How to Generate Meta Titles and Descriptions for Thousands of Products in Magento 2
-
Oleksandr Drok
- SEO
- Updated: Nov 17, 2026
- 7 min read
Rewritten around the bulk question: why Magento's native auto-generation skips existing products, and three ways to fill meta titles and descriptions for a whole catalog.
Magento 2 can generate meta titles and descriptions on its own, but only for products you create from now on. The native Product Fields Auto-Generation setting (Stores > Configuration > Catalog > Catalog) fills the fields once, when a new product is created in the admin form. It has no conditions and doesn't touch the thousands of products you already have.
For an existing catalog, you have three working options:
| Approach | Covers existing products | Conditions per category or attribute | Keeps up with new products |
|---|---|---|---|
| Native Product Fields Auto-Generation | No | No | Only products created in the admin form |
| Export to CSV, rewrite, import back | Yes | Whatever you do in the spreadsheet | No, you repeat the export |
| SEO meta templates (Advanced SEO Suite) | Yes | Yes | Yes |
AI generation fits into either of the last two: as a source for the CSV, or as a fixer for the pages that templates leave weak. Here's how each one works and where it breaks.
What native auto-generation does (and why it skips your catalog)
Go to Stores > Configuration > Catalog > Catalog > Product Fields Auto-Generation. You'll see four masks: SKU, Meta Title, Meta Keywords and Meta Description. Out of the box, the meta title mask is {name} and the meta description mask is {name} {description}.
The limits come from how the masks work:
- New products only. The mask fills a field in the product form as you type the product name. On a product that already exists, it does nothing.
- Admin form only. The masks run inside the product edit form. Products created by CSV import or through the API don't get them.
- No conditions. One mask for the whole catalog: shoes, spare parts and gift cards all get the same pattern.
- No store view scope. The masks are set once at the default level, so a multilingual store can't have a separate pattern per language.
- Long descriptions.
{description}pastes the whole product description with HTML removed. The mask doesn't trim it to snippet length.
And one side effect matters later: whatever the mask generates is saved into the product's own meta fields, just as if you'd typed it.
Option 1: export, rewrite, import
If you need meta stored in the product records, a CSV round trip is the native way:
- Export products in System > Data Transfer > Export (entity type: Products).
- Fill the
meta_titleandmeta_descriptioncolumns with spreadsheet formulas or with text generated by an AI tool. - For translated store views, add rows with the
store_view_codecolumn set to that store view. - Import the file back in System > Data Transfer > Import.
It works, but it's a snapshot. Next month's new products arrive without meta, and if you change a brand name or a pattern, you run the whole loop again.
Option 2: SEO meta templates with conditions
A meta template is a rule: "for products that match these conditions, build the meta title and description from this pattern". The Advanced SEO Suite applies templates when a page is rendered rather than writing them into product records. A saved template covers every matching product at once, old and new, and nothing needs to be re-imported.
Templates work for more than products. The same template manager covers categories, CMS pages and layered navigation pages (a category with filters applied), which native Magento gives you no meta fields for at all.

How to create a product meta template
- Go to Marketing > Advanced SEO Suite > Templates and click Add template.
- Enter an Internal name, set Type to Products and choose the Store view. The type can't be changed after saving, so click Save and continue edit to get the product settings.
- Turn on Is active and set the Sort order (more on priority below).
- Fill in Meta title, Meta description, and if you want, Meta keywords and Title (H1) using variables.
- In Conditions, narrow the template to the products it's meant for. Leave it empty to cover all products.
- Click Preview template to see the result on 5 random products, or enter specific product IDs to check the ones you're worried about.
- Save the template and clean the Magento cache.
Variables: build the text from product data
Any product attribute works as a variable in the form [product_{attribute_code}], for example [product_color] or [product_material]. On top of that, there are ready-made ones such as [product_name], [product_sku], [product_final_price_minimal], [product_category_name] and [store_name].
Not every product has every attribute filled in. Wrap the optional part in square brackets with the variable in curly braces, and the whole chunk disappears when the value is empty:
Meta title: [product_name][ in {product_color}] | [store_name]
Meta description: Order [product_name][ by {product_manufacturer}] from [store_name].[ Material: {product_material}.]
A product with no color gets "Trail Runner 2 | Your Store" instead of "Trail Runner 2 in | Your Store".
Conditions: different patterns for different products
This is where templates beat a single mask. Conditions can check the Category, Attribute set, Product type, and any attribute that has Use for Promo Rule Conditions set to Yes in its properties. If an attribute you need isn't in the list, that flag is the reason.
A typical setup is a general template for all products plus narrower ones for categories where the general pattern reads badly: spare parts with the part number in the title, apparel with color and size. Turn on Apply to child categories so a template set for "Shoes" also covers "Shoes > Running".
Which meta wins: priority and order
When several sources could set the meta title of the same page, this is the order:
- The product's own meta fields, if they're filled and Use existing meta tags is enabled for product pages (it is by default).
- SEO rewrites: meta set by hand for one specific URL in Marketing > Advanced SEO Suite > SEO Rewrites.
- Templates. If several templates match, the one with the higher Sort order wins. A template with Stop further rules processing takes precedence over templates without it.
Here's the trap for an existing catalog. If native masks or an old import already filled meta for your products, those stored values beat the template, and the template looks like it doesn't work. To let templates take over, go to Stores > Configuration > Mirasvit extensions > SEO Templates and rewrites > Use existing meta tags and set Product pages to No. For the handful of best sellers where you want handwritten meta, use an SEO rewrite for that URL: it still wins over the template.
Option 3: AI generation for the pages templates can't fix
Templates are consistent, but a pattern can't write a good description for a product whose attributes are half empty. The Advanced SEO Suite covers that gap with its SEO AI helper, which works off the SEO audit:
- The audit crawls your store and flags empty, short, long and duplicate meta titles and descriptions. It counts a title as too short under 50 characters and too long over 70; for descriptions the range is 110–160.
- For each flagged URL, the AI helper asks the model to write a new title or description and saves the result as an SEO rewrite for that URL. You choose the provider: OpenAI, Anthropic Claude or Google Gemini.
- With Automatically fix meta-related issues and Enable cron task turned on in the SEO audit settings, it runs every 30 minutes. You can also run it on demand with
bin/magento mirasvit:seo-ai:fix-audit-meta --limit 100. - It never overwrites a rewrite you wrote by hand, and
--resetremoves everything it generated.
So the split is: templates for the bulk of the catalog, the AI helper for the pages the audit still flags afterwards.
Checklist before you roll it out
- Length. Write patterns that fit 50–70 characters for titles and 110–160 for descriptions with a typical product name. Content and meta length settings in the same config section can crop longer values, but it cuts at an exact character count, even mid-word, and it's off by default.
- Uniqueness. Configurable products and their variants often share a name, so
[product_name]alone produces duplicate titles. Add the attribute that tells them apart: color, size or SKU. - Store views. Native masks have one value for all languages. Create a template per store view instead, or use
store_view_coderows if you go the CSV route. - Empty values. Wrap every optional variable in
[ ... ], then preview products with sparse attributes before saving. - What you'll see in the admin. Template output isn't saved into product records, so the product grid and CSV exports still show the old meta fields. Check the storefront page, not the product form.
Need meta keywords too? See our guide to Magento meta keywords: what the field still does and how to fill it automatically.
FAQ
Does Magento 2 generate meta titles and descriptions automatically?
Only for new products. The masks in Stores > Configuration > Catalog > Catalog > Product Fields Auto-Generation fill the meta fields while you create a product in the admin form. Existing products and products created by CSV import or the API aren't affected.
How do I update meta titles for existing products in bulk?
Either export products to CSV, fill the meta_title and meta_description columns and import the file back, or use meta templates that build the text from product attributes and apply to every matching product without an import.
Why does my SEO meta template not change the product meta title?
The product probably has its own meta title stored, for example from native auto-generation or an old import. With Use existing meta tags enabled for product pages, the stored value wins. Set it to No to let templates take over.
From meta tags to the sitemap, the Magento 2 SEO Extension gives you full control over every SEO-related feature in your store.
It automates the SEO work you'd otherwise do by hand - templated meta tags, rich snippets, redirects, sitemaps, cross-links and a built-in SEO audit - across every page type. That is why 2,435+ Magento stores rely on it.