Glossary
Structured data (JSON-LD and schema.org)
Structured data is information on a web page that is written for machines as well as people. The most common form is JSON-LD: a block of JSON inside a script tag that uses the schema.org vocabulary to say what the page is about, such as a product, a job posting or an article.
What it looks like
A fictional product page might carry this block. The values mirror what a shopper sees on the page.
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Product",
"name": "Desk lamp, matte black",
"sku": "LAMP-0420",
"offers": {
"@type": "Offer",
"price": "49.00",
"priceCurrency": "USD",
"availability": "https://schema.org/InStock"
}
}
</script>
JSON-LD is one syntax. Microdata and RDFa put the same vocabulary into HTML attributes. Many sites also embed the data their own front end uses as JSON in the page, which is not schema.org but often holds the same values.
Good source, with limits
When a page has complete, correct JSON-LD it is the cleanest way to read it: typed fields and no HTML parsing. It rarely tells the whole story:
- Sites add it for search engines, so it covers what search features use, such as price, rating or job title, and often leaves out the rest of the page.
- It can be stale or wrong. Templates and caches can disagree with the visible page, so compare a sample against what a visitor sees.
- It is often present on single-item pages and missing from the list pages that link to them.
- Which properties appear, and how they are typed, varies from site to site and even from page to page.
- Being machine-readable is not permission to reuse. The site's terms and robots.txt still apply.
In CleanedWeb
A site does not need to publish JSON-LD for CleanedWeb to build an API from it. Inspection reads the collection page and proposes the fields it finds, you review and keep the ones you need, and the saved output schema defines their names and types. The website data checker shows what a site already publishes for machines (JSON-LD, embedded JSON, feeds, sitemap and robots.txt rules) before you decide how to get the data.
Tools and docs
- Website data checker Enter a URL to see the structured data, feeds and sitemap a crawler finds.
- JSON Schema generator Turn sample records into a schema, TypeScript types or Pydantic models.
- Fields and schemas How CleanedWeb describes the fields and types an API returns.
Related terms
-
Sitemap
The XML file that lists a site's URLs, and how to use it to find pages and spot changes.
-
JSON Schema
A way to describe the shape of JSON records and validate each response against it.
-
Web scraping vs API
Scraping pages versus calling an API: when each fits and what scraping costs to maintain.
-
llms.txt
A proposed Markdown file that gives AI systems a short guide to a site's best pages.
Build an API from a website
CleanedWeb turns a website into a maintained REST API that returns structured records, with a versioned schema and repairs when the site changes.