The SEO Patterns API allows you to read and write a Wix site's SEO patterns: the templates that generate SEO tags for every item of a page type. A pattern is written once for a page type, such as every store product or every blog post, and its tags contain variables, such as {{product.name}}, that are filled in with each item's own values when its page renders. Changing one pattern therefore changes the tags of every page of that type that doesn't have SEO tags set for the item itself.
With the SEO Patterns API, you can:
Wix builds the tags a page renders with by combining several sources, where a later source takes precedence:
So a pattern decides an item's tags only where the item has none of its own. To see the tags a specific item is expected to render with, and which source each one came from, read resolvedTags on that item with the Item SEO Tags API.
A pattern is stored where the live site reads it, so a change takes effect without a site publish.
A pattern has no revision, and a Wix user editing SEO patterns in the dashboard writes to the same patterns as this API. If both change a pattern at once, whichever lands second overwrites the other, with no conflict error. When a Wix user may be editing at the same time, retrieve the pattern immediately before writing it.
Pages built from a Wix Data collection are the one case where a page type holds more than one pattern: each such page can have a pattern of its own. To address one of them, specify its ID in pageId, with a page type of WIX_DATA_PAGE_ITEM.
Every other page type has a single pattern for the whole type, and specifying a page ID for one of those fails rather than being ignored. collectionName isn't supported yet, so address a dynamic page by its ID instead.
It's important to note the following points before starting to code:
source says which of the two is in effect.{{product.name}}, for example, while a page built from a Wix Data collection offers {{wix-data-page-item.main-collection-primary-field}}. Call List SEO Pattern Variables for each page type rather than reusing a name.pattern replaces the page type's tag templates in full. Retrieve the pattern first and send back the complete set you want it to have.BLOG_POST or STORES_PRODUCT, that business solution must be installed on the site. Get SEO Pattern, List SEO Pattern Variables, and Create SEO Pattern fail when it isn't. Set SEO Pattern and Reset SEO Pattern To Default don't apply that check, so a pattern stored before a business solution was uninstalled stays readable and editable.{{product.name}}, written in double braces, that's replaced with an item's own value when its page renders. Each page type offers its own set.Last updated: 12 August 2026