Skip to content

How to Add Schema Markup and Get Rich Snippets in Google Search

How-To9 min readJanuary 20, 2025
Table of Contents

Schema markup is structured data added to your web pages that helps search engines understand your content at a semantic level — not just what words your page contains, but what type of content it is, who created it, what it is about, and how it relates to other entities on the web. This understanding enables Google to generate rich results: enhanced search listings that display star ratings, FAQ dropdowns, event dates, recipe information, product availability, and other visual elements directly in the SERP.

Rich results occupy significantly more visual space than standard blue links and have been shown to increase click-through rates by 20–30% in controlled studies across content types. The investment in learning schema markup pays dividends in improved SERP visibility that compounds over time.

This guide focuses on JSON-LD — Google's preferred and recommended format — and covers the schema types most relevant to SEO: Article, FAQPage, HowTo, Product, LocalBusiness, Event, Organization, BreadcrumbList, and Review. For each type, we show the required and recommended properties, provide code examples, and explain what rich result it unlocks.

How JSON-LD Schema Works

JSON-LD (JavaScript Object Notation for Linked Data) embeds structured data in a <script> tag in your HTML. Unlike Microdata (which requires wrapping HTML elements in schema attributes) and RDFa (which embeds data in HTML tag attributes), JSON-LD is completely separate from your visible HTML structure. This makes it easy to add, update, and maintain without touching your presentation code.

A basic JSON-LD block looks like this:

<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "Article",
  "headline": "Your Article Title",
  "datePublished": "2025-01-15",
  "author": {
    "@type": "Person",
    "name": "Author Name"
  }
}
</script>

The @context property tells parsers that you are using schema.org vocabulary. The @type identifies what kind of entity you are describing. All other properties are schema.org attributes specific to that type.

You can include multiple JSON-LD blocks on a single page — for example, an article page might include both an Article schema and a BreadcrumbList schema in separate script tags. Google processes all JSON-LD blocks on a page independently.

Where to place JSON-LD:

Google accepts JSON-LD in both the <head> and <body>. Placing it in the <head> is preferred — it is available to parsers immediately when the page loads and follows the convention of keeping metadata in the head section.

FAQPage Schema — Get FAQ Dropdowns in Google

FAQPage schema is among the most impactful schema types for content publishers. When Google decides to show FAQ rich results, your listing expands with 2–3 questions and answers that users can click to reveal. This expansion can double or triple the vertical height of your SERP listing.

Complete FAQPage JSON-LD example:

{
  "@context": "https://schema.org",
  "@type": "FAQPage",
  "mainEntity": [
    {
      "@type": "Question",
      "name": "What is schema markup?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "Schema markup is structured data added to HTML pages that helps search engines understand content. It enables rich results like FAQ dropdowns, star ratings, and event details in Google Search."
      }
    },
    {
      "@type": "Question",
      "name": "How do I add FAQ schema to my page?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "Add a JSON-LD script block to your page head with @type FAQPage and mainEntity containing an array of Question objects. Each Question needs a name (the question text) and an acceptedAnswer with the answer text."
      }
    }
  ]
}

Eligibility requirements:

The Q&A content must be visible on the page — not hidden or only in the script block. Questions must represent genuine user questions, not promotional content phrased as questions. Pages with primarily advertising content are ineligible.

Generate FAQ schema markupCreate FAQPage JSON-LD ready to paste into your page

Article Schema — Qualify for Top Stories

Article schema (and its subtypes NewsArticle and BlogPosting) signals editorial content metadata to Google, making pages eligible for the Top Stories carousel, Google News, and Google Discover. These placements drive substantial traffic for news publishers and content-focused websites.

Complete Article JSON-LD example:

{
  "@context": "https://schema.org",
  "@type": "Article",
  "headline": "Your Article Headline (max 110 chars for News)",
  "datePublished": "2025-01-15T09:00:00+00:00",
  "dateModified": "2025-01-20T14:30:00+00:00",
  "author": {
    "@type": "Person",
    "name": "Author Name",
    "url": "https://yourdomain.com/about/author-name"
  },
  "publisher": {
    "@type": "Organization",
    "name": "Your Site Name",
    "logo": {
      "@type": "ImageObject",
      "url": "https://yourdomain.com/logo.png",
      "width": 600,
      "height": 60
    }
  },
  "image": "https://yourdomain.com/article-image.jpg",
  "mainEntityOfPage": {
    "@type": "WebPage",
    "@id": "https://yourdomain.com/article-slug"
  }
}

Key fields for Top Stories eligibility:

The publisher Organization with a logo, the author Person entity, and correct ISO 8601 dates (with timezone offsets) are all required. The image should be at least 1200px wide for the carousel. Use dateModified every time you update the article — Google uses this for freshness ranking.

Generate Article schema markupBuild complete Article JSON-LD with all required fields

HowTo Schema — Step-by-Step Rich Results

HowTo schema enables rich results for instructional content — step-by-step guides appear with numbered steps, images, and time estimates directly in the SERP. This is particularly effective for DIY, cooking, technical guides, and tutorial content.

HowTo JSON-LD structure:

{
  "@context": "https://schema.org",
  "@type": "HowTo",
  "name": "How to Create an XML Sitemap",
  "description": "A step-by-step guide to creating an XML sitemap for your website.",
  "totalTime": "PT10M",
  "step": [
    {
      "@type": "HowToStep",
      "position": 1,
      "name": "List your URLs",
      "text": "Compile all the URLs on your website that you want included in the sitemap."
    },
    {
      "@type": "HowToStep",
      "position": 2,
      "name": "Generate the sitemap",
      "text": "Use a sitemap generator to create the XML file with proper formatting and attributes."
    },
    {
      "@type": "HowToStep",
      "position": 3,
      "name": "Submit to Google",
      "text": "Upload the sitemap to your server root and submit the URL in Google Search Console."
    }
  ]
}

The totalTime uses ISO 8601 duration format: PT10M means 10 minutes, PT1H means 1 hour, PT1H30M means 1 hour 30 minutes. Include an image in each step when you have step-specific screenshots or illustrations — images significantly increase the richness of the SERP display.

Product and Review Schema — E-Commerce Rich Results

Product schema enables star ratings, price, and availability to appear alongside product pages in Google search results — a significant conversion driver for e-commerce. Combined with Review or AggregateRating schema, the result is a full rich snippet with visual stars and review count.

Product with AggregateRating:

{
  "@context": "https://schema.org",
  "@type": "Product",
  "name": "Product Name",
  "image": "https://example.com/product.jpg",
  "description": "Product description here",
  "brand": {
    "@type": "Brand",
    "name": "Brand Name"
  },
  "offers": {
    "@type": "Offer",
    "price": "29.99",
    "priceCurrency": "USD",
    "availability": "https://schema.org/InStock"
  },
  "aggregateRating": {
    "@type": "AggregateRating",
    "ratingValue": "4.5",
    "reviewCount": "128"
  }
}

Google's review policy:

Reviews in Product schema must reflect genuine user reviews. Review gating (only showing positive reviews), incentivized reviews, or reviews written by the site owner are violations of Google's structured data guidelines and can result in rich result removal or manual penalties. Only mark up authentic, third-party reviews.

Validating Schema Markup Before Publishing

Always validate your schema markup before adding it to a live page. Invalid schema is ignored silently — it produces no error in the browser, no warning to users, and no rich results. The only way to know your schema is valid is to test it explicitly.

Google's Rich Results Test:

Go to search.google.com/test/rich-results and paste either your URL (for live pages) or your JSON-LD code directly. The tool shows which schema types were detected, whether they are valid, and whether each type is eligible for rich results. It also lists any warnings for recommended but missing properties.

Schema.org Validator:

The Schema.org Validator at validator.schema.org checks your markup against schema.org specifications independently of Google's rich result requirements. Use it to catch schema.org compliance issues that Google's tool may not flag.

Common validation errors:

  • Missing required properties (datePublished for Article, offers for Product)
  • Invalid date formats (use ISO 8601 with timezone: 2025-01-15T09:00:00+00:00)
  • URLs not starting with https (images and entityOfPage URLs must be absolute HTTPS)
  • Array format errors (mainEntity must be an array for FAQPage, not a single object)
  • Nested type errors (acceptedAnswer must use @type Answer, not a plain string)

After fixing validation errors, test again. Only after the Rich Results Test shows a green checkmark and eligible rich result types should you consider the markup complete.

Generate any schema typeBuild valid JSON-LD for Article, FAQ, HowTo, and more

Frequently Asked Questions

Does schema markup improve rankings directly?
Schema markup is not a direct ranking factor in Google's core algorithm. However, it enables rich results that improve click-through rates, which sends positive user engagement signals to Google. Better CTR from rich results can indirectly improve rankings over time. Think of schema as improving your SERP presentation, not your domain authority.
Which schema types get rich results in Google?
Google supports rich results for these schema types: Article, Book, Breadcrumb, Carousel, Course, Dataset, Education Q&A, Event, FAQ, How-to, Image Metadata, Job Posting, Learning Video, Local Business, Logo, Math Solvers, Movie, Practice Problems, Product, Q&A, Recipe, Review Snippet, Sitelinks Searchbox, Software App, Speakable, Subscription, and Video. Not all are common for typical websites — FAQ, Article, Product, HowTo, and LocalBusiness are most impactful for content and e-commerce sites.
How long does it take for schema markup to show rich results?
Rich results typically appear within a few days to a few weeks after Google recrawls the page with the schema markup. The timeline depends on Google's crawl frequency for your site, which increases with site authority and publication frequency. You can request recrawling via Google Search Console's URL Inspection tool after adding markup.
Can I use schema markup on every page?
Add schema markup to every page where a relevant type applies. Use Article or BlogPosting on all editorial content. Use Product on all product pages. Use FAQ on all pages with Q&A sections. Use BreadcrumbList on every page for site structure. The more accurately and completely you implement schema across your site, the stronger your overall structured data footprint.
What happens if my schema markup has errors?
Schema markup with validation errors is silently ignored by search engines — it produces no rich results, no error messages to users, and no ranking penalties unless the markup is deliberately misleading (which does risk manual action). Fix errors using Google's Rich Results Test and resubmit for crawling. Incorrect schema is a missed opportunity, not a penalty trigger.

Summary

Schema markup transforms your search listings from plain blue links into rich, visually enhanced results that stand out in a crowded SERP. The implementation investment is modest — a JSON-LD block in your page head — but the return in improved visibility and click-through rate is measurable and sustained.

Start with the highest-impact types for your content category: FAQPage for any page with question-and-answer sections, Article for editorial content, and Product with AggregateRating for e-commerce. Add BreadcrumbList to all pages for site structure clarity. Validate every implementation before publishing. Monitor rich result performance in Google Search Console's Enhancements section to track which pages are generating rich results and catch any new errors as Google's requirements evolve.

Try these tools

Related guides

All Guides