> For the complete documentation index, see [llms.txt](https://staylime.com/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://staylime.com/docs/volume-themes/theme-settings/product-badges.md).

# Product Badges

Set up Volume product badges in Shopify: Sale, Sold out and Preorder badges with their own styles and colors, plus up to four custom badges driven by the custom.badge metafield.

Badges are the small labels on product cards and product pages — **Sale**, **Sold out**, **BEST SELLER** — that give a shopper a reason to stop scrolling. They are the cheapest merchandising tool in the theme: no app, no extra section, just a label that tells people what is urgent, what is new and what makes a product worth a second look.

Volume gives you three badges that appear on their own, and up to four custom badges that you write and color yourself. Everything is in **Theme Editor → Theme settings → Product badges**.

{% hint style="info" %}
On a product card, badges sit in the top corner of the image. On the product page, they sit next to the price.
{% endhint %}

***

## Sale, Sold out and Preorder

These three need no metafields and no product setup — the theme decides when to show them.

| Badge        | When it appears                                                           | What you can change                                 |
| ------------ | ------------------------------------------------------------------------- | --------------------------------------------------- |
| **Sale**     | The product is in stock and its compare-at price is higher than its price | Show badge, Badge style, Text and Background colors |
| **Sold out** | The product is out of stock                                               | Show badge, Text and Background colors              |
| **Preorder** | The product uses the `product.preorder` template                          | Show badge, Text and Background colors              |

Each of the three has its own **Show badge** checkbox, so you can switch any of them off without touching code.

**Badge style** belongs to the Sale badge only. Pick **Text** to show the word *Sale*, or **Percentage** to show the discount instead — for example `-30%`. The percentage is calculated from the compare-at price and rounded to a whole number.

{% hint style="info" %}
The discount is taken from the product's first available variant. If different variants are discounted differently, turn on **Update variant price and badge** in **Theme settings → Product card** so the card recalculates the badge for the variant the shopper selects.
{% endhint %}

{% hint style="warning" %}
**Preorder is about the template, not about the inventory policy.** Setting a product to continue selling when out of stock does not give it the Preorder badge. The product has to use the `product.preorder` template — see [Quick View & Pre-order templates](https://staylime.com/docs/volume-themes/collections-and-products/product-page/quick-view-and-pre-order-templates.md).
{% endhint %}

### Changing the wording

*Sale*, *Sold out* and *Pre-order* come from the theme's language file, not from a theme setting. To reword them, go to **Content → Translate & Adapt**, or open **Theme Editor → ⋯ → Edit default theme content** and search for the badge strings.

### Make transparent

The checkbox at the top of the **Product badges** group applies to every badge at once. When it is on, the badge loses its fill and becomes an outlined label: a thin border and text in the color you picked as the background. It is the safer option over busy product photography, where solid blocks of color tend to fight with the image.

***

## Custom badges

Custom badges are your own labels — **BEST SELLER**, **PREGNANCY SAFE**, **NEW IN** — with your own text and colors. The theme holds four of them, and a product can carry several at once.

Setting them up takes three steps: name the badges in Theme settings, create the badge metafield, then assign badges to products.

{% stepper %}
{% step %}

### Name your badges in Theme settings

Go to **Theme Editor → Theme settings → Product badges → Custom badges**.

For each badge from **Badge 1** to **Badge 4**, enter the badge text and pick its **Text** and **Background** colors. The text you type here is what shoppers see, and it is the value you will put on products in step 3.
{% endstep %}

{% step %}

### Create the Badge metafield

The theme reads custom badges from a product metafield called `custom.badge`. You only create it once:

1. In your Shopify admin, open any product and scroll to the **Metafields** section, then click **Add definition**. (The same screen is available from **Settings → Metafields and metaobjects → Products**.)
2. In the **Name** field, enter `Badge`. The **Namespace and key** fills in automatically as **`custom.badge`** — it has to match exactly, so check it before saving.
3. Click **Select type** and choose **Single line text**.
4. Click **One value** and switch it to **List of values**, so a product can carry more than one badge.
5. Click **Save**.

<figure><img src="https://846450420-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJZYrhya1ZIeTZS4wpBJB%2Fuploads%2From4Clvc8EG7vandZLp1%2Fcustom-badges.gif?alt=media&amp;token=e0c375e3-3922-492c-99d2-c57a6992b0f3" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Add badges to products

1. Open the product you want to badge.
2. Scroll to the **Metafields** section and find **Badge**.
3. Add one or more values, written the same way as in Theme settings — for example `BEST SELLER`.
4. Click **Save**.

<figure><img src="https://846450420-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJZYrhya1ZIeTZS4wpBJB%2Fuploads%2F32t2aEWxYLCda9V3F0ll%2Fcustom-badges-product.gif?alt=media&amp;token=7e760997-3e92-49a1-b5df-91a1d8d5bfda" alt=""><figcaption></figcaption></figure>

The badge now appears on that product's card and on its product page.
{% endstep %}
{% endstepper %}

{% hint style="success" %}
**Good to know**

* **Capitalisation does not matter.** `best seller` and `BEST SELLER` match the same badge — the theme compares the values in lower case. Everything else does: an extra space, a hyphen or a different spelling counts as a different value.
* **A value that matches nothing still shows up**, just without your background color. That is the quickest way to spot a typo: if a badge appears unstyled, its text does not match any of the four names in Theme settings.
* **Custom badges are not limited to products in stock.** They show on sold-out products too, next to the Sold out badge.
* **Make transparent does not restyle unmatched values** — one more reason an unstyled badge stands out.
  {% endhint %}

### Badges on a single variant

The product page, **Featured product** and **Quick view** also read `custom.badge` on the **variant**, which lets you badge one color or one size instead of the whole product.

To use it, create the same definition for variants: **Settings → Metafields and metaobjects → Variants → Add definition**, name it `Badge`, type **Single line text**, **List of values**. Variant badges are listed before the product's own badges.

{% hint style="warning" %}
Product cards in collections and in sections read only the product-level metafield. A badge put on a variant will not show in the grid.
{% endhint %}

***

## Hiding badges

### Remove the Sale badge

Turn off **Show badge** under **Theme settings → Product badges → Sale**. This removes it across the store, cards and product pages alike, and no code is involved.

To keep the badge everywhere except one template — say, hide it on the collection page only — leave the setting on and add this to the **Custom CSS** field of that section (**Theme Editor → Collection page → Product grid → Custom CSS**):

```css
.card__badges-item--sale {
  display: none;
}
```

The same code in **Theme settings → Custom CSS** would hide it store-wide, which the Show badge checkbox already does more cleanly.

### On the product page

Badges next to the price are controlled by the **Show badges** checkbox in the **Title** and **Price** blocks of the product section. Turning it off hides every badge in that block — defaults and custom ones together — without affecting product cards.

<details>

<summary>Places where the theme hides badges on purpose</summary>

A few surfaces are too small or too dense for labels, so Volume suppresses them there:

* the search dropdown in its list layout;
* product cards inside the **News drawer**;
* **Complementary products** — badges are hidden over the image and shown next to the price instead.

This is part of the theme's styling rather than a setting, so changing it means custom CSS.

</details>

***

## Best practices

* **Keep badges short.** One or two words. Long text wraps onto a second line and pushes the next badge down over the image.
* **Do not use all four at once on the same product.** Three labels stacked in the corner of a card read as noise, and the Sale or Sold out badge gets lost among them.
* **Reserve one color per meaning.** If red means a discount, do not also use red for *NEW IN* — shoppers learn the colors faster than the words.
* **Check contrast on sold-out products.** Card images are dimmed when a product is out of stock, and a pale badge can disappear into them.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://staylime.com/docs/volume-themes/theme-settings/product-badges.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
