Structured Data and JSON-LD: Practical SEO Implementation Guide

前端工程

Structured data helps search engines understand what a page is about. JSON-LD is the most common way to add it because it keeps machine-readable data separate from the visible HTML.

Structured data can make a page eligible for enhanced search features, but it does not guarantee rich results. Google and other search engines decide what to show based on page quality, query intent, eligibility rules, and many other signals.

Useful references:

What Structured Data Does

Structured data gives explicit meaning to page content. Instead of only seeing text, a search engine can understand that a page is an article, a product, a software application, a breadcrumb trail, an FAQ section, or another recognized entity type.

Good structured data should:

  • Match the visible content on the page.
  • Use the most specific relevant Schema.org type.
  • Include required and recommended properties.
  • Stay accurate when content changes.
  • Be validated before deployment.

Do not use structured data to describe content that users cannot see. That is a common quality problem and can make markup ineligible.

Why JSON-LD Is Usually The Best Format

There are several structured data formats, but JSON-LD is usually easiest to maintain.

Format How it is added Maintenance
JSON-LD A <script type="application/ld+json"> block Clean and separate from HTML
Microdata Attributes inside HTML elements Easy to break during template changes
RDFa Attributes inside HTML elements Powerful but more complex

With JSON-LD, frontend markup can change without rewriting every structured data attribute.

Basic JSON-LD Pattern

<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "Article",
  "headline": "Structured Data and JSON-LD: Practical SEO Implementation Guide",
  "description": "Learn how to add JSON-LD structured data safely.",
  "author": {
    "@type": "Person",
    "name": "Sarah Miller"
  },
  "datePublished": "2026-07-16",
  "dateModified": "2026-07-16"
}
</script>

The core fields are:

  • @context: normally https://schema.org.
  • @type: the Schema.org type, such as Article.
  • Properties: fields that describe the entity, such as headline, author, or datePublished.

Article Markup

Use Article, BlogPosting, or NewsArticle for editorial content. Pick the type that best matches the page. For normal blog posts, BlogPosting is often appropriate.

<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "BlogPosting",
  "headline": "How to Split a PDF Safely",
  "description": "A practical guide to extracting and splitting PDF pages.",
  "image": "https://example.com/images/pdf-split-guide.png",
  "author": {
    "@type": "Person",
    "name": "Rachel Kim"
  },
  "publisher": {
    "@type": "Organization",
    "name": "Example Tools",
    "logo": {
      "@type": "ImageObject",
      "url": "https://example.com/logo.png"
    }
  },
  "datePublished": "2026-07-16",
  "dateModified": "2026-07-16",
  "mainEntityOfPage": {
    "@type": "WebPage",
    "@id": "https://example.com/blog/pdf-split-guide"
  }
}
</script>

Keep dates honest. Do not update dateModified just to make content look fresh unless the page actually changed.

Breadcrumb structured data helps search engines understand page hierarchy.

<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "BreadcrumbList",
  "itemListElement": [
    {
      "@type": "ListItem",
      "position": 1,
      "name": "Home",
      "item": "https://example.com/"
    },
    {
      "@type": "ListItem",
      "position": 2,
      "name": "Blog",
      "item": "https://example.com/blog"
    },
    {
      "@type": "ListItem",
      "position": 3,
      "name": "PDF Split Guide",
      "item": "https://example.com/blog/pdf-split-guide"
    }
  ]
}
</script>

The breadcrumb trail in JSON-LD should match the navigation users can understand on the page.

FAQPage Markup

Only add FAQPage markup when the page actually contains visible questions and answers. Do not add fake FAQs just to target rich results.

<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "FAQPage",
  "mainEntity": [
    {
      "@type": "Question",
      "name": "Does structured data guarantee rich results?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "No. Structured data can make a page eligible, but search engines decide whether to show enhanced results."
      }
    },
    {
      "@type": "Question",
      "name": "Should JSON-LD match visible page content?",
      "acceptedAnswer": {
        "@type": "Answer",
        "text": "Yes. Markup should describe content that users can also see on the page."
      }
    }
  ]
}
</script>

FAQ markup is not a shortcut to extra search space. Use it only when it improves clarity for users.

SoftwareApplication Markup

For online tools, apps, or downloadable software, SoftwareApplication can describe what the page offers.

<script type="application/ld+json">
{
  "@context": "https://schema.org",
  "@type": "SoftwareApplication",
  "name": "PDF Split Tool",
  "applicationCategory": "UtilitiesApplication",
  "operatingSystem": "Web",
  "url": "https://example.com/pdf/split",
  "description": "Split a PDF into selected pages or smaller files in the browser.",
  "offers": {
    "@type": "Offer",
    "price": "0",
    "priceCurrency": "USD"
  }
}
</script>

Only include fields that are true. If you add ratings, reviews, prices, or platform claims, they must be supported by visible page content and your actual product state.

Multiple JSON-LD Blocks

You can include more than one structured data entity on a page. For example, a blog article can also have breadcrumbs.

Either use separate script blocks:

<script type="application/ld+json">{ "...Article data..." }</script>
<script type="application/ld+json">{ "...Breadcrumb data..." }</script>

Or use an array:

<script type="application/ld+json">
[
  { "@context": "https://schema.org", "@type": "BlogPosting" },
  { "@context": "https://schema.org", "@type": "BreadcrumbList" }
]
</script>

Separate blocks are often easier to generate from templates.

Validation Workflow

Use a simple workflow before publishing:

  1. Generate JSON-LD from the same source data used by the page.
  2. Check that the markup is valid JSON.
  3. Run the URL or code through the Rich Results Test.
  4. After indexing, monitor structured data reports in Search Console.
  5. Re-check templates after major design, routing, or CMS changes.

Validation passing means the syntax and some eligibility rules are satisfied. It still does not guarantee a rich result.

Common Mistakes

Markup Does Not Match Visible Content

If JSON-LD says the page has reviews, FAQs, prices, or author details, users should be able to verify those details on the page.

Wrong Type

Do not use Product for every tool page just because product rich results look attractive. Use the type that matches the page.

Fake Or Unsupported Ratings

Review and rating markup needs real visible reviews. Do not invent aggregate ratings.

Dates Are Inconsistent

datePublished and dateModified should match the actual content lifecycle. Update modified dates only when meaningful changes happen.

Broken URLs

Image, logo, canonical, and page URLs should be absolute, crawlable, and stable.

Locale Mismatch

For multilingual sites, each localized page should have structured data in the same language as the page, with the correct canonical and alternate links handled elsewhere in the page.

Implementation Tips

  • Generate structured data from your CMS or page metadata, not by hand on every page.
  • Escape user-generated text correctly so JSON remains valid.
  • Keep one reusable template for each page type.
  • Test representative pages, not only the homepage.
  • Revalidate after changing routes, slugs, author profiles, or image generation.
  • Treat warnings as opportunities to improve, but prioritize errors first.

Final Checklist

Before shipping JSON-LD, confirm:

  • The markup describes visible page content.
  • The Schema.org type fits the page.
  • Required fields are present.
  • URLs are absolute and crawlable.
  • Dates, authors, titles, and descriptions match the page.
  • The page passes the Rich Results Test where applicable.
  • Search Console is monitored after deployment.

Structured data is not a trick for forcing richer search results. It is a clean way to make page meaning explicit. When it is accurate, maintained, and aligned with the visible page, it improves the chance that search engines understand the content correctly.

Try these browser-local tools — no sign-up required →

#JSON-LD#结构化数据#SEO#Schema.org#富摘要