40
votes
What is the use of @id in json-ld syntax?
The @id keyword allows you to give a node a URI. This URI identifies the node.
See Node Identifiers in the JSON-LD spec.
(The equivalent in Microdata is the itemid attribute, and the equivalent in ...
17
votes
Accepted
Linking external JSON-LD schema (from Schema.org)
The script element can be used for two things:
dynamic/classic scripts
data
And for data, the spec defines:
When used to include data blocks, the data must be embedded inline […]
So you may use ...
13
votes
Accepted
Which one does Google prefer, Microdata or JSON-LD?
The document that recommends JSON-LD is more recent and it clearly states that Google recommends using JSON-LD where possible (over Microdata) specifically for the following reasons:
"The markup does ...
12
votes
Accepted
Multiple addresses in JSON-LD Schema.org
Similar to adding multiple string/URL values: by using an array.
<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "Organization",
"address":
[
{
...
12
votes
Should Schema.org Organization data about my company be on every page?
A quick point on this. A site I work on recently got a manual action penalty from Google for having organization JSON-LD markup across every single page on their domain. It didn't affect rankings of ...
10
votes
Accepted
How to use more than 1 schema.org schema on a web page
In JSON-LD (instead of Microdata/RDFa) you have to repeat the property and its value for each node.
Instead of using a separate script element for each node, you could also use a single script ...
9
votes
Accepted
schema.org/Book with multiple authors using JSON-LD
your code contains error, thats why two authors aren't recognized. If you have more then one author, you should add them as list without entity duplication. Here the correct code:
<script type="...
9
votes
Can I mix Microdata and JSON-LD on the same page for different entity
It should be fine to use different syntaxes on the same page.
It has one drawback, though: If you want to connect entities specified in different syntaxes, you can’t nest them. You have to use URIs ...
9
votes
Accepted
Do I need JSON-LD on all pages or just the home page?
Google uses the phrase "Include the contact markup on one page in your official site" in relation to the Organization information you are adding.
https://developers.google.com/search/docs/guides/...
8
votes
What is the use of @id in json-ld syntax?
Reading the following link from Google Developers - Data types - Local Business in the Local business properties section you have:
[...] The ID should be stable and unchanging over time. Google ...
7
votes
Do I need JSON-LD on all pages or just the home page?
JSON-LD should be included on the company home page for the company info. While you shouldn't use that on other pages, you should include JSON-LD on the other pages that provides the information on ...
6
votes
Accepted
How do I mark up multi product pages with Schema.org and JSON-LD?
I assume you mean two Offer items for one Product (like your example suggests).
Instead of repeating the offers property, you have to use one offers property with an array value (in [ and ]):
"...
6
votes
Getting errors "Missing ',' or '}'", "Unexpected token" and "got 'undefined'" for my JSON-LD
You use ” instead of " two times:
Instead of
"url": "company website jewellers url/”,
it has to be
"url": "company website jewellers url/",
Instead of
"sameAs": [
"youtube channel about url”...
5
votes
Can I have multiple JSON-LD scripts in the same page?
Yes, you can.
The first script indicates the URL of internal site search to be shown in Google SERP between your main entry and sitelinks. The second script indicates your social media accounts to be ...
5
votes
Accepted
Should Schema.org Organization data about my company be on every page?
Google looks for such information in traditional places such as About, Contact, Company Info, the sites header, or the sites footer. This began in the early days of semantics where specific ...
5
votes
Accepted
Product Snippets with JSON-LD + Schema.org - Are there any live examples in Google index?
Update 2016: The documentation got updated and it no longer contains the note. So now JSON-LD seems to be supported for the Products Rich Snippet.
Google’s documentation for the Products Rich Snippet ...
5
votes
Accepted
NewsArticle not validing: "The attribute image.width has an invalid value."
See Google documentation: https://developers.google.com/search/docs/data-types/articles
Images should be at least 696 pixels wide.
So this one works for me:
<script type="application/ld+json"&...
5
votes
Accepted
Google Tag Manager Multiple URL Exceptions not Working
When adding exception operations, there's a note above it:
Fire this trigger when an Event occurs and all of these conditions are true
You'll need to create two separate rules, each containing just ...
5
votes
Google SDTT gives error "Missing '}' or object member name." for my JSON-LD
If you want to provide multiple addresses, you have to specify one address property with an array value, not an array of address properties.
If you click at the error in the SDTT, the tool correctly ...
5
votes
Accepted
What is the benefit of ImageObject schema org markup for images?
First of all, for the image property, Schema.org expects either an URL value or an ImageObject value. This is typically the case for other properties taking an image value, too.
So for the image ...
5
votes
Accepted
How to write JSON-LD for list of people?
You have several options:
as top-level items
(only use this if the other two options are not possible)
as values for a property
(best option, but requires that Schema.org offers a suitable type/...
5
votes
Accepted
Google Structured Data Testing Tool Repeat Error: "The URL could not be rendered. Some markup may be missing."
After:
isolating error triggers
assessing what all the error triggers had in common (they all referred to external .svg files)
The answer is:
Google Structured Data Testing Tool doesn't yet know ...
5
votes
Using both JSON+LD and Microdata to markup the exact same information on a page
If you provide structured data about the same thing in different syntaxes, you should convey that it’s actually the same thing, not different things.
You can do this by giving all representations the ...
5
votes
Accepted
Are html tags allowed in structured data product description?
There's an important nuance here. With structured data for search, there are multiple layers of validity: the vocabulary (Schema.org, etc.), the syntax (RDFa, JSON-LD, etc.), and individual search ...
5
votes
Accepted
schema JSON produces error "Unparsable structured data" in Google Search Console
You need to add speech marks (") around the URL's you have in that list. Your last URL in the list also can't have a comma after it. I have placed the corrected code below.
{
"@context" : "http://...
4
votes
How to use more than 1 schema.org schema on a web page
Not looking to be a necromancer, but there was a recent article from someone at Yoast that details problems that arise with using the @Graph type when trying to get Google search to "report" the ...
4
votes
Does Google parse SVG images as value of the Schema.org 'image' property in JSON-LD?
I guess there is no reason to assume that Google wouldn’t handle SVGs as value of the image property:
Schema.org’s image property expects an image URL (or an ImageObject).
SVG is an image format (...
4
votes
Linking external JSON-LD schema (from Schema.org)
According to the documentation:
[…] Also, Google can read JSON-LD data when it is dynamically injected into the page's contents, such as by JavaScript code or embedded widgets in your content ...
4
votes
Linking external JSON-LD schema (from Schema.org)
This may, or may not help, but take a look at how Trevor Fox did it:
<script>
$.getJSON( "/your-schema-file.jsonld", function( data ) {
$( "<script/>", {
"type": "application/ld+json",
"...
4
votes
Accepted
How to use JSON-LD in my page that already have content?
Nothing wrong with Microdata or RDFa
First of all, ignore Google’s recommendation if you are fine with using Microdata or RDFa. I think there are only two cases where you should use JSON-LD instead ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
json-ld × 194schema.org × 124
structured-data × 49
seo × 48
rich-snippets × 23
microdata × 22
google-rich-snippets-tool × 21
google-search-console × 17
google-search × 17
google × 14
html × 9
google-tag-manager × 9
javascript × 7
breadcrumbs × 7
local-seo × 5
markup × 5
googlebot × 4
homepage × 4
rdfa × 4
knowledge-graph × 4
microformats × 4
search-results × 3
html5 × 3
meta-description × 3
validation × 3