Chapter 64: Structured Data & Schema.org

Product & Offer Schema

Supercharge e-commerce search visibility with Schema.org Product, Offer, AggregateRating, and Merchant Return schemas to earn star ratings, pricing badges, and stock indicators in Google SERPs.

LEARNING OBJECTIVES
  • Model e-commerce items using Schema.org Product and Offer / AggregateOffer.
  • Implement ISO 4217 currency codes, exact price formats, and Schema.org availability enumerations.
  • Structure customer review data using AggregateRating and nested Review objects.
  • Integrate global trade item numbers (gtin13, sku, mpn) for Google Merchant Center reconciliation.
  • Understand Google's merchant listing requirements including shipping and return policies.
🎬 INTERACTIVE VISUAL PIPELINE Core Architecture Simulation
🌐
1. Input
Directives & Tags
⚙️
2. Parse
Tokenizer & AST
🌳
3. Layout
Box Model & Flow
🎨
4. Render
GPU Paint & Composite
PHASE 1: INPUT & DIRECTIVES
Browser receives declarative markup stream, parsing tag tokens and initializing component state.

📖 The Mental Model & Story (Intuitive Foundation)

Imagine walking down a busy commercial market street. There are dozens of storefronts selling headphones.

  • Storefront A has frosted glass windows. You cannot see what they sell, how much it costs, or if it is currently in stock unless you open the door, walk inside, and find a salesperson.
  • Storefront B has an illuminated, crystal-clear digital window display showing:
    • "Sony WH-1000XM5 Wireless Headphones"
    • "Price: $349.99 (Save $50 today)"
    • "★ ★ ★ ★ ★ 4.8 / 5.0 (2,410 verified customer reviews)"
    • "🟢 14 units In Stock (Free 2-Day Delivery)"

Which storefront attracts 10x more foot traffic and clicks?

+-------------------------------------------------------------------------------+
|                       GOOGLE PRODUCT RICH SEARCH RESULT                       |
|                                                                               |
|  Sony WH-1000XM5 Noise-Canceling Wireless Headphones                          |
|  https://audiohub.example.com/products/sony-wh1000xm5                         |
|  ★★★★★ Rating: 4.8 · ‎2,410 reviews · ‎$349.99 · ‎In stock · Free 2-day delivery|
|  Industry-leading noise canceling with two processors and 8 microphones...    |
+-------------------------------------------------------------------------------+

Product & Offer Schema turns your search result into Storefront B. It extracts commercial parameters from your database and presents them directly in Google Search results before the user even visits your site.


Technical Deep Dive & Specifications

The Anatomy of Product Schema

In Schema.org, a Product represents the physical or digital item itself (the abstract concept: model, brand, dimensions, reviews). The Offer represents the commercial transaction terms under which that product is sold (price, currency, stock status, return policy, seller).

+-------------------------------------------------------------------------------+
|                               PRODUCT ENTITY                                  |
|   name: "Sony WH-1000XM5"                                                     |
|   image: "https://.../photo.jpg"                                              |
|   brand: { "@type": "Brand", "name": "Sony" }                                 |
|   gtin13: "0027242923508"                                                     |
|   aggregateRating: { ratingValue: "4.8", reviewCount: "2410" }                |
|                                                                               |
|   +-----------------------------------------------------------------------+   |
|   |                            OFFER ENTITY                               |   |
|   |   price: "349.99"                                                     |   |
|   |   priceCurrency: "USD"                                                |   |
|   |   availability: "https://schema.org/InStock"                          |   |
|   |   itemCondition: "https://schema.org/NewCondition"                    |   |
|   |   priceValidUntil: "2026-12-31"                                       |   |
|   +-----------------------------------------------------------------------+   |
+-------------------------------------------------------------------------------+

Key Properties & Enumerations Matrix

Property Target Schema Type Allowed Values & Standards Google Status
name Product Text (Product Title) Required
image Product URL or Array of high-res image URLs Required
gtin13 / sku / mpn Product Global Trade Item Number, Barcode, SKU string Required (at least one ID)
brand Product Brand or Organization ({"@type": "Brand", "name": "..."}) Required
offers Product Offer or AggregateOffer Required
price Offer Number or String with decimals (349.99). No currency symbols! Required
priceCurrency Offer 3-letter ISO 4217 currency code (USD, EUR, GBP, INR) Required
availability Offer https://schema.org/InStock, OutOfStock, PreOrder, BackOrder Required
itemCondition Offer https://schema.org/NewCondition, RefurbishedCondition, UsedCondition Recommended
aggregateRating Product AggregateRating (ratingValue, reviewCount, bestRating: 5) Recommended

💻 Interactive Code Playground

Starter Code

Line-by-Line Code Breakdown

  • Line 8 ("@type": "Product"): Defines the top-level entity as a physical retail product.
  • Line 14–15 ("sku", "gtin13"): Provides unique commercial identifiers. gtin13 allows Google Shopping to cross-match this product against manufacturer databases and competing retailers.
  • Line 16–19 ("brand"): Nests a Brand entity rather than a raw string, establishing Knowledge Graph entity linkage.
  • Line 20–26 ("aggregateRating"): Specifies the aggregated customer rating. ratingValue: "4.8" generates the yellow review stars in SERPs; reviewCount: "2410" renders the review tally.
  • Line 27–38 ("offers"): Nests an Offer object defining the commercial terms.
    • "priceCurrency": "USD": ISO 4217 code.
    • "price": "349.99": Decimal format with no dollar sign.
    • "availability": Full Schema.org enum URI (https://schema.org/InStock).

Expected Browser Render Output


SYS: ACTIVE
HULL: 98%
CORE: STABLE
NET: ONLINE
HTML STARSHIP CODE TERMINAL playground.html
LIVE RENDER & DIAGNOSTICS CORE TEMP: 45°C
INSPECTING DOM: VALID
TAGS: SCANNING...
Sony WH-1000XM5 Wireless Noise-Canceling Headphones
Brand: Sony | SKU: SONY-WH1000XM5-BLK
★★★★★ 4.8 / 5.0 (2,410 customer reviews)
$349.99 USD   In Stock - Ready to Ship
Premium noise-canceling headphones with Auto NC Optimizer...
[Add to Cart Button]

🏋️ Hands-On Exercise

🎯 The Challenge: Build a Refurbished Laptop Product Schema with Individual Reviews

Instructions:

  1. Create a complete Product JSON-LD schema for a refurbished MacBook Pro.
  2. Include the following properties:
    • name: "Apple MacBook Pro 16-inch M3 Max (Certified Refurbished)"
    • sku: "MBP-16-M3MAX-REFURB"
    • brand: Brand named "Apple"
    • aggregateRating: Rating of 4.9 based on 85 reviews.
    • offers: An Offer with price "2799.00", currency "USD", condition "https://schema.org/RefurbishedCondition", and availability "https://schema.org/InStock".
    • review: An array containing one Review object:
      • author: Person named "Devon Vance"
      • datePublished: "2026-05-18"
      • reviewBody: "Flawless performance for Docker and local LLM inference. Indistinguishable from brand new."
      • reviewRating: Object with ratingValue: "5".

🏁 Starter Code Sandbox

SYS: ACTIVE
HULL: 98%
CORE: STABLE
NET: ONLINE
STARTER CODE SANDBOX exercise.html
LIVE RENDER & DIAGNOSTICS CORE TEMP: 45°C
INSPECTING DOM: VALID
TAGS: SCANNING...

⚠️ Common Pitfalls

  1. Including Currency Symbols in price: Writing "price": "$349.99" or "price": "349.99 USD". The price property MUST contain only a numeric value ("349.99" or 349.99), with the currency defined strictly in priceCurrency ("USD").
  2. Fabricating Fake Reviews in Schema: Injecting a 5.0 star AggregateRating in JSON-LD when no actual user reviews exist on the page. Googlebot actively checks for visible user reviews; deceptive ratings lead to search penalties.
  3. Using AggregateRating for General Business on a Product Page: Confusing business-level site reviews (e.g. Trustpilot store score) with item-specific product reviews. Google requires product ratings to pertain exclusively to that exact item.

💡 Pro Tips

  1. Include GTIN / EAN for Google Shopping Clustering: Providing a verified gtin13, gtin14, or isbn enables Google to link your listing directly with official manufacturer catalogs and eligible Google Shopping comparisons.
  2. Use AggregateOffer for Variable Products: When a product has multiple sizes, colors, or prices (e.g., $19.99 – $49.99), use "@type": "AggregateOffer" with lowPrice, highPrice, and offerCount properties.

📌 Key Takeaways

  • Product schema models the item's identity, while Offer models the transaction terms (price, availability).
  • Prices must be purely numeric without symbols; currency must use standard 3-letter ISO 4217 codes (USD, EUR).
  • Availability uses Schema.org enums: InStock, OutOfStock, PreOrder, BackOrder.
  • AggregateRating powers the golden review stars in Google SERPs.
  • GTIN/EAN barcodes enable Google to reconcile your products in Google Shopping merchant listings.
  • --
⭐ LEARN: HTML 🌟 ⚔️ QUIZ BATTLE ARENA // ACTIVE
3x
STREAK!
BONUS ACTIVE
COMBO
? Question 1 / 3

Which of the following is the correct way to specify a price of 49.99 US Dollars in an Offer schema?

Question 1 / 3 Topic: HTML Fundamentals
00:45 REMAINING
XP REWARD
+250 XP
3x
STREAK!
BONUS ACTIVE
COMBO
? Question 2 / 3

What is the primary role of the gtin13 (or gtin) property in Product schema?

Question 2 / 3 Topic: HTML Fundamentals
00:45 REMAINING
XP REWARD
+250 XP
3x
STREAK!
BONUS ACTIVE
COMBO
? Question 3 / 3

When should you use AggregateOffer instead of a standard Offer?

Question 3 / 3 Topic: HTML Fundamentals
00:45 REMAINING
XP REWARD
+250 XP