Helldan:410
Newbie
Hi everyone,
I'm writing structured data for a client’s PDPs and I’d love some feedback from others working with eCommerce Schema at scale—particularly with ProductGroup and variant handling via parameterized URLs. I've never authored this before, and it passes verifications, but I wanted to make sure it was correct.
Here are the facts:
I'm writing structured data for a client’s PDPs and I’d love some feedback from others working with eCommerce Schema at scale—particularly with ProductGroup and variant handling via parameterized URLs. I've never authored this before, and it passes verifications, but I wanted to make sure it was correct.
Here are the facts:
- CMS: Headless Shopify (sanity.io)
- Variants: Product is available in three sizes (Small, Medium, Large), each served via a parameterized URL like ?size=small.
- Markup Strategy: Using ProductGroup as the parent entity with individual Product instances defined via hasVariant.
Code example for product with 3 size variants:
-
JSON:
{ "@context": "https://schema.org", "@type": "ProductGroup", "@id": "https://www.example.com/products/product-x#productgroup", "productGroupID": "PRD-X-2025", "name": "Product X", "description": "A premium product designed with high-quality materials and available in multiple sizes.", "brand": { "@type": "Brand", "@id": "https://www.example.com/brands/acme-brand#brand", "name": "Acme Brand" }, "category": "Category1 > Category2 > Category3 > Product", "material": "High-performance composite", "manufacturer": { "@type": "Organization", "@id": "https://www.example.com/#organization", "name": "Acme Manufacturing Co." }, "aggregateRating": { "@type": "AggregateRating", "@id": "https://www.example.com/products/product-x#aggregaterating", "ratingValue": "4.6", "reviewCount": "215" }, "review": [ { "@type": "Review", "@id": "https://www.example.com/products/product-x#review1", "reviewRating": { "@type": "Rating", "ratingValue": "5" }, "author": { "@type": "Person", "@id": "https://www.example.com/reviewers/reviewer-1#author", "name": "Verified Reviewer" }, "reviewBody": "Outstanding build quality and performance. Would highly recommend." } ], "image": "https://www.example.com/images/products/product-x.jpg", "url": "https://www.example.com/products/product-x", "variesBy": [ "https://schema.org/size" ], "hasVariant": [ { "@type": "Product", "@id": "https://www.example.com/products/product-x?size=small#variant", "sku": "PRD-X-SM-001", "gtin14": "10012345678901", "name": "Product X - Small", "description": "Product X in small size for compact spaces and lightweight needs.", "size": "Small", "image": "https://www.example.com/images/products/product-x-small.jpg", "weight": { "@type": "QuantitativeValue", "value": "50", "unitCode": "LBR" }, "width": { "@type": "QuantitativeValue", "value": "40", "unitCode": "INH" }, "depth": { "@type": "QuantitativeValue", "value": "70", "unitCode": "INH" }, "height": { "@type": "QuantitativeValue", "value": "10", "unitCode": "INH" }, "offers": { "@type": "Offer", "@id": "https://www.example.com/products/product-x?size=small#offer", "price": "699.99", "priceCurrency": "USD", "priceValidUntil": "2025-12-31", "availability": "https://schema.org/InStock", "url": "https://www.example.com/products/product-x?size=small", "itemCondition": "https://schema.org/NewCondition", "shippingDetails": { "@type": "OfferShippingDetails", "shippingRate": { "@type": "MonetaryAmount", "value": "0.00", "currency": "USD" }, "shippingDestination": { "@type": "DefinedRegion", "addressCountry": "US" }, "deliveryTime": { "@type": "ShippingDeliveryTime", "handlingTime": { "@type": "QuantitativeValue", "minValue": 0, "maxValue": 1, "unitCode": "DAY" }, "transitTime": { "@type": "QuantitativeValue", "minValue": 1, "maxValue": 5, "unitCode": "DAY" } } }, "hasMerchantReturnPolicy": { "@type": "MerchantReturnPolicy", "applicableCountry": "US", "returnPolicyCountry": "US", "returnPolicyCategory": "https://schema.org/MerchantReturnFiniteReturnWindow", "merchantReturnDays": 60, "returnMethod": "https://schema.org/ReturnByMail", "returnFees": "https://schema.org/FreeReturn" } }, "isVariantOf": { "@id": "https://www.example.com/products/product-x#productgroup", "@type": "ProductGroup", "productGroupID": "PRD-X-2025", "name": "Product X" } }, { "@type": "Product", "@id": "https://www.example.com/products/product-x?size=medium#variant", "sku": "PRD-X-MD-001", "gtin14": "10012345678902", "name": "Product X - Medium", "description": "Product X in medium size with optimized design and material efficiency.", "size": "Medium", "image": "https://www.example.com/images/products/product-x-medium.jpg", "weight": { "@type": "QuantitativeValue", "value": "65", "unitCode": "LBR" }, "width": { "@type": "QuantitativeValue", "value": "60", "unitCode": "INH" }, "depth": { "@type": "QuantitativeValue", "value": "80", "unitCode": "INH" }, "height": { "@type": "QuantitativeValue", "value": "12", "unitCode": "INH" }, "offers": { "@type": "Offer", "@id": "https://www.example.com/products/product-x?size=medium#offer", "price": "799.99", "priceCurrency": "USD", "priceValidUntil": "2025-12-31", "availability": "https://schema.org/InStock", "url": "https://www.example.com/products/product-x?size=medium", "itemCondition": "https://schema.org/NewCondition", "shippingDetails": { "@type": "OfferShippingDetails", "shippingRate": { "@type": "MonetaryAmount", "value": "0.00", "currency": "USD" }, "shippingDestination": { "@type": "DefinedRegion", "addressCountry": "US" }, "deliveryTime": { "@type": "ShippingDeliveryTime", "handlingTime": { "@type": "QuantitativeValue", "minValue": 0, "maxValue": 1, "unitCode": "DAY" }, "transitTime": { "@type": "QuantitativeValue", "minValue": 1, "maxValue": 5, "unitCode": "DAY" } } }, "hasMerchantReturnPolicy": { "@type": "MerchantReturnPolicy", "applicableCountry": "US", "returnPolicyCountry": "US", "returnPolicyCategory": "https://schema.org/MerchantReturnFiniteReturnWindow", "merchantReturnDays": 60, "returnMethod": "https://schema.org/ReturnByMail", "returnFees": "https://schema.org/FreeReturn" } }, "isVariantOf": { "@id": "https://www.example.com/products/product-x#productgroup", "@type": "ProductGroup", "productGroupID": "PRD-X-2025", "name": "Product X" } }, { "@type": "Product", "@id": "https://www.example.com/products/product-x?size=large#variant", "sku": "PRD-X-LG-001", "gtin14": "10012345678903", "name": "Product X - Large", "description": "Product X in large size for maximum capacity and usage scenarios.", "size": "Large", "image": "https://www.example.com/images/products/product-x-large.jpg", "weight": { "@type": "QuantitativeValue", "value": "80", "unitCode": "LBR" }, "width": { "@type": "QuantitativeValue", "value": "70", "unitCode": "INH" }, "depth": { "@type": "QuantitativeValue", "value": "90", "unitCode": "INH" }, "height": { "@type": "QuantitativeValue", "value": "14", "unitCode": "INH" }, "offers": { "@type": "Offer", "@id": "https://www.example.com/products/product-x?size=large#offer", "price": "899.99", "priceCurrency": "USD", "priceValidUntil": "2025-12-31", "availability": "https://schema.org/InStock", "url": "https://www.example.com/products/product-x?size=large", "itemCondition": "https://schema.org/NewCondition", "shippingDetails": { "@type": "OfferShippingDetails", "shippingRate": { "@type": "MonetaryAmount", "value": "0.00", "currency": "USD" }, "shippingDestination": { "@type": "DefinedRegion", "addressCountry": "US" }, "deliveryTime": { "@type": "ShippingDeliveryTime", "handlingTime": { "@type": "QuantitativeValue", "minValue": 0, "maxValue": 1, "unitCode": "DAY" }, "transitTime": { "@type": "QuantitativeValue", "minValue": 1, "maxValue": 5, "unitCode": "DAY" } } }, "hasMerchantReturnPolicy": { "@type": "MerchantReturnPolicy", "applicableCountry": "US", "returnPolicyCountry": "US", "returnPolicyCategory": "https://schema.org/MerchantReturnFiniteReturnWindow", "merchantReturnDays": 60, "returnMethod": "https://schema.org/ReturnByMail", "returnFees": "https://schema.org/FreeReturn" } }, "isVariantOf": { "@id": "https://www.example.com/products/product-x#productgroup", "@type": "ProductGroup", "productGroupID": "PRD-X-2025", "name": "Product X" } } ] }