The issue of duplicate images in the media library of the WooCommerce website when importing images from the CSV file.
This is happening because the Product Import Export Plugin for WooCommerce uses WP Importer. The WP Importer has a 1:1 relationship with the product and its corresponding image. So when you upload an image via CSV, an image entry for the product is added to the media library, duplicating the image. This happens because, at the moment, there is no way to check whether an entry already exists in the media library. The duplication of an image in the media library is standard, and the vital thing to remember is that it’s just an entry.
Even if you have multiple images in the media library, the images are not duplicated on the server this way. The only way the images are reproduced on your server is if you use the full URL path of the image. So, to avoid using up too much space on the server, use the image name (image.png) instead of the complete image URL in the images column. It will link the product to the image and result only in thumbnail generation.
Comments (2)
Scott
November 21, 2022
This article is not accurate. I uploaded a set of images to the WordPress Media Library then imported the corresponding products with the Product Import Export Plugin for WooCommerce plugin via a .csv file with the images column populated with only the image name (example: image.jpg), not the full URL, just as this article suggests. When the import was complete I looked at the Media Library and the /wp-content/uploads/ folder on the server and noticed the import process duplicated all the product images that were already in the Media Library, adding a “-1” to the file name of the duplicate images. I checked the products to see which image version was linked to them and all of them linked to the duplicate image version instead of the original. Based on my testing, it does not appear that imported products can be linked to images that already exist in the Media Library without duplication. If that is not true, please tell me what I did wrong. Thank you.
Alan
November 25, 2022
Hi,
Can you please reach us via support so that we can check it and help you?