What is Microdata?

Microdata is easy to implement structured data that encapsulates the HTML code with additional tags. It includes a sensible structure that is easy to follow once you get used to reading it.

If you’re using scripts to generate pages, then microdata is a great way to add structured data around crucial information. For example, you may include price markup around a products price. This technique is used frequently in platforms such as Shopify and Magento.

Microdata Example from Schema.org

How can I check my Microdata?

The easiest way to check structured data is by using Google’s Structured Data Testing Tool. Directly input a URL or copy and paste your code, and it will notify you of any errors, warnings and suggestions.

The most common errors are to do with the formatting of the code. Tools that automatically generated structured data can often include mistakes. An excellent example of this is missing required fields such as the name of a product, or bad formatting of JSON code.

The most frequent warnings include other useful data for the object type. An excellent example is suggestions for GTIN or SKU codes on the product markup.

Breadcrumbs in Structured Data Testing Tool

How can I fix my Microdata?

Before you can begin to fix your microdata, you first need to learn to read it. Here are the three main components of Microdata:

  • ItemScope – the microdata scope begins with this starting tag, typically a <div>, and finishes with the accompanying close tag.
  • ItemType – the itemType specifies the used markup. Since microdata does not use ‘vocab’ or ‘context’, you link directly to the vocabulary page.
  • ItemProp – each property is marked up, and the value applies to the current scope. For example, many markups utilise “name”, but it would apply to the scope that this name is inside.

Once you have grasped these basics, it is easy to fix Microdata.