Ecommerce

Product Schema: Showing Price and Reviews in Search

Product schema markup helps Google show price, availability and star ratings for your products in search results. Here is what to include, how to add it, and the mistakes that stop rich results appearing.

Quick answer: Product schema is structured data, usually added as JSON-LD, that describes a product on its page: name, image, description, brand, SKU, price, currency, availability and, if you have them, reviews and an aggregate rating. When the markup is valid and matches what visitors see, Google may show rich results with price, stock status and star ratings under your listing. Most ecommerce platforms output basic product schema already, so the job is usually to check it is complete and accurate, fill gaps such as brand and GTIN, test it with Google’s tools, and keep it in sync with the visible page.

What product schema does

Search engines read your page content, but structured data spells out key facts in a standard format from Schema.org. For a product page, that means telling Google exactly which text is the product name, which number is the price and whether the item is in stock.

Google can use that information to show rich results, such as:

  • Star rating and number of reviews
  • Price and currency, or a price range
  • Availability, such as “In stock”

These details make a listing stand out and help shoppers decide before they click. Google does not guarantee rich results even with perfect markup, but without markup you are much less likely to get them.

Which pages should have product schema

Product markup belongs on pages about a single product, where a visitor can see its details and usually buy it. That includes:

  • Individual product pages in an online store
  • Product pages on manufacturer sites, even without a buy button
  • Single product review pages

It does not belong on category pages listing many products, on pages about a type of product in general, or on service pages. Marking up a category page as a single product is a common mistake that can lead Google to ignore the markup.

Key properties to include

Product basics

  • name: the product name as shown on the page
  • image: one or more product image URLs, ideally in several aspect ratios
  • description: a short description matching the page
  • sku: your stock keeping unit
  • brand: the brand name
  • gtin8, gtin13 or gtin14, or mpn: global identifiers such as EAN or UPC, or the manufacturer part number

Identifiers help Google match your product to the same item sold elsewhere. If you already send a product feed to Google, use the same identifiers as in your Merchant Center feed.

Offers (price and availability)

The offers property describes the sale:

  • price: the numeric price, without currency symbols
  • priceCurrency: a three-letter code such as USD, GBP or INR
  • availability: a Schema.org value such as InStock, OutOfStock or PreOrder
  • url: the product page URL
  • priceValidUntil: optional, the date a sale price ends
  • itemCondition: optional, such as NewCondition or UsedCondition

For products with several variants at different prices, you can use an AggregateOffer with lowPrice and highPrice, or list separate offers.

Reviews and ratings

  • aggregateRating: the average rating (ratingValue) and the number of ratings or reviews (reviewCount or ratingCount)
  • review: one or more individual reviews, each with an author and reviewRating

Only include ratings and reviews that are visible on the page and come from your customers. If you are collecting reviews on a WooCommerce store, our guide to WooCommerce product reviews covers how to get more of them.

A simple JSON-LD example

Google recommends JSON-LD, a block of script placed in the page’s HTML. A simplified example:

<script type="application/ld+json">
{
  "@context": "https://schema.org/",
  "@type": "Product",
  "name": "Canvas Weekend Bag",
  "image": "https://www.example.com/images/weekend-bag.jpg",
  "description": "Waxed canvas weekend bag with leather handles.",
  "sku": "WB100",
  "brand": { "@type": "Brand", "name": "Example Goods" },
  "offers": {
    "@type": "Offer",
    "url": "https://www.example.com/weekend-bag/",
    "priceCurrency": "USD",
    "price": "89.00",
    "availability": "https://schema.org/InStock"
  },
  "aggregateRating": {
    "@type": "AggregateRating",
    "ratingValue": "4.6",
    "reviewCount": "27"
  }
}
</script>

Every value in the markup should match the page. If the page says the bag costs $89 and is in stock, the markup must say the same.

How to add product schema

Ecommerce platforms

WooCommerce outputs Product structured data on single product pages by default, including price, availability and ratings when reviews exist. It may not include brand or GTIN unless you add them, often with a plugin or a small code snippet that extends the default markup.

Shopify themes usually include product markup in the theme code. Quality varies by theme, so test it. See our Shopify SEO guide for related checks.

Magento and other platforms also provide product markup, again with varying completeness.

SEO plugins

Some SEO plugins add or extend structured data. Be careful not to output two separate Product blocks for the same item from different sources, which can create conflicting data.

Custom sites

On a custom-built store, generate JSON-LD from the same data used to render the page, so price and stock in the markup always match what customers see. Hard-coding values in templates is a recipe for stale markup.

Testing your markup

Use these tools:

  • Structured Data Testing Tool from Google, to see all detected markup and errors
  • Rich Results Test, to check whether a page is eligible for specific rich results
  • Search Console, where the Enhancements section shows reports for detected structured data types, including errors and warnings across your whole site

Check a sample of products after any theme change, plugin update or platform migration. Markup often breaks silently during redesigns.

Common mistakes that stop rich results

  • Markup does not match the page. Prices, stock or ratings in the code differ from what visitors see.
  • Reviews that are not on the page. Ratings in markup must come from reviews displayed on that page.
  • Imported or third-party reviews in your rating. Marking up reviews collected elsewhere as if they were your own is against Google’s guidelines.
  • Product markup on category pages. Use it only for single products.
  • Missing required properties. Without name, and at least one of offers, review or aggregateRating, Google will not show product rich results.
  • Duplicate or conflicting markup from theme and plugins.
  • Out of date prices cached in markup after a sale ends.

A note on reviews: in September 2019 Google stopped showing review stars for “self-serving” reviews where a business marks up reviews about itself using LocalBusiness or Organization markup. That change does not affect genuine customer reviews of products on product pages, which remain eligible.

What results to expect

Valid product markup does not directly improve rankings. Its value is in how your listing looks. Stars, price and stock status can make a result more attractive and set expectations before the click, which tends to bring better-qualified visitors.

Product schema works best alongside the basics of ecommerce SEO: unique product descriptions (see our guide to duplicate product descriptions), clear category structure and fast pages. If you are adding other structured data types, our FAQ schema article covers a different rich result with similar rules.

FAQ

Is product schema required to rank?

No. It does not boost rankings directly, but it makes rich results possible, which can improve click-through.

How long until stars appear?

After Google recrawls the page and processes the markup. That can take days or weeks, and there is no guarantee rich results will be shown.

Can I add product schema to service pages?

No. Product markup is for products. Services and local businesses have their own types, with different rules for reviews.

Should I include out-of-stock products?

Yes, with availability set to OutOfStock. Keep the page live if the product will return, as we explain in out of stock products SEO.

Make every product listing count

Product schema is a small technical task with a visible payoff. Check what your platform already outputs, fill the gaps, keep it in sync with the page and test after every change. If you want your product pages set up properly so more searchers become buyers, take a look at our Turn visitors into customers service.

About the author

Imran M

Leave a Reply

Your email address will not be published. Required fields are marked *

Ready to improve your website?

Let's build a faster, higher performing website.