Solved

Why aren't all product images importing back into Shopify?

Christin
Excursionist
18 1 8

I have exported all my products to add article numbers in google sheets. Then I importet them back. I just realized that only the main image of each product has been imported, all other images are missing.

After this issue I tried something: I added a second picture to a particular product >  exported that particular product > again deleted the second picture of this product in shopify  > imported the csv file (product) back to shopify > the second pictures has not been imported back to shopify.

So what am I doing wrong?

Thanks for helping!

 

Accepted Solution (1)
PaulCarlisle
Tourist
3 1 18

This is an accepted solution.

Ok so I know I'm a little late to the party but I thought I'd bring to the table a solution that works perfectly and won't require any additional apps or hours of re-uploading images to your file repository and re-linking to your products, I had exactly the same issue described in this post, I exported my products to CSV, updated the prices and descriptions and when I re-imported the products only the first image and it's associated alt tag was present. During this import failure I got an import error like this:

Screenshot 2020-04-03 at 13.01.32.png


Why it happens

As correctly stated further up this post, if you upload an image directly to a product the image gets deleted when you import changes, whereas if the image is uploaded to the files repository and you select it via the product it creates a link, this way the image path is retained when you make any changes via the Shopify product import.

 

I reached out to Shopify Support and they gave me the following solution:

When a product image is deleted a copy of the image is retained, this process pulls back in the saved copy of the image and creates a new link

 

The Solution

Using your preferred text editor open your CSV file and do a find and replace on all image paths, look for /products/ and replace all instances with /deleted/products/ then save your CSV file and import to your store.

 

The result of doing this is that the images are pulled from the /deleted/products repository and re-imported as new files with a new file name and re-links them to your products. (As a test, if you then export the product, you'll see that the image paths are different and no longer contain /deleted/).

 

Now go to a product in your Shopify admin and you'll see all your images are back with their corresponding alt tags!

 

I thought this may still be useful as it's still very much a current issue, thank you Daniela from Shopify Support for your solution.

 

 

View solution in original post

Replies 26 (26)

tonisan
Visitor
2 0 0

I'm having the same issue! 😞 Anyone know why Shopify no longer recognizes the links to the secondary images?

Christin
Excursionist
18 1 8

Hi!

I know what my problem was. I uploaded the product pictures on the product pages. They are lost when you export these producta. You have to upload your pictures on the general pictures section in shopify:

https://accounts.shopify.com/store-login?redirect=settings%2Ffiles

 

By doing this, every single picture gets a URL which you copy and insert in your particular product page. Now, a link exists to each picture and they dont go lost.

 

Hope my explanation was fine and this is what you where looking for! Good luck

 

Christin
Excursionist
18 1 8

 


@Christin wrote:

Hi!

I know what my problem was. I uploaded the product pictures on the product pages. They are lost when you export these producta. You have to upload your pictures on the general pictures section in shopify:

https://accounts.shopify.com/store-login?redirect=settings%2Ffiles

 

By doing this, every single picture gets a URL which you copy and insert in your particular product page. Now, a link exists to each picture and they dont go lost.

 

also look here: https://help.shopify.com/en/manual/products/import-export/using-csv#add-multiple-product-images-in-a...

 

Hope my explanation was fine and this is what you where looking for! Good luck

 


 

Salad_Zoom
Tourist
12 0 2
Just a note, we have an app that will allow you to locate missing images, also has a new feature that checks variants for images. It is called Image Audit, you can look into it if you want to see how it can work for you. 

 

 

Image Audit on Shopify App Store

 

 

Thanks 

PaulCarlisle
Tourist
3 1 18

This is an accepted solution.

Ok so I know I'm a little late to the party but I thought I'd bring to the table a solution that works perfectly and won't require any additional apps or hours of re-uploading images to your file repository and re-linking to your products, I had exactly the same issue described in this post, I exported my products to CSV, updated the prices and descriptions and when I re-imported the products only the first image and it's associated alt tag was present. During this import failure I got an import error like this:

Screenshot 2020-04-03 at 13.01.32.png


Why it happens

As correctly stated further up this post, if you upload an image directly to a product the image gets deleted when you import changes, whereas if the image is uploaded to the files repository and you select it via the product it creates a link, this way the image path is retained when you make any changes via the Shopify product import.

 

I reached out to Shopify Support and they gave me the following solution:

When a product image is deleted a copy of the image is retained, this process pulls back in the saved copy of the image and creates a new link

 

The Solution

Using your preferred text editor open your CSV file and do a find and replace on all image paths, look for /products/ and replace all instances with /deleted/products/ then save your CSV file and import to your store.

 

The result of doing this is that the images are pulled from the /deleted/products repository and re-imported as new files with a new file name and re-links them to your products. (As a test, if you then export the product, you'll see that the image paths are different and no longer contain /deleted/).

 

Now go to a product in your Shopify admin and you'll see all your images are back with their corresponding alt tags!

 

I thought this may still be useful as it's still very much a current issue, thank you Daniela from Shopify Support for your solution.

 

 

AmitOX
Tourist
3 0 0

You are the best!

shady1677
Visitor
1 0 0

Thanks, Buddy. God bless you!

dlomarcan
Tourist
7 0 2

@PaulCarlisle Thank you for this tip. You saved me hours of work finding and restoring images.

Irisbel
Visitor
1 0 0

Thank You Very Much for sharing with us the solution... You saved me.

PaulCarlisle
Tourist
3 1 18
No problem 👍
disgp
Visitor
2 0 1

Thank you! This is the most on point and helpful answer I've ever read here!

MarkyMarkMark
New Member
7 0 0

This is the solution, Thanks Paul it worked for me, you saved me hours of work. 

 

chrisjack
Visitor
1 0 0

Nice one @PaulCarlisle, you saved my bacon. 

 

Seriously though, I did a full CSV export -> price adjustment -> import of my catalogue in February 2022 and I didn't have this issue. Why oh why Shopify would you fatally hamstring the CSV import-export method in this way?

 

Working with the product export CSV's is fiddly enough as it is (e.g. always needing the primary row for a product with its html body etc to be positioned above the other rows, makes sorting the csv while editing slightly nerve wracking when it shouldn't be).

abhishek-yadav
Shopify Partner
1 0 0

Thanks @PaulCarlisle 
Your solution just made my day and saved lots of time that I have else would have spent in manually uploading images
A big thanks to @PaulCarlisle 

joooaodias
Visitor
1 0 0

U just save my life

InspiredIndigo
Visitor
1 0 0

This is absolutely brilliant and just saved me HOURS of work - thank you!

 

I'll add to it that you don't want to replace ALL instances of /products/ with /deleted/products - this did replace all of my secondary images but also deleted my main images (but it was easy enough to go back in the CSV and change the main images back to /products/). So, ONLY do the find and replace on the secondary images.

 

Thanks again for the extreme time save!

boxer_3
Visitor
3 0 0

If you're like me and some URLs have structure that has no /product/ such as: 

https://cdn.shopify.com/s/files/1/0570/9820/7368/files/14k-solid-gold-pink-sapphire-pendant-necklace...,

 

You can include /deleted/ before the second /files/ in the url like this: 

https://cdn.shopify.com/s/files/1/0570/9820/7368/deleted/files/14k-solid-gold-pink-sapphire-pendant-...

 

And it should work fine. Be careful when using find and replace, you'll need an additional repeated identifier around /files/ becuase /files/ is used twice in the urls and replacing simply /files/ would lead to chaos. In my case it is 8/files/ as every url has it.

Enjoy.

 

 

bluepittie01
New Member
8 0 0

My images don't have "/products/" in them to be able to resolve this.
Any other solution? Know of any apps?

About to pull my hair out!!

boxer_3
Visitor
3 0 0

Share your link structure here and check my answer from literally yesterday :D. Its above your response.

bluepittie01
New Member
8 0 0

lol! my bad- my freaking out must've made me miss your response.
thanks for bringing it back to my attention!! gonna test it later today. note: I didn't get any import errors from the multiple files I imported, and I'm not sure at what point the secondary images were deleted. hope this still works off a recent export.

here's an image I have:
https://cdn.shopify.com/s/files/1/0671/6394/7265/products/VKITCOM30WAWCO_Alt_8.jpg?v=1706545780

also would I essentially have to do this before every import? Me and my assistant have been doing some bulk updates of descriptions and tags and such, so there'd be multiple imports/exports.

boxer_3
Visitor
3 0 0

I didnt get a notice either. The url you've sent seems fine. Does it not work?

bluepittie01
New Member
8 0 0

I tried two SKUs and the secondary images are back! thank goodness.

BUT, the original main stock image is now gone lmao.
This is what I did: I imported the file with the find and replaced with "/deleted/" on all the images, imported, and noticed the main stock images were removed but all the secondary images were restored. Then followed what @InspiredIndigo said above- only putting "/deleted/" on the secondary images....and the main stock image is still gone after the import. -_- LOL I'm confused.

bluepittie01
New Member
8 0 0

Ok I re-tried it with the first image normal, then added /deleted/ in the secondary images, and it looks like it's working! 😄

MPI1
Visitor
2 0 0

Will that solution work on this type if It has no /products in the filename?

Can I slide /deleted in somewhere else? EVERY one of my sites URLs are not valid now. 

https://cdn.shopify.com/s/files/1/0550/0151/4028/files/SuperTurbosSide_dec21fdb-58f0-42a7-bfcc-56324...
PaulCarlisle
Tourist
3 1 18

Yes absolutely, just replace /files/ with /deleted/files/

 

Like this: https://cdn.shopify.com/s/files/1/0550/0151/4028/deleted/files/SuperTurbosSide_dec21fdb-58f0-42a7-bf...

 

Check it out by clicking the link and you'll see your image again...

seatea
Visitor
1 0 0

I'm having this same issue, however I'm sourcing images from a different website host (Dropbox). Do I really need to download all of those tons of images and re-upload them into Shopify? This will take hours and I'd prefer just to keep using the "Add media from URL" method....anyone have a fix?