Build image links from file names

Set up an image URL convention so your Shopify product push builds image links from your CDN prefix and file name patterns.

In Uphance, you set up an image URL convention so your Shopify product push builds image links from your CDN prefix and file name patterns. Each active color gets one main image link followed by its alt image links, in color order.

Your convention tells the Shopify push how to turn each product's active colors into image links. It also decides how those links sit alongside any images you've uploaded.

  1. Go to Apps > My apps. On the Image URL Conventions form, enter your CDN Prefix, the base URL that goes in front of every image path. Apps > My apps on the Apps page
  2. Fill in the Main Image Pattern (a new form starts with {style}_{color}), and end it with the file extension, such as .jpg, because none is added for you.
  3. Fill in the Alt Image Pattern, which takes the same placeholders as the main pattern plus {n}, a counter that starts at 1, and include the file extension here too.
  4. Enter an Alt Text Pattern; a new form starts with Product image of {title}.
  5. Choose an Image Precedence: Convention first then uploads, Uploads first then convention, Convention only, or Uploads only.
  6. Click Save Convention with the CDN prefix, main pattern, alt pattern and alt text pattern all filled in, because a saved convention needs every one of them.

Once a CDN prefix and a main pattern are saved, a URL Preview panel appears on the form with example main and alt links, using style 1503 and color Navy as sample values. From then on, each active color gets one main image link followed by its alt image links, in color order.

Good to know

If something goes wrong

Common questions

Why isn't the Shopify push using my image URL convention?

An image URL convention only shapes the Shopify product push when both the Pro-Fashion Shopify integration setting and the image URL conventions setting are on for your organization. The image URL conventions setting starts off for every organization.

Why are a color's images missing when the style number is blank?

The {style} placeholder in an image pattern uses the product identifier, falling back to the style number. When both are blank, it raises a missing-placeholder error.

Why is the Alt Image Count column missing on product colors?

The Alt Image Count column on a product's Colors section only appears when the alt images setting for product colors is on. Once it appears, it accepts a value from 0 to 20.

How do uploaded images and convention images combine in the Shopify push?

An image URL convention's Image Precedence decides it: Convention only gives just convention images, Uploads only gives just uploaded images, Convention first puts convention images before uploads, and Uploads first puts uploads before convention images.

Does a trailing slash on my CDN prefix break image links?

A trailing slash on an image URL convention's CDN prefix is removed, and the prefix is joined to the file name pattern with a single slash.