What Is JSON-LD? A Plain-English Guide to Structured Data for AI Search

CrawlTide Team
12 min read

Last updated: October 26, 2026

JSON-LD structured data code for Organization and WebSite schema, linked to Google and AI answer engines like ChatGPT.
Table of Contents

You have almost certainly seen a block of code like <script type="application/ld+json"> in an SEO guide and scrolled straight past it. That block is JSON-LD, and it quietly decides how clearly a machine understands your page. Search engines read it. AI answer engines like ChatGPT, Perplexity, and Google's AI Overviews read it too. When your page only implies what it is through headings and prose, a machine has to guess. JSON-LD lets you state it plainly, in a format built for exactly that job.

What JSON-LD actually is

JSON-LD stands for JavaScript Object Notation for Linked Data. Strip the jargon and it is a small block of structured data, written as JSON, that describes the things on your page: the organization behind the site, the article, the product, the breadcrumb trail. It follows the shared vocabulary at schema.org, so "@type": "Article" or "@type": "Organization" mean the same thing to every engine that reads them. A local bakery might describe its LocalBusiness, its opening hours, and its menu; a SaaS site might describe its Organization, its SoftwareApplication, and the Article you are reading right now.

The "Linked Data" part is the interesting bit. Each entity can carry an @id, a stable identifier, and reference other entities by that id. That is how you tell a machine that the article on this page was published by the organization described a few lines down, without repeating yourself. The result is a clean, unambiguous map of your page that a crawler does not have to reconstruct from context.

For years, structured data was mostly about rich results: star ratings, FAQ dropdowns, recipe cards. That still matters. But the larger shift is that AI answer engines now assemble responses from whatever they can parse confidently, and clean structured data is one of the easiest signals for them to trust. When an answer engine attributes a claim to a source, it has to be confident about who that source is, and structured data hands it that confidence directly instead of asking it to infer.

A model reading raw HTML has to work out what your page is about from layout and wording. Give it JSON-LD and there is nothing to work out. You have named the entities, typed them, and linked them together. That does not guarantee a citation, because nothing guarantees a citation. What it does is remove a specific failure mode: the one where a machine misreads or skips your page because it could not tell what it was looking at.

One caveat for Google specifically. Its guide to AI features in Search says "there's also no special schema.org structured data that you need to add" to appear in AI Overviews or AI Mode; a page needs to be indexed and eligible to be shown with a snippet. So treat JSON-LD as the way you state who you are, not as a switch for Google's AI features.

JSON-LD vs microdata and RDFa

Schema.org data can be written three ways: JSON-LD, microdata, and RDFa. Microdata and RDFa weave the markup into your visible HTML, attribute by attribute, which is fragile and painful to maintain. JSON-LD sits in a single script block, separate from the markup a user sees. You can add it, edit it, or move it without touching the page's layout.

Google recommends JSON-LD, and it is what most modern sites use, for one practical reason: it is the easiest format to add correctly and the hardest to break by accident. Google's introduction to structured data puts it as using "a format that's easiest for you to implement and maintain (in most cases, that's JSON-LD)," and adds that "all 3 formats are equally fine for Google, as long as the markup is valid." So there is no ranking reason to rip out working microdata, but new markup should be JSON-LD. When someone tells you to "add schema," they almost always mean add JSON-LD.

Is JSON-LD the same as JSON Schema?

No. The names are close and the two get mixed up constantly, but they do different jobs. JSON-LD is a W3C standard for writing linked data as JSON; the JSON-LD 1.1 specification has been a W3C Recommendation since 16 July 2020. JSON Schema is, in its project's own words, "a declarative language for defining structure and constraints for JSON data." It describes the shape data must have, and search engines do not read it from your pages.

You can tell them apart from the first few keys. An "@context" pointing at schema.org means JSON-LD. A "$schema" key pointing at json-schema.org, followed by "type": "object" and a "properties" list, means a JSON Schema document. The two do meet in one useful place: because a JSON-LD block is plain JSON, a developer can write a JSON Schema that every product template's JSON-LD must pass before a deploy, so a missing offers property fails the build instead of reaching production. That check runs in your pipeline, never on the page.

Comparison showing that without JSON-LD a machine must guess a page's meaning, while with JSON-LD it reads a clear Organization, WebSite, and Article entity map.

How to add JSON-LD to your site

You add JSON-LD as a script tag in the page's HTML, usually in the <head> or just before the closing </body>. Here is a compact Organization plus WebSite block, the kind you would render once from a shared layout so it appears on every page:

{
  "@context": "https://schema.org",
  "@graph": [
    { "@type": "Organization", "@id": "https://example.com/#organization",
      "name": "Example", "url": "https://example.com/",
      "logo": "https://example.com/logo.png" },
    { "@type": "WebSite", "@id": "https://example.com/#website",
      "name": "Example", "url": "https://example.com/",
      "publisher": { "@id": "https://example.com/#organization" } }
  ]
}

The @graph array holds multiple entities in one block. The shared @id values let them reference each other, so a machine reads one consistent entity instead of two loose objects. Render it from a single layout component and it stays identical across the whole site, which is the entire point. Adding it in one place also means one thing to test and one thing to fix, rather than a copy on every template quietly drifting out of sync.

Should you nest an item or reference it by @id?

Both work, so choose for maintenance. Google's structured data guidelines say Google Search "understands multiple items on a page, whether you nest the items or specify each item individually." Nest when one item clearly owns another and nothing else refers to it, like an article's author. Reference by @id when the same entity appears in several places, such as the organization that publishes every article. The JSON-LD 1.1 specification defines @id as the keyword "used to uniquely identify node objects."

The #organization fragment in the example is a convention, not a rule: the identifier only has to be stable and identical everywhere you use it. Change it on one template and the link between entities breaks without any validator complaining. Our guide to Organization schema covers what belongs in that central entity.

Can one page carry several JSON-LD blocks?

Yes, and most real pages do, because the theme, an SEO plugin and a reviews widget each print their own. That is fine as long as the blocks agree. Trouble starts when two of them describe the same entity differently, such as two Organization blocks with different names or logos, and Google does not document which one it trusts. Keep one owner per entity type: turn off structured data output in either the theme or the plugin, not both, and reference shared entities by @id rather than declaring them again.

Where should the script go, and can JavaScript add it?

Anywhere in the HTML, as far as Google is concerned. Its introduction describes JSON-LD as "embedded in a <script> tag in the <head> and <body> elements of an HTML page," so choose whichever spot your templates keep accurate most easily. Injection also works: Google "can read JSON-LD data when it is dynamically injected into the page's contents."

Two caveats come from Google's guide to generating structured data with JavaScript. If you use Google Tag Manager, use variables to pull values from the page "instead of duplicating the information in GTM," so the markup cannot contradict the content. And for Product markup, Google warns that dynamically generated markup "can make Shopping crawls less frequent and less reliable," so server-render it on product pages. When you test injected markup, give the Rich Results Test the URL rather than pasted code, as Google recommends.

What we saw adding structured data to our own site

We ran CrawlTide's AI readiness audit on crawltide.com, found that Organization and WebSite schema were missing site-wide, and added them as one shared JSON-LD block in the footer. Before, structured-data coverage sat at 40% of pages (17 of 43). After re-crawling, it was 98% (42 of 43), from a single component. Our AI readiness score rose from 104 to 134 out of 230.

Here is the honest part: our own visibility tracking still showed us absent from most AI answers afterward. JSON-LD made the site far more legible; it did not make AI recommend us overnight. It is a foundation, not a switch, and treating it as anything more oversells it.

We tested that claim directly. We asked ChatGPT "What is CrawlTide?" once the schema was live, and it answered accurately and cited crawltide.com:

CrawlTide is an AI-powered SEO analytics platform for improving a website’s search visibility. It combines technical site audits for broken links, missing tags, redirects, and thin content; keyword research and rank tracking; backlink and competitor analysis; content-gap identification; monitoring of brand visibility in ChatGPT and Google AI Overviews; and prioritized recommendations explaining what to fix first. It offers a free plan with limited projects, crawled pages, and AI credits.

That is the real payoff of structured data: when an engine already has a reason to describe your entity, it describes it correctly and attributes it to you. What the same engine still would not do is name us unprompted for a broad "best SEO tool" query. Legible is not the same as recommended, and JSON-LD buys you the first, not the second.

Common JSON-LD mistakes

A handful show up over and over:

  • Describing things that are not on the page. Your JSON-LD should match the visible content. Marking up a review or a price a user cannot see is the kind of mismatch that gets flagged.

  • Inventing sameAs, ratings, or reviews. Do not claim social profiles you do not maintain or ratings you have not earned. It is dishonest and it is detectable.

  • Forgetting @type. Every real entity needs a type. A @graph wrapper object itself does not, which quietly trips up some validators, including, for a while, our own.

  • Letting it drift. Markup added page by page slowly falls out of sync after a redesign. One shared block does not.

Which syntax errors stop JSON-LD from parsing?

JSON is stricter than JavaScript, and most broken blocks were edited by hand or pasted from a document. Six errors account for most of them:

  1. A trailing comma after the last property or array item. JavaScript forgives it; JSON does not.
  2. Curly quotes. Copying from a word processor turns straight quotes into typographic ones, which JSON does not accept as string delimiters.
  3. An unescaped double quote inside a value, such as a product name with an inch mark. Write it as \".
  4. Comments. JSON has no comment syntax, so a // note left for a colleague breaks the block.
  5. A missing comma between two properties, usually after someone adds a line in the middle of a block.
  6. The text </script> inside a value. The browser ends the script element there and the rest spills onto the page. If values come from a CMS field or user input, escape <, > and & as \u003c, \u003e and \u0026 when you serialize the JSON.

Each script block is parsed on its own, so one malformed block usually leaves the others readable. That is why a page can show some of its structured data in a checker and silently lose the rest.

Verify and monitor your JSON-LD

Once it is live, confirm a machine actually reads it the way you intended. Run the page through a validator or our schema markup checker to see the entities resolve, and use Google's Rich Results Test for eligibility. Then keep watching. Markup that silently disappears after a deploy is worse than markup you never shipped, because you now believe you are covered when you are not. Track your structured-data coverage over time, not just the day you add it.

Each check catches a different failure, so run all three on one URL per template. A checker that reads each block separately catches blocks that fail to parse and duplicate entities; ours lists the schema.org types it finds and flags any block that does not parse. The Schema Markup Validator (validator.schema.org) confirms every type and property name exists, because a misspelled property is still valid JSON and still means nothing. The Rich Results Test applies Google's required properties for a feature, which are stricter than schema.org's. Our comparison of schema markup testing tools covers the order to run them in.

Where JSON-LD fits

JSON-LD is one signal among many. Content quality, authority, links, and freshness still decide most of whether you get found and cited. What JSON-LD does is remove ambiguity cheaply and permanently, which makes every other signal easier for a machine to attach to the right entity. In practice that means fewer cases where an engine confuses your brand with a similarly named one, or credits your content to the wrong site.

If you are starting from nothing, do not try to mark up everything at once. Add one shared block with Organization and WebSite, render it from your layout so it covers every page, verify that it resolves, and stop there for now. That single change is the highest-leverage, lowest-risk piece of structured data most sites are still missing.

CrawlTide Team

CrawlTide is an AI-powered SEO platform that helps teams find and fix technical SEO issues, track keyword rankings, and optimize search performance.