Invalid image URLs returned by Storefront API

New Member
4 0 0

I am getting back image URLs from the Storefront API that point to non-existent files on the Shopify CDN.

I'm not going to post shop details in a public forum, so how can I get help with this apparent Shopify error? I tried partner support and they (unhelpfully) pointed me to these public forums.


Replies 3 (3)

Shopify Expert
11190 225 2283

What can you post? This is a community forum so we'd need a little bit to work with. Do understand that you might not want to add all the details here so maybe throw them into a github gist or something that you delete later.

Are you sure it's a non existent url? is it the version number that's wrong? missing? something else?

★ I jump on these forums in my free time to help and share some insights. Not looking to be hired, and not looking for work. ★
New Member
4 0 0

We use the Storefront API transformedSrc field to get Shopify CDN image URLs. For at least one shop, many of these URLs lead to a CDN 404 error.

As far as I understand, an invalid URL from this field is either an API error or a CDN error. The transformations are best-effort, but they're ignored if unsupported; and for this shop, simply requesting transformedSrc with no transformations still leads to a 404 error page.

The query is very simple:


query ($id: ID!) {
  product: node(id: $id) {
    ... on Product {
      images(first: 1) {
        edges {
          node {
            transformedSrc(maxWidth: 128, maxHeight: 128)


Example of a bad transformedSrc URL returned by the Storefront API:

I expect Shopify needs to look into this to determine whether the API or the CDN is at fault.

Shopify Staff
249 42 36

Hey @sigh,

We did a bit of digging with the info you shared. Based on this specific behaviour, and intended functionality of how images are hosted, this would not be directly related to the our Storefront API.  I would suggest reaching out to a merchant experiencing this types of issue, and encourage them to contact our support team directly - feel free to share this link

awwdam | API Support @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit or the Shopify Web Design and Development Blog