This is a complete guide to Structured Data in Shopify that includes:
A screenshot of a Google search results page, May 21, 2020
That's a rich result (aka a rich snippet). Rich results provide more data compared to normal search results. For example, although standard results show only the title, URL, and meta summary of a website, rich results can also show product ratings, the number of reviews, price ranges, and more (as seen in the above screenshot).
Since you're here, Google (and other search engines) probably want to view similar results for your Shopify store. You need to apply structured data markup to your website for this to happen, which can be a challenge.
You have to be tech-savvy. Shopify Liquid, HTML, JSON-LD (JSON for Linking Data), and schema.org (data types and properties) must be familiar with this. But even if you're a skilled developer, it might be hard to define exactly what types of data and properties you need to add to your Shopify store.
As Shopify experts, through our Structured Data & Schema Markup Setup service we help Shopify merchants add structured data to their stores on a daily basis. We will summarize our experience in this post, and share the knowledge we have gained. We will talk about what structured data is and how you can implement it.
We will also tackle the specific schema.org data types and properties you should add to your Shopify homepage, product, collection, blog, and article pages.
After reading this guide, you'll realize that implementing structured data can be very easy, overwhelming at first glance, as long as you have the right details.
This is a structured data markup:
And this is the result of implementing structured data markup:
Structured data markup provides more information to the search engines about your website and its content. Structured data will give Google useful information about your products in the context of e-commerce (e.g. cost, quality, ranking, number of reviews etc.).
It can also give detailed information about your business (e.g. logo, address, contact information, connected social media pages, founders, subsidiaries, etc.).
To rephrase the question: How do you benefit from structured data? Structured data helps search engines and web systems to read the website and better understand what it is about. Google would thus be able to view your goods (and other web pages) in a more comprehensive and accurate way.
One important aspect of this is that Google uses structured data to create rich snippets. Google can also use the markup for your product pages to create automated product feeds for your Google Shopping Ads.
Side Note
Google does not guarantee that you will get rich snippets even if
your pages are marked up correctly. This is explicitly stated in Google's Structured Data Guidelines:
Here’s a visual:
But if you add structured data markup to your website, Google is more likely to give you rich snippets and in most cases it does.
As described in the Google Webmaster Blog, structured data formats "define a small number of fixed structures that can be used to encode descriptive data".
There are 3 structured data formats:
Google recommends using JSON-LD for structured data.
Source: Google, Understand how structured data
The takeaway: If you're using Microdata or RDFa, it is best to consider migrating to JSON-LD. JSON-LD is easier to add and update and it is compatible with dynamic data. In addition, if you use JSON-LD, you don’t have to change your HTML code
Here's a representation of a product in JSON-LD that would show up on a product page.
<script id="productLd" type="application/ld+json"> { "@context": "http://schema.org/", "@type": "Product", "name": "Shopify Structured Data for E-commerce", "image": "https://cdn.shopify.com/s/files/1/1564/7647/products/StructuredDataforE-commerce_600x600.jpg?v=1587479185", "sku": "", "description": "In an SEO setting, "structured data" ordinarily alludes to actualizing a few sorts of markup on a webpage, in order to supply extra detail around the page’s substance. This mar...", "brand": { "@type": "Thing", "name": "HulkApps" }, "offers": { "@type": "Offer", "priceCurrency": "USD", "price": "149.0", "priceValidUntil" : "2020-08-19", "url" : "https://www.hulkapps.com/products/structured-data-for-e-commerce", "availability": "http://schema.org/InStock" }, "review": { "@type": "Review", "reviewRating": { "@type": "Rating", "worstRating": "0", "ratingValue": 5, "bestRating": "5" }, "author": { "@type": "Person" } } }</script>
In short, adding JSON-LD to your online store can help search engines parse your products and offers, and therefore greatly increase your organic search traffic. It's not a shortcut or hack. Google and other search engines encourage it.
Structured data schemas define terms for different types (e.g. "WebSite", "Person", "Organization") and properties (e.g. "name", "description", "logo"). Structured data schemas include:
Data-vocabulary.org is outdated. And, due to the increasing popularity of schema.org, come April 6, 2020, data-vocabulary.org will no longer be eligible for rich results features.
The takeaway: If you’re using data-vocabulary.org, you must replace your data-vocabulary.org markup with schema.org markup.
Now that you know what structured data is, why you should use it, and what the chosen structured data format (JSON-LD) and schema (schema.org) is for Google, let's take a closer look at what you need to do before implementing structured data.
You must do 3 things:
Source: schema.org, Product, Example 2, JSON-LD
As you can see from the screenshot, structured data consists of types. Each type is associated with a set of properties. Common properties of the Product type include productID, description, name, height, weight, mpn, etc.
Each type can contain other types (arranged in hierarchical order). For example, the Product type contains a set of Offer types. The Offer types are actually your product variants and contain properties like price, availability, etc.
Only a handful of them is of interest to us. But before we arrive at the specific types and properties that you need to add to the individual pages of your shop, let's see how you can incorporate structured data in the HTML of your website.
There are 2 ways to implement structured data in your website’s HTML:
Read the article below to get to the roots of adding the Structured Data to your Shopify store.
Now that you are aware of your choices for implementing structured data in the HTML of your Shopify store, let's take a closer look at the various forms and properties of schema.org data you need to apply to the different pages on your website.
You should add 2 data types to your homepage:
Schema.org defines 'WebSite' as a set of related web pages that usually share the same domain. You have to include the following properties in the WebSite data type:
For example, Store, SportsOrganization, Corporation, LocalBusiness, BikeShop, BookStore, WorkersUnion, hardware store, etc. Note that the more specific the Organization type is, the better. You have to include the following properties in the Organization data type:
You can also include a price range (priceRange), contact information (e.g. a phone number), geolocation, and more.
You should add 3 data types to your product pages:
The product type describes the product itself, along with its size, SKU, barcode, etc., the offer type describes a product variant. You need to have one type of product and at least one type of offer for each variant of the product. If you don't have variants for a product, you will have that product's price, SKU, barcode, etc. as its properties. These properties are added in Shopify as a default variant, and you can use this variant to create your type of Offer.
The following recommended attributes are relevant for you: productID, brand, mpn (Manufacturer Part Number, MPN), and gtin (Global Trade Item Number, GTIN). That will help Google match your product search queries.
In Shopify, the GTIN is referred to as a barcode and you can add it to your product variants. The GTIN is also your productID and can also serve as an MPN.
Adding breadcrumb markup to your product pages is a good practice. This will help Google understand and categorize the information on its product pages better. The markup for breadcrumb will contain the type BreadcrumbList. The type BreadcrumbList should contain at least one type ListItem. The category ListItem should have the following properties in it:
The collection page should contain the CollectionPage type and also include one ListItem type for each product on the collection page.
Side Note:
It is also a good practice to add breadcrumb markup to your
collection pages (please, check the Product page markup section for more information on breadcrumb
markup).
The Blog type should contain a number of BlogPosting types. Each blog posting type is associated with an article or a publication. The blog posting type should contain the following properties:
You can use the following tools to check if your pages are marked up correctly and you’re eligible for rich results:
The structured data testing tool allows you to test URLs or code snippets:
Note that if the Structured Data Testing Tool detects an error, you must fix it as it might (and probably will) hurt your rankings. Warnings, on the other hand, are not something you should lose sleep over - usually, warnings refer to recommended properties you could include in your markup.
Rich Results Test is just as easy to use. All you have to do is paste your website's URL in the "Enter a URL to test" field → Click "Test URL".
Click on Test URL and wait for a few seconds
Note that you can also test code snippets.
The addition to your Shopify store of structured data markups will help search engines understand better what your website is about. It will also increase your chances of getting rich results which, in turn, will increase user engagement and your CTR-all of which will lead to more sales.
There are 3 structured data formats: JSON-LD, RDFa, and Microdata. Google prefers and recommends using JSON-LD for structured data.
There are two structured data (or vocabularies) schemes: data-vocabulary.org and schema.org. Data-vocabulary.org is outdated, and will no longer be eligible for rich features of results as of April 6, 2020. Therefore, if you use the data-vocabulary.org markup, you have to replace it with a schema.org markup.
Structured data markup (or schema.org markup) consists of the hierarchically arranged data types and properties. In Shopify, adding structured data to your homepage, product pages, collection pages, blog page, and article pages is recommended. Here is a brief overview of the data types and properties you should add to each of these pages:
There are two ways to add structured data to your Shopify store: you can use a do it in-house manually, or outsource the task to a Shopify Expert. If you would like us to take a look at the SEO of your website and to implement structured data for you, please feel free to contact us or browse through our Structured Data service catalog to buy the one you're looking for.
After you add structured data to your website, you have to check if your pages are marked up correctly. To do this, you can use Google Structured Data Testing Tool and/or Rich Results Test. Making sure that your pages are marked up correctly is the last step of implementing structured data.
We realize that this is a lot of information to take in at once and you must have a lot of questions. We’re here to answer all of them!
How will you add structured data markup to your website? Will you do it in-house, or outsource it to a Shopify Expert?
Or, maybe, you’ve already added structured data and want to share your experience...
Whatever it is, we’re here to help all the way!