Fluorescent
Stiletto
Stiletto
  • Stiletto Help Center
    • Start using Stiletto
      • Theme licenses
      • Migrate your theme
    • FAQs
    • Video tutorials
    • Changelog
  • General
    • Editing themes
      • Adding sections
      • Using templates
      • Accessibility
      • Customizing your site
      • SEO for Shopify themes
      • H1 heading tags
      • Online store speed
    • Image guide
      • Web ready photography
      • Image sizes
      • File formats
      • Theme image settings
    • Adapting theme content
      • Edit default theme content
      • Multiple languages
      • Dynamic content with metafields
      • Unique content for markets
    • Update your theme
  • Theme styles
    • Theme settings
    • Style presets
      • Demo layouts
    • Fonts
    • Colors
    • Animation
  • Pages
    • Templates
      • About page
      • Blog page
      • Blog posts
      • Collections list
      • Contact page
      • Customer accounts
      • FAQ page
      • Lookbook
      • Password page
      • Search page
      • Store locations
      • 404 page
      • Home page
    • Announcement bar
    • Header
      • Layout and style
      • Logo
      • Transparent header
      • Mega menus
      • Mobile menu
      • Quick search
      • Language and currency
      • Social media icons
      • Customer account icon
    • Footer
      • Links block
      • Newsletter block
      • Text and image block
      • Language and currency
      • Payment icons
      • Custom Liquid
  • Sections
    • Theme sections
      • Using sections
      • Content blocks
      • Blog posts
      • Collapsible row list
      • Collection list grid
      • Collection list slider
      • Complete the look
      • Contact form
      • Countdown banner
      • Countdown bar
      • Events
      • Featured collection grid
      • Featured collection slider
      • Featured product
      • Gallery carousel
      • Grid
      • Image compare
      • Image hero
      • Image hero split
      • Image with text
      • Image with text split
      • Multi column
      • Newsletter
      • Newsletter compact
      • Promotion banner
      • Promotion bar
      • Quotes
      • Recently viewed products
      • Rich text
      • Sales banner
      • Scrolling content
      • Shoppable image
      • Shoppable image editorial
      • Slideshow
      • Testimonials
      • Video
      • Video hero
      • Video with text
    • Popups
      • Sign up popup
      • Age verification
      • Countdown popup
      • Promotional popup
  • Products
    • Product listings
      • Product card style
    • Prices and discounts
    • Product badges
    • Quick shop
  • Product pages
    • Product template
      • Alternate templates
      • Pre-order template
      • Gift card
    • Layout and style
      • Product tabs
      • Media gallery
      • Sticky product details
      • Breadcrumbs
      • Navigation buttons
    • Overview blocks
      • Default blocks
        • Description
        • Product header
        • Variant selector
        • Quantity selector
        • Buy buttons
        • Local pickup banner
        • Share icons
        • Sticky add-to-cart bar
      • Collapsible rows block
      • Complementary products
      • Custom options
      • Image block
      • Information popup
      • Product labels
      • Secure payment
      • Stock level indicator
      • Text block
      • Text list with icons
      • App blocks
    • Variant options
      • Variant chips
      • Variant swatches
        • Enable swatches
        • Use default colors
        • Use custom colors
        • Use variant images
        • Use custom images
        • Change swatch styles
        • Show on product cards
        • Dynamic option availability
      • Media grouping
      • Sibling product swatches
    • Product page sections
      • Product reviews
      • Product recommendations
  • Collection pages
    • Collection template
      • Collection landing
      • Sale collection
      • Subcollections
      • Flash sale
    • Banner
    • Product grid
    • Filters and sorting
  • Cart
    • Cart page
    • Quick cart
      • Added to cart popup
      • Empty cart promotion
    • Free shipping bar
    • Low inventory warning
    • Cross sells
  • Support
    • Support policy
    • Shopify vs Theme issues
    • Store access requests
  • For developers
    • Custom CSS
    • Custom fonts
    • Custom Liquid
    • Custom JavaScript events
    • Edit Theme JavaScript
Powered by GitBook
On this page
  • 1. Create and upload custom swatch images
  • 2. Set up product variants

Was this helpful?

  1. Product pages
  2. Variant options
  3. Variant swatches

Use custom images

Last updated 4 months ago

Was this helpful?

Using custom images for swatches is great for product variants that have patterns or textures. Custom swatch images require image file names and variant names that match, which we will cover below.

Adding custom swatches images involves two general steps: (1) Create and upload your custom swatch images and (2) Set up your product variants with matching names.

1. Create and upload custom swatch images


For each product variant, you need to create a PNG image by screenshotting or cropping your product images. Each swatch image needs a file name that matches the variant name in your product options.

For example, if the product variant is called "Sea Blue", the swatch image file must be named sea-blue.png.

If your store uses multiple languages, make sure to upload swatch images with file names that match the translated name of your product variants, for each language.

For example, if your store uses English and German, you need two swatch image files for the default variant name (yellow.png) and the translated name (gelb.png).

STEPS
  1. You can create PNG image files by taking a screenshot (step 2) or cropping your product images (step 3).

    We recommend images with minimum length or width of 70px.

  2. Screenshots: Use the built-in screenshot tool on your computer to capture swatches from your existing product images:

    Windows:

    Mac:

  3. Cropped images: Alternatively, crop a section of your product photo with a photo editing application (like Preview or Photoshop).

    Windows:

    Mac:

  4. Save your images as PNG files with a file name that matches the variant name. File names must be in lowercase and use hyphens instead of spaces. Add image files for each store language matching the translated variant name.

    For all image files, use lowercase only (no capitals):

    Variant name
    File name

    Gray

    gray.png

    Green

    green.png

    For variants with multiple words, use hyphens - instead of spaces:

    Variant name
    File name

    Sea Blue

    sea-blue.png

    Red and Blue

    red-and-blue.png

    For multiple languages, add image files for each language with the translated names of the product variant:

    Language
    Variant name
    File name

    English

    Yellow

    yellow.png

    German

    Gelb

    gelb.png

    French

    Jaune

    jaune.png

  5. Once you have renamed your swatch images, go to Content > Files in your Shopify admin.

  6. Click the Upload files button in the top-right corner and add all your swatch image files. You can select multiple files at once.

  7. Go to Step two: Set up your product variants.

2. Set up product variants


Once you've uploaded your images, you need to set up your product variants with names that match the file names of your swatch images.

STEPS

In your Shopify admin:

  1. Go to Products and click the product you want to edit.

  2. Under Variants, click Add options like size and color checkbox if you're adding variants for the first time.

  3. Add the Option name (e.g. "Color" or "Material").

    Remember to add this option name in your Theme settings to enable swatches.

    See Shopify's for more information about product options.

  4. Add the Option values (product variants) with a name that corresponds to the correct swatch image file.

    For example, if you've uploaded dark-blue.png as a swatch image, the product variant must be named Dark Blue.

    If your store uses multiple languages, add the translated variant names using feature.

    Variant name
    File names

    Green

    yellow.png, gelb.png, jaune.png

    Sea blue

    sea-blue.png

    Red and blue

    red-and-blue.png

  5. Preview your store to confirm that the swatches now appear.

    If the theme cannot locate a matching swatch image for a color variant, a White swatch is shown. In this case, make sure the file names match the variant name, use hyphens - instead of spaces, and are all lowercase (no capitals).

  6. Click Save.


Related links

How to use Windows Snipping Tool
Take a screenshots on your Mac
How to Crop Images on Windows
How to crop an image in Preview on Mac
Variants guide ↗
Shopify's Translate & Adapt
Use default color swatches
Use custom color swatches
Use variant image swatches
Change swatch styles
Show swatches on product cards
Enable dynamic option availability
Enable swatches