In several cases you might need to mix structured data using different formats like microdata and json-ld; in this article we review the do’s and don’ts for these edge cases.

Can I mix microdata and json-ld?

Yes, it is totally fine to use both syntaxes side by side on the same page but Google will not be able to merge attributes for the same entity using the item ID unless you are using json-ld ONLY.

Let’s get into the details: 

  • I can have on the same page both syntaxes (microdata and json-ld); for instance I might use microdata to render WebPage and use json-ld for Organization;
  • I can also merge attributes related to the same entity when all the data is available in json-ld but …
  • I cannot combine information related to the same entity by item ID when this information is written in microdata and json-ld. While this is possible in principle, and a pure RDF application would be able to do it, Google does not support it, which means properties won’t be merged and, most importantly, this won’t satisfy the Rich Snippets‘ requirements.

This topic is particularly relevant as microdata remains today the most widely used format for structured data (see data below collected by Aaron Bradley from the 2019 Common Crawl’s sample) and there is a huge demand to improve structured data to gain additional visibility on Google’s SERP.

To confirm that we cannot mix attributes by item ID when combining microdata and json-ld we asked the help of several SEOs with in-depth knowledge on structured linked data, including Dan BrickleyJarno van Driel, Jono Alderson, Richard Wallis and Mark and Martha van Berkel.

Before engaging with the community we created two examples HTML pages:

  1. json-ld + microdata: here is the result validated with the Google Structured Data Testing Tool (where you will see the “Unspecified Type” error since GSDTT cannot merge the two syntaxes);
  2. json-ld + json-ld: here we can see that GSDTT supports the merge by type ID when data is written in json-ld

Interesting enough the first example would be properly rendered by the Structured Data Linter: a tool designed to help webmaster validate structured data markup. Here follows the information from the Twitter thread and the messages by Dan Brickley and Jarno van Driel:

READY TO AUTOMATE YOUR STRUCTURED DATA MARKUP?

Book a call with us and join our list of happy customers!

Are you ready for the new SEO?
Try WordLift now!

€59 Coupon
€100 Coupon
€19 Coupon
€19! Coupon
€39 Coupon
€19 Coupon
No Prize
€39 Coupon
Almost!
€100 Coupon
€100 Coupon
€39 Coupon
Get your chance to win a prize!
Enter your email address and spin the wheel. This is your chance to win amazing discounts!
I have read and agree to the Privacy Policy and Terms of Service

Stand out on search in 2019. Get 50% off WordLift until January 7th Buy Now!

x