Structured data and social previews

How to add structured data for rich results

Structured data is the markup behind the rich results you see in Google: the star ratings, the prices, the FAQ drop-downs. A result with one of those takes up more room and pulls more clicks than two plain lines of text.

What it is

Structured data is a block of machine-readable markup (schema.org, usually as JSON-LD in the page head) that tells Google exactly what a page is: a product, an article, a recipe, a local business, an FAQ.

Why it costs you

Without it, Google reads your page as prose and shows a plain result. With it, and where the page qualifies, your result can carry a rating, a price, an image, or expandable questions. Those features stand out and earn more clicks at the same rank. No markup means you are competing for attention with one hand tied.

How to fix it

Add JSON-LD for the type that matches the page.

  • WordPress: Yoast and Rank Math output baseline schema (Article, Breadcrumb, Organization) automatically; for products or FAQs, a plugin like Schema Pro or the block-level FAQ block adds the rest.
  • Shopify: good themes include Product and Offer schema already. Check your result in the Rich Results Test. If it is thin, add the missing JSON-LD to the product template.
  • Hand-coded: drop a <script type="application/ld+json"> block in the head using schema.org’s vocabulary. Start with Organization on the homepage and the type that fits each template (Article, Product, LocalBusiness, FAQPage).

How to check your site

Paste a URL into Google’s Rich Results Test. It shows what structured data Google found and whether the page is eligible for a rich result. Search Console reports valid and broken items across the site.

What this looks like in practice

A recipe blog added Recipe schema (cook time, rating, image). Its results started showing the cook-time and star rating, and click-through on those pages climbed without any change in position.

Questions people ask

Does structured data improve ranking?
Not directly. It makes you eligible for rich results, which raise click-through, an indirect but real gain.
What if I add markup and no rich result appears?
Eligibility is not a guarantee; Google decides when to show one. Make sure the markup is valid and matches visible content, then give it time.

Does your site have this?

Check your site to see which pages could show a richer result.

See also

All SEO checks →