Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

How to group product images by variants?

Group images by product variants to set the related images for a specific color variant.

You can follow the listed recommendations to apply configurations specifically for a color variant:

Step 1

Go to your Shopify admin -> Products, select a product, or create a new one. Then, add product images in the "Media".

Step 2

Place images in the order to display on the storefront:

  • first image - main image of the product variant;

  • all other images - related to this product variant.

The main image marks the beginning of images grouped by a particular color and is followed by the main image of the new group.

Start each new group of product variant images with the main image. Then, add as many related images as needed.

Step 3

Add a product option with product variants.

Step 4

Assign main images to each product variant.

Step 5

To use the "Group by 'group-gallery' tag" option, paste the 'group-gallery' tag in the "Tags" field for the desired product. This tag will become available in the "Tags" list for other products in your admin.

Step 6

Use the settings provided in the "After variant selection" drop-down of the Theme Editor:

Last updated