Product cards

Product cards appear wherever products are listed: collections, search, recommendations and featured grids. Small changes here show up everywhere, so they’re worth getting right.

Updated 6 min read

Find these in the theme editor under Theme settings > Product cards. Badges and flash sales have their own groups, Product badges and Flash sales, covered further down.

Card style and images

A product card with the image on a light background and plain text below
Standard
A product card where the image and text sit together inside a white card
Card
SettingWhat it does
StyleStandard, or Card, which puts everything inside a box with its own color scheme.
Aspect ratioKeep each image’s shape, or make every card the same, such as square. The same shape everywhere makes grids line up neatly.
Image fills available spaceCrops images to fill the card. Use Focus point to keep the top, center or bottom in view.
Show second image on hoverShows the product’s second image when customers hover over the card.
Image padding and scaleAdds space around the product, which suits cut-out product photos.
Replace white image backgroundsBlends white photo backgrounds into a color of your choice. Only use it if every product image has a white background.

What the card shows

  • Vendor and subtitle: the subtitle uses Shopify’s Product subtitle metafield.
  • Inventory: show stock levels for low stock only, or always, with or without a count.
  • Include collection in product link: keeps the collection in the product’s address, which lets breadcrumbs show where the customer came from.

Ratings and reviews

Turn on Show product rating to show stars on each card. The stars come from your reviews app, which must save ratings to Shopify’s standard review metafields. Most popular review apps, such as Judge.me, do this.

You can set the star color and size under Product card style and Product card colors.

Swatches

Cards can show color swatches for each product. Swatches come from Shopify’s category metafields, which you set up on your products. See Shopify’s guide to swatches. In the settings, choose where swatches sit, their size, and how many to show. Swatch rounding is in Appearance.

Quick add

Turn on Enable quick add to put a button on each card. Customers can choose options and add to cart without leaving the page.

  • Quick add popup style on desktop: a centered popup or a side drawer.
  • Quick add popup type: standard, or a bulk order list for products where customers buy many variants at once.
  • What’s in the popup: set on the product page. Many blocks there have a Show in quick add setting. See Product page.

Products without variants

These can go straight into the cart, so set Button for products without variants to Add to cart, or show a quantity selector. Choose Quick view if you’d rather customers saw the popup first.

A product card with a + Cart button
Add to cart
A product card with a Quick view button
Quick view

Sold-out products

Button for sold out products sets what customers can do:

  • Disabled: a grayed-out Sold out button.
  • Quick view: the popup still opens, so customers can see the details.
  • Notification: a Notify me button that opens the popup. Make sure the Back-in-stock alert block is near the top of it.
A sold-out laptop card with a disabled Sold out button
Disabled
A sold-out laptop card with a Notify me button
Notification

Product badges

Badges are small labels on the product image that appear automatically. Set them up in Theme settings > Product badges.

A row of product cards with Sale, New, Sold out and Bulk order badges on the images
BadgeShows when
SaleA product has a compare-at price. Show it as text, a percentage or an amount saved.
Sold outEvery variant is out of stock.
NewA product is in one of the collections you choose, such as “New in”.
PreorderA product uses the preorder template. It can show in the cart too.
Bulk orderA product uses the bulk-order template.
CustomA product has text in its custom badge metafield. See below.

You can choose the position on the image, the maximum number shown, and each badge’s shape and colors. Gradients replace the background color where possible.

Custom badges

A custom badge shows your own text on chosen products, such as “Staff pick” or “Refurbished”.

A phone product card with a green Refurbished badge
  1. In your Shopify admin, go to Settings > Metafields and metaobjects > Products and click Add definition.
  2. Name it Custom badge, set the namespace and key to custom.badge, and choose Single line text.
  3. On each product, type the badge text in the new metafield.
  4. In the theme editor, go to Theme settings > Product badges and turn on Show custom badge.

To give a product’s badge its own colors, add Color metafields with these keys:

Optional color metafields
custom.badge_background_color
custom.badge_foreground_color
custom.badge_border_color

Highlight and option badges

Highlight badges are small tags below the product name for features worth knowing at a glance, such as “Wireless charging” or “Vegan”.

Product cards with small outlined tags, such as storage sizes and Wireless charging, below the titles
  1. Create a product metafield with the key custom.highlights, type Single line text, and choose List of values.
  2. Add one or more values to each product. Each value becomes a badge.
  3. Turn on Show product highlight badges in Theme settings > Product cards.

Optionally, add custom.highlights_label for a label per product, and a Color metafield, custom.highlights_color, for a badge color per product.

Product option badges work the same way, without metafields. Type option names, such as Size,Color, and the card lists each product’s values, such as S, M and L.

Flash sales

A flash sale adds a progress bar to product cards showing how much stock has gone, which creates a sense of urgency.

A laptop product card with a Sale badge and a progress bar reading 22% claimed
  1. Create a collection, such as “Flash sale”, with the products you want to include.
  2. In the theme editor, go to Theme settings > Flash sales and choose that collection in Collections.
  3. Set the Flash sale inventory threshold, explained below.
  4. Choose whether the bar shows the percentage claimed or the quantity sold, and style it to suit.

The inventory threshold

Shopify doesn’t record how much stock you started with, so the theme needs you to tell it. The threshold is the starting stock for each flash sale product.

  • The bar appears once a product’s total stock drops below the threshold.
  • The bar shows how much of the threshold has gone.

For example, with a threshold of 10 and 5 left in stock, the bar shows 50% claimed.

With many flash sale products, set Flash sale position to Bottom of card so the bars line up.

Product icons

Product icons are a row of small images, such as vegan, gluten-free or recyclable symbols, on product cards and the product page.

Food product cards with a row of small dietary icons at the bottom, outlined in red
  1. Create a product metafield with the key custom.icons, type File, and choose List of files. Restrict it to images.
  2. On each product, upload the icons. Google’s Material icons are a good free source.
  3. Give each icon clear alt text, such as “Vegan”. It appears when customers hover over the icon, and as the label on the product page.
  4. In Theme settings > Product cards > Product icons, choose where the icons sit and their size.
  5. To show them on the product page too, add the Product icons block to Product information.

Compatibility badge

If you use the Compatibility finder, cards can show a badge such as “Fits: BMW 2 Series 2022” on matching products. See Compatibility finder badges.