Download as pdf or txt
Download as pdf or txt
You are on page 1of 5

Understand how structured data works

Google Search works hard to understand the content of a page. You can help us by
providing explicit clues about the meaning of a page to Google by including structured data
on the page. Structured data is a standardized format for providing information about a
page and classifying the page content; for example, on a recipe page, what are the
ingredients, the cooking time and temperature, the calories, and so on.

Google uses structured data that it @nds on the web to understand the content of the page,
as well as to gather information about the web and the world in general. For example, here is
a JSON-LD (https://json-ld.org) structured data snippet that might appear on a recipe page,
describing the title of the recipe, the author of the recipe, and other details:

<html>
<head>
<title>Party Coffee Cake</title>
<script type="application/ld+json">
{
"@context": "https://schema.org/",
"@type": "Recipe",
"name": "Party Coffee Cake",
"author": {
"@type": "Person",
"name": "Mary Stone"
},
"datePublished": "2018-03-10",
"description": "This coffee cake is awesome and perfect for parties.",
"prepTime": "PT20M"
}
</script>
</head>
<body>
<h2>Party coffee cake recipe</h2>
<p>

<i>by Mary Stone, 2018-03-10</i>


</p>
<p>
This coffee cake is awesome and perfect for parties.
</p>
<p>
Preparation time: 20 minutes

https://developers.google.com/search/docs/advanced/structured-data/intro-structured-data 01/04/22, 3=42 PM


Page 1 of 5
Preparation time: 20 minutes
</p>
</body>
</html>

Google Search also uses structured data to enable special search result features and
enhancements (/search/docs/guides/search-gallery). For example, a recipe page with valid
structured data is eligible to appear in a graphical search result, as shown here:

Search appearanceStructured data (#structured-data)


(#search-appearance)

Note: The actual appearance in search results might be different. You can preview most features with the

Rich Results Test (https://support.google.com/webmasters/answer/7445569).

Because the structured data labels each individual element of the recipe, users can search
for your recipe by ingredient, calorie count, cook time, and so on.

Structured data is coded using in-page markup on the page that the information applies to.

https://developers.google.com/search/docs/advanced/structured-data/intro-structured-data 01/04/22, 3=42 PM


Page 2 of 5
Structured data is coded using in-page markup on the page that the information applies to.
The structured data on the page describes the content of that page. Don't create blank or
empty pages just to hold structured data, and don't add structured data about information
that is not visible to the user, even if the information is accurate. For more technical and
quality guidelines, see the Structured data general guidelines (/search/docs/guides/sd-policies).

The Rich Results Test (https://search.google.com/test/rich-results) is an easy and useful tool for
validating your structured data, and in some cases, previewing a feature in Google Search. Try it out:

Try it out in the Rich Results Test

Structured data format

This documentation describes which properties are required, recommended, or optional for
structured data with special meaning to Google Search. Most Search structured data uses
schema.org (https://schema.org/) vocabulary, but you should rely on the Google Search
Central documentation as de@nitive for Google Search behavior, rather than the schema.org
documentation. There are more attributes and objects on schema.org that aren't required by
Google Search; they may be useful for other services, tools, and platforms.

As of January 29, 2021, data-vocabulary.org markup will no longer be eligible for Google rich result
features. To be eligible after January 29, 2021, you need to replace data-vocabulary.org markup with
schema.org markup. Learn more about sunsetting support for data-vocabulary
(/search/blog/2020/01/data-vocabulary).

Be sure to test your structured data using the Rich Results Test
(https://search.google.com/test/rich-results) during development, and the Rich result status
reports (https://support.google.com/webmasters/answer/7552505) after deployment, to monitor
the health of your pages, which might break after deployment due to templating or serving

issues.

You must include all the required properties for an object to be eligible for appearance in
Google Search with enhanced display. In general, de@ning more recommended features can
make it more likely that your information can appear in Search results with enhanced
display. However, it is more important to supply fewer but complete and accurate

https://developers.google.com/search/docs/advanced/structured-data/intro-structured-data 01/04/22, 3=42 PM


Page 3 of 5
display. However, it is more important to supply fewer but complete and accurate
recommended properties rather than trying to provide every possible recommended
property with less complete, badly-formed, or inaccurate data.

In addition to the properties and objects documented here, Google can make general use of
the sameAs (https://schema.org/sameAs) property and other schema.org (https://schema.org/)
structured data. Some of these elements may be used to enable future Search features, if
they are deemed useful.

Google Search supports structured data in the following formats, unless documented
otherwise:

Formats

JSON-LD (http://json-ld.org/)* A JavaScript notation embedded in a <script> tag in the page


(Recommended) head or body. The markup is not interleaved with the user-visible
text, which makes nested data items easier to express, such as the
Country of a PostalAddress of a MusicVenue of an Event.
Also, Google can read JSON-LD data when it is dynamically
injected into the page's contents
(/search/docs/guides/generate-structured-data-with-javascript),
such as by JavaScript code or embedded widgets in your content
management system.

Microdata An open-community HTML speci@cation used to nest structured


(https://www.w3.org/TR/microdata/)data within HTML content. Like RDFa, it uses HTML tag attributes
to name the properties you want to expose as structured data. It is
typically used in the page body, but can be used in the head.

RDFa (https://rdfa.info/) An HTML5 extension that supports linked data by introducing


HTML tag attributes
(https://www.w3.org/TR/rdfa-lite/#the-attributes) that correspond
to the user-visible content that you want to describe for search
engines. RDFa is commonly used in both the head and body
sections of the HTML page.

Google recommends using JSON-LD for structured data whenever possible.

Structured data guidelines

https://developers.google.com/search/docs/advanced/structured-data/intro-structured-data 01/04/22, 3=42 PM


Page 4 of 5
Be sure to follow the general structured data guidelines (/search/docs/guides/sd-policies), as
well as any guidelines speci@c to your structured data type; otherwise your structured data
might be ineligible for rich result display in Google Search.

Get sta7ed with structured data

If you're new to structured data, check out schema.org beginner's guide to structured data
(https://schema.org/docs/gs.html). While the guide focuses on Microdata, the basic ideas are
relevant for JSON-LD and RDFa. For a step-by-step guide on how to add structured data to a
web page, check out our structured data codelab
(https://codelabs.developers.google.com/codelabs/structured-data/index.html).

Once you're comfortable with the basics of structured data, explore the search gallery
(/search/docs/guides/search-gallery) and pick a feature to implement. Each guide goes into
detail on how to implement the structured data in a way that makes your site eligible for a
rich result appearance on Google Search.

Explore the search gallery (/search/docs/guides/search-gallery)

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0
License (https://creativecommons.org/licenses/by/4.0/), and code samples are licensed under the Apache
2.0 License (https://www.apache.org/licenses/LICENSE-2.0). For details, see the Google Developers Site
Policies (https://developers.google.com/site-policies). Java is a registered trademark of Oracle and/or its
aeliates.

Last updated 2022-02-28 UTC.

https://developers.google.com/search/docs/advanced/structured-data/intro-structured-data 01/04/22, 3=42 PM


Page 5 of 5

You might also like