In short
This task industrializes Product, ProductGroup and Offer markup across an entire store: every template (simple product, product with variants, product on sale, pre-order, used, sold by weight) produces accurate markup, drawn from the same data as the page and the feed. The basics of the markup are covered in implement Product, ProductGroup and Offer to match the catalog (opens in a new tab); this guide deals with cases specific to e-commerce and with checks at catalog scale. Once the task is done, the merchant listings report in Search Console no longer shows any error on product templates.
Why it matters
Google reads product markup for two families of features: product snippets (rating, price, availability) and merchant listings, reserved for pages where people buy from you. Merchant listings feed rich results, Google Images and the Shopping tab. Merchant Center can also create products automatically from this markup, and compares it with the feed to detect price mismatches.
In a store, markup is generated per template. An error in a template therefore affects hundreds or thousands of product pages at once: a strikethrough price marked up as the active price, a sale whose end date has passed, a pre-order announced as InStock. Google states that a past priceValidUntil date can prevent the listing from showing, and that when price and priceSpecification both encode the active price, it keeps price and ignores the specification.
AI assistants that answer shopping requests rely on structured product data drawn from feeds and pages. Accurate markup makes your products comparable (price, availability, identifiers); it guarantees neither a citation nor a recommendation.
What it improves
- Merchant listing eligibility across the whole catalog, not just on the page you tested.
- Display of sales Strikethrough price and active price correctly distinguished.
- Merchant Center Fewer disapprovals for price mismatch, and a source to check the feed against.
- Comparability in shopping assistants An indirect effect that cannot be measured directly.
- Rankings No direct effect; markup is not a ranking factor.
How to check
- Inventory the templates. List one sample URL for each case: simple product, product with variants, preselected variant, product on sale with an end date, pre-order, out of stock, used or refurbished, sold by weight or volume, member price.
- Test each URL in the Rich Results Test. The “Merchant listings” and “Product snippets” items must be valid.
- Compare with the page. For each URL, note the displayed price, the strikethrough price, the availability and the currency, then compare them with the markup:
curl -s "https://example.com/produits/the-vert-sencha-100g/" \
| grep -o -E '"(@type|price|priceType|priceCurrency|availability|priceValidUntil|validFrom|validThrough)" *: *"?[^",}]*'
- Check the whole catalog in Search Console:
Shopping > Merchant listingsandShopping > Product snippets. The number of valid items should come close to the number of indexable product pages. - Crawl the catalog with Screaming Frog, with structured data extraction and validation turned on (
Configuration > Spider > Extraction): the Structured Data tab lists the URLs with errors or warnings, by type.
Compliant result: no template with errors, a single Product or ProductGroup per page, an active price equal to the displayed price.
How to implement
Before you start
Map the fields. The markup, the page and the feed must read the same data. In a table, note the source field in your database for each property:
| schema.org property | Merchant Center feed attribute | Source field (WooCommerce example) |
|---|---|---|
sku |
id |
Variant SKU |
gtin13 |
gtin |
Inventory GTIN field |
brand.name |
brand |
Brands taxonomy |
offers.price |
price or sale_price |
Active price, tax included |
priceSpecification with StrikethroughPrice |
price when sale_price exists |
Regular price |
offers.availability |
availability |
Stock status |
offers.itemCondition |
condition |
Condition attribute |
productGroupID or inProductGroupWithID |
item_group_id |
Parent product SKU |
This is how Thé des Lisières, a fictional loose-leaf tea store, discovered that its feed used the product's internal ID while its markup used the SKU: Merchant Center could not match the two sources.
Choose the markup for each special case:
| Case | Markup | Google rule |
|---|---|---|
| Sale | Active price in price, original price in a UnitPriceSpecification with priceType https://schema.org/StrikethroughPrice |
Never put priceType on the active price |
| Sale with dates | validFrom and priceValidUntil (or validThrough) on the Offer |
ISO 8601 dates with a time zone |
| Sold by weight or volume | UnitPriceSpecification with referenceQuantity and unitCode |
The unit price must match the one displayed |
| Member price | UnitPriceSpecification with validForMemberTier |
A regular price must also appear in the offer |
| Pre-order | availability PreOrder |
Availability date visible on the page |
| Restock in progress | BackOrder or OutOfStock |
See manage temporarily out-of-stock products (opens in a new tab) |
| Used or refurbished | itemCondition UsedCondition or RefurbishedCondition |
A single value |
| Several currencies | A separate URL for each currency | Google explicitly requires it |
Sale with a strikethrough price and dates:
"offers": {
"@type": "Offer",
"url": "https://example.com/produits/the-vert-sencha-100g/",
"price": 9.90,
"priceCurrency": "EUR",
"validFrom": "2026-11-27T00:00:00+01:00",
"priceValidUntil": "2026-12-01T23:59:59+01:00",
"availability": "https://schema.org/InStock",
"itemCondition": "https://schema.org/NewCondition",
"priceSpecification": {
"@type": "UnitPriceSpecification",
"priceType": "https://schema.org/StrikethroughPrice",
"price": 12.90,
"priceCurrency": "EUR"
}
}
Warning: only display and mark up a strikethrough price if it matches a price you have actually charged. In the European Union, the reference price in a price-reduction announcement is regulated (in France, article L112-1-1 of the Consumer Code): have your calculation method validated.
Sold by weight (tea sold in a 250 g bag, price expressed per kilo):
"offers": {
"@type": "Offer",
"url": "https://example.com/produits/the-noir-assam-250g/",
"priceSpecification": {
"@type": "UnitPriceSpecification",
"price": 14.50,
"priceCurrency": "EUR",
"referenceQuantity": {
"@type": "QuantitativeValue",
"value": "250",
"unitCode": "GRM",
"valueReference": { "@type": "QuantitativeValue", "value": "1", "unitCode": "KGM" }
}
}
}
Member price. First declare the loyalty program once, in the Organization (hasMemberProgram, with name, description and hasTiers), then reference the tier by its @id in the offer:
"offers": {
"@type": "Offer",
"url": "https://example.com/produits/the-vert-sencha-100g/",
"price": 12.90,
"priceCurrency": "EUR",
"priceSpecification": {
"@type": "UnitPriceSpecification",
"price": 11.50,
"priceCurrency": "EUR",
"validForMemberTier": { "@type": "MemberProgramTier", "@id": "https://example.com/fidelite/#niveau-membre" }
}
}
Google ignores a specification that carries both priceType and validForMemberTier.
Variants follow the ProductGroup model described in the guide of the Structured data topic. Check that the markup's productGroupID equals the feed's item_group_id, and that each variant URL preselects the right image, price and availability. See also manage variants (opens in a new tab).
WordPress
Versions WordPress 6.8 and later, WooCommerce 10 and 11.
WooCommerce generates product markup on its own. The source code of the WC_Structured_Data class shows the behaviors you need to know:
- Sale: the sale price is placed first in
priceSpecificationand the regular price receivespriceTypeListPrice. Google acceptsListPriceduring a transition period but recommendsStrikethroughPrice. priceValidUntil: it is set to the sale end date if there is one, otherwise to December 31 of the following year.- Variable product:
AggregateOfferon the parent URL, not eligible for merchant listings; a simpleOfferwithinProductGroupWithIDonly on a URL that preselects a complete variant, since WooCommerce 11.0. - Out of stock:
BackOrderif backorders are allowed, otherwiseOutOfStock. There is no native “pre-order” status.
To fix the strikethrough price type, add this filter to a custom plugin or to a child theme's functions.php:
add_filter('woocommerce_structured_data_product_offer', function (array $offer, WC_Product $product): array {
if (empty($offer['priceSpecification']) || ! is_array($offer['priceSpecification'])) {
return $offer;
}
foreach ($offer['priceSpecification'] as $index => $specification) {
if (($specification['priceType'] ?? '') === 'https://schema.org/ListPrice') {
$offer['priceSpecification'][$index]['priceType'] = 'https://schema.org/StrikethroughPrice';
}
}
return $offer;
}, 10, 2);
For a pre-order handled by a plugin, use the same filter to replace availability with https://schema.org/PreOrder when the product carries the plugin's pre-order status. To replace the whole markup with a ProductGroup, use a WooCommerce SEO plugin that generates it, or the woocommerce_structured_data_product filter. Then clear the page cache (WP Rocket, LiteSpeed Cache) so that the new markup is served.
Shopify
Versions Shopify, all plans, Online Store 2.0 themes, November 2026.
The Liquid filter {{ product | structured_data }} outputs a Product or a ProductGroup depending on whether the product has variants. It only knows Shopify's data: check in the Rich Results Test how it handles the compare-at price, variant availability and products sold by unit of measure.
If a case is not covered, do not add a second Product next to it: replace the filter call in sections/main-product.liquid with a hand-written block, for example for a variant's strikethrough price:
{%- assign variant = product.selected_or_first_available_variant -%}
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Product",
"name": {{ product.title | json }},
"image": {{ product.featured_image | image_url: width: 1200 | prepend: 'https:' | json }},
"sku": {{ variant.sku | json }},
"gtin13": {{ variant.barcode | json }},
"brand": { "@type": "Brand", "name": {{ product.vendor | json }} },
"offers": {
"@type": "Offer",
"url": {{ request.origin | append: variant.url | json }},
"price": {{ variant.price | divided_by: 100.0 | json }},
"priceCurrency": {{ cart.currency.iso_code | json }},
"availability": "https://schema.org/{% if variant.available %}InStock{% else %}OutOfStock{% endif %}"
{%- if variant.compare_at_price > variant.price -%},
"priceSpecification": {
"@type": "UnitPriceSpecification",
"priceType": "https://schema.org/StrikethroughPrice",
"price": {{ variant.compare_at_price | divided_by: 100.0 | json }},
"priceCurrency": {{ cart.currency.iso_code | json }}
}
{%- endif %}
}
}
</script>
This block covers only one variant: for a product with variants, keep the structured_data filter unless you have a specific need. With Shopify Markets, each market has its own URLs and currency, which satisfies the one-URL-per-currency rule.
PrestaShop
Versions PrestaShop 8 and 9.
The markup of the Classic and Hummingbird themes lives in templates/_partials/microdata/product-jsonld.tpl. Copy it into your child theme to add the strikethrough price: PrestaShop exposes the pre-discount price ($product.regular_price_amount) and a discount flag ($product.has_discount) in the product template. Add the StrikethroughPrice UnitPriceSpecification only when that flag is true. Check the variable names in your version's template, then clear the cache (Advanced Parameters > Performance).
Magento
Versions Adobe Commerce and Magento Open Source 2.4.7 to 2.4.9.
The Luma theme only outputs partial microdata. Use a structured data extension that handles dated special prices (special_price, special_from_date, special_to_date), configurable products as ProductGroup and customer group prices, or write a JSON-LD block in your theme based on Magento's final price model. Remove Luma's microdata so that only one source remains. Flush the cache: bin/magento cache:flush.
Wix
Versions Wix dashboard, Wix Stores, November 2026.
The markup of Wix Stores product pages is prefilled and can be edited in the SEO settings of the Product Pages page type. Check in the Rich Results Test how strikethrough prices and variants are handled; cases that are not covered (member price, unit price) are better handled through the Merchant Center feed.
Squarespace
Versions Squarespace 7.1, plans with commerce, November 2026.
Squarespace generates basic product markup. Sales, unit prices and member prices cannot be set in this markup: declare them in the Merchant Center feed, which takes precedence over the markup for Shopping.
Webflow
Versions Webflow Ecommerce, November 2026.
In the Products collection template, under Page settings > Custom code, complete the JSON-LD block with the collection's compare-at price fields and a condition on whether they are present, following the Shopify block above.
Laravel
Versions Laravel 11 to 13, spatie/schema-org package 3 to 5.
Calculate the price in a single class used by the view, the feed and the markup:
use Spatie\SchemaOrg\Schema;
$offer = Schema::offer()
->url(route('products.show', $product))
->price($pricing->current($product))
->priceCurrency('EUR')
->availability($product->availabilitySchemaUrl())
->itemCondition('https://schema.org/NewCondition');
if ($pricing->hasStrikethrough($product)) {
$offer->priceSpecification(
Schema::unitPriceSpecification()
->priceType('https://schema.org/StrikethroughPrice')
->price($pricing->regular($product))
->priceCurrency('EUR')
);
}
if ($product->sale_ends_at) {
$offer->priceValidUntil($product->sale_ends_at->toIso8601String());
}
$pricing is your price calculation service; the Merchant Center feed must call it too. Purge the HTTP cache of the product pages whenever a price or stock level changes.
Next.js
Versions Next.js 15 and 16 (App Router).
Generate the markup in the same server component as the displayed price, from the same query. With a static or cached page, trigger on-demand revalidation (revalidatePath('/produits/[slug]', 'page') or revalidateTag) from the webhook of your stock and pricing system; otherwise a sale that has ended stays in the markup until the next regeneration. In Next.js 16, revalidateTag takes a second argument (revalidateTag('produits', 'max')): the single-argument form from Next.js 15 is deprecated there.
Common mistakes
- Strikethrough price marked up as the active price, or
priceTypeset on the sale price: Google asks for the opposite. - A finished sale still in the markup: cached page, expired
priceValidUntil, strikethrough price still displayed. - Prices excluding tax in the markup, including tax on the page for a consumer store.
- A pre-order marked up as
InStock: the buyer expects immediate shipping. - A different group ID between
productGroupIDand the feed'sitem_group_id. - A single URL for several currencies, with a price converted on the fly according to the visitor.
- Testing a single product page: errors hide in rare templates (used, bundle, by weight).
Frequently asked questions
How do you mark up a strikethrough price during a sale?
Put the sale price, the one the customer pays, in the price property of the Offer, and the original price in a UnitPriceSpecification whose priceType is StrikethroughPrice. Add validFrom and priceValidUntil for the sale period. Never set priceType on the sale price. The original price must be a price you have actually charged, in line with the regulations on price-reduction announcements.
Does WooCommerce produce markup compatible with merchant listings?
Partly. WooCommerce produces a valid Offer for simple products, but an AggregateOffer for the URL of a variable product, which merchant listings do not accept. During a sale, it marks the regular price with ListPrice, accepted during a transition period, whereas Google recommends StrikethroughPrice. The woocommerce_structured_data_product and woocommerce_structured_data_product_offer filters let you fix these points.
Should member-only prices be marked up?
Yes, if these prices are displayed on the product page and you want them to be able to appear in results. Declare the loyalty program in the organization markup with hasMemberProgram, then add to the offer a UnitPriceSpecification with validForMemberTier pointing to the relevant tier. The offer must also contain the regular price, and the specification must not carry a priceType.
Is product markup enough without a Merchant Center feed?
It can be enough to get started: Merchant Center can create products from your pages' markup, provided the site is verified and Googlebot can crawl it. A feed remains preferable for a large catalog or for prices that change often, because it sends attributes the page does not carry and updates at your own pace.
Resources
- Google Search Central: Merchant listing structured datadevelopers.google.com
- Google Search Central: Product variant structured datadevelopers.google.com
- Google Search Central: Loyalty program structured datadevelopers.google.com
- schema.org: UnitPriceSpecificationschema.org
- Shopify: structured_data filtershopify.dev
- WooCommerce: structured data generation codegithub.com
- Merchant Center Help: Add products from your online storesupport.google.com
Updated on
Topic checklist (PDF)