Spin Syntax

Written By Minh

Last updated 1 day ago

Spin Syntax lets you create content variations so that not every page reads the same way. You write multiple options for a word or phrase, and SEOmatic randomly picks one for each page during generation.

Quick Example

Your field template:

[Best|Top|Leading] {{ Service }} in {{ City }}

Generated output:

  • Page 1: "Best Plumbing in New York"

  • Page 2: "Leading Roofing in Chicago"

  • Page 3: "Top Landscaping in Miami"

Same structure, different wording - making each page feel more unique.

Syntax

Wrap your options in square brackets, separated by pipes:

[option1|option2|option3]

You need at least two options. Spaces around pipes are trimmed automatically, so [option1 | option2] works fine. Nesting (spin syntax inside spin syntax) is not supported.

How to Use Spin Syntax

Type [option1|option2] in any text field and it automatically converts into a gray badge showing your variations. Click the badge to edit them.

Spin Syntax works in text fields - single-line, multi-line, and rich text. It does not work in dropdowns, toggles, color pickers, or file fields. You can use Dynamic Variables and AI Generation alongside Spin Syntax - for example:

 genText("Write a short intro for [a|the best|a top-rated] {{ Service }} company in {{ City }}")

Each spin block picks a random option every time you generate. If your field has multiple spin blocks, each one is resolved independently.

Tips

  • Use it for natural variation. Words like "best", "top", "leading", "premier" or phrases like "get in touch", "contact us", "reach out" are good candidates.

  • Don't overdo it. One or two spin blocks per field keeps content readable. Too many makes it hard to review.

Troubleshooting

Problem

Solution

Spin syntax appears as plain text

Make sure you have square brackets on both sides and at least one pipe between options: [option1|option2]

β€œEmpty variation found" error

You have an extra pipe with nothing after it. Remove any || or trailing | in your syntax.

"No variations found" error

You need at least two options separated by a pipe. [single_option] is not valid.

Badge shows but content isn't varying

Each generation picks randomly. With only two options, you may see the same one often. Add more variations for more diversity.