Support » Plugin: WooCommerce » WooCommerce Product Import Duplicating Images

  • When using the CSV import option for WooCommerce I have to upload the images first otherwise they will not import which is fine.

    So I open Media Manager, import my images with the correct names as per the CSV and then go back to Product Import. At this point I import the produces and then if I log into my server via SFTP I can see that each of the image has been duplicated. For Example I uploaded 3 images, they were named: “ArielWedding.jpg”, “BelleHC.jpg” and “BelleWedding.jpg”. WooCommerce then re creates these images as “ArielWedding-1.jpg”, “BelleHC-1.jpg” and “BelleWedding-1.jpg”. This makes no sense to me? And just clogs up my server.

    Its rather annoying that when I upload them to the Media Manager WordPress creates 6 copies of the first image in different sizes alone. That when I import the products WooCommerce then creates another 6 images with “-1” beside them!

    I would have thought that the whole point of uploading the images first would mean you link the product to that one, not recreate it another 6 times!

    I have also noticed that within the Media Section, the images are not attached specifically to the Products its self, unlike when I add then manually.

    Please see 2 images

    SS01 Shows that they are not “Attached” to product via import

    SS02 Shows that the images are duplicated with “xxxx-1.jpg”

    The page I need help with: [log in to see the link]

Viewing 8 replies - 1 through 8 (of 8 total)
  • @daza110

    Thank you for writing the forums, and sharing some details of the symptom.

    Looking for confirmation — Is it the (new-as-of-WooCommerce-version-3.1) WooCommerce native CSV import functionality that you’re using?

    (I mean this: )

    (As opposed to another 3rd party plugin, etc.)

    As an initial step, I want to be able to reproduce the symptom of the CSV import failing to cause the images to become imported.

    Would you please share with us a sample CSV file, that manifests the symptom?

    Would you please also describe what directory the image file(s) are in, in the case when the CSV fails to import?

    Looking forward to learn more about the concerns!

    Please forgive the delayed response!! Yes I can confirm that it is that exact importer I am using.

    This is the CSV

    The directory is

    • This reply was modified 3 years, 1 month ago by daza110.


    Thank you for clarifying and telling more details.

    I’ll see if I can reproduce and then again reply.


    Thanks again for having shared the additional details.

    I see what you mean, that the act of importing images during the .csv import does make a copy of the file during the process.

    Also, I agree that the import also usually fails in my tests if I try to specify just the filename, or anything other than a full “http:…” url path for the image column value.

    Also, I agree that if one uses the media library to add the images prior to the .csv import, then that results in even more clutter.

    How about this?

    First, directly upload (like via direct SFTP) the product images to a separate folder, for example

    Then, in the Images column of the .csv import, reference that folder. for example set the value for that column for the first row from the “Product Import CSV TEST.csv” file as:

    What do you think?


    Will you kindly start to mark this thread as ‘Resolved’? (including some solution detail)

    Or if there’s still concern, then will you update how it is?



    @mjjojo Please once again forgive the very delayed response.

    I confirm that this work around works fine and prevents the duplicate “xxxxx-1”, it just means I have to delete them from the “temp” folder I created later which is no problem.

    It would still be beneficial to me to see the “Attached” image in the Media Library. As per my SS01 above in description (copied below), SS01 Shows that they are not “Attached” to product via import however when added one by one they automatically attach.

    Is this something you can build in to the import? It just cleans every thing up.

    @dmjjojo, i would like to reuse this thread for another issue/request. i use the native csv-importer too and it works really well. i do upload my images in another folder on the server, which helps me to have one library of product images there. so far so good.

    the problem is, that when i update my products, all the files are imported again and also duplicated. i guess the assumption was, that there could be a change in the image files, so it is better to re-import and reference to the new ones. but imho i think that it would be best to have the chance to say
    – i want existing images (just the name, no matter in which year-month-folder they are stored) in the library to be used and do not upload the referenced image again
    – i want all images to be uploaded again, because i changed them but they have the same names as before

    if it is not possible in the gui soon, could you please reference to a filter i could hook in? i guess it would not be to hard to code 🙂

    best, matt

    alternative way is
    1. import your images into media library
    2. import product csv without importing image, set image path as ‘do not import’
    3. delete the imported csv file from media library
    4. re-import same file with existing checkbox selected with image path as it is

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘WooCommerce Product Import Duplicating Images’ is closed to new replies.