How to set up meta tag templates and use variables

A meta tag template is one pattern for the meta titles and meta descriptions of a page type, with variables that the app replaces by each page's own data. This article shows how to write a template, which variables you can use, how the preview works and what the app checks before it saves.

Before you start

Create and save a template

  1. Go to On-page settings and open Meta tags.
  2. In Page type, choose a type. If it has no template yet, you see "No products template yet" (or the same for another type).
  3. Select Create product template. A starter template is added, for example the page title, a separator and your store name for the title, and the first sentence of the description for the description.
  4. Edit Meta title and Meta description. Select a variable chip to add the variable to the end of the field you edited last. A toast confirms the insert.
  5. Check the preview on the right, then save. The toast says "Template saved".

You can write only a title template or only a description template.

Variables by page type

Write a variable as {{ product.title }}. Spaces inside the braces do not matter.

Page type Variables
Products product.title, product.type, product.vendor, product.price, product.description, variant.option1, shop.name
Collections collection.title, collection.description, shop.name
Pages page.title, page.content, shop.name
Blog posts article.title, article.excerpt, blog.title, shop.name

Details:

How the result is built

Use the preview

The preview shows a Google-style result built from one real page. To change the page, select Change next to Preview with and pick another in the dialog Preview the template on. You can search by title or handle and sort the list. Select Use this product (or the matching type) to update the preview.

The title note reads "As Google sees it: N / 60 characters". If your theme adds your store name, the note says which text it adds.

What the app checks before saving

Message What to fix
"product.colour" isn't a variable. Use product.type or a product option. Use a variable from the table above
Every product would get this same text, and "2026" goes out of date. Add a product variable such as {{ product.title }} and leave out the year. Add a variable that differs on each page and drop the year
"2026" goes out of date. Leave out the year. Remove a fixed year
Check the {{ }} around each variable. Close every {{ with }} and use only the filter above
Write a meta title or a meta description template. Fill at least one field

Apply the template

Under Apply to existing products (or another type), select the apply button, choose which fields the template may write and confirm. A progress bar shows the job. You can undo it from History.

[!INFO] New products and collections can also be filled automatically. See How to fill new products and collections automatically.

The Coverage card on the right shows how many meta descriptions were written by you, by a template or by import.

Related articles

How to fill new products and collections automatically →