Home › Blog › Shopify Open Graph tags for AI shopping agents
Shopify Open Graph tags for AI shopping agents: why og:price:amount is a product discovery signal
Most Shopify merchants set up Open Graph once, confirm the Facebook preview looks right, and never touch it again. That was fine in 2022. In 2026, GPTBot, PerplexityBot, and Google-Extended are reading your OG tags to build shopping indexes — and the four properties your theme almost certainly does not set (og:price:amount, og:price:currency, product:availability, product:brand) are the exact ones AI agents use to filter and rank products.
og:price:amount on product pagesproduct:availability — the stock-filter signal AI agents read firstContents
Why AI crawlers read OG tags before JSON-LD
Open Graph was designed by Facebook in 2010 to control how URLs rendered in social feeds. For the next decade it was purely a social-sharing tool. That changed when large-language model shopping indexes started crawling the web at scale.
AI shopping agents — ChatGPT Shopping (GPTBot), Perplexity (PerplexityBot), Google AI Mode (Google-Extended), Amazon Rufus — build their product indexes by crawling HTML, not by calling your Shopify Admin API. When a crawler fetches a product page, it parses the document in layers:
- HTTP headers (Cache-Control, Last-Modified, Content-Type)
- <head> meta tags — including all
<meta property="og:…">tags - <script type="application/ld+json"> blocks — the Product JSON-LD
- Visible body text — product description, headings, copy
Steps 2 and 3 are both in the <head>, but meta tags are typically parsed by the crawler's key-value extractor before the JSON-LD parser finishes tokenising the potentially large Product graph. This means og:price:amount is often the first numeric price signal a crawler caches for a product URL.
og:price:amount is absent, the crawler may record the product with no price in its shopping index — making it invisible to "under $50" or "best price for X" queries — even if your Product JSON-LD has a perfectly formed offers.price.
The same applies to product:availability. AI shopping agents apply a stock filter before surfacing results in buy-intent queries ("buy X now", "where can I get Y"). If product:availability is absent, some crawlers default to assuming the product is out of stock rather than in stock. Others simply exclude it from inventory-filtered result sets until the next crawl returns a definitive signal.
The 6 OG properties that matter for product pages
The Open Graph protocol defines a product commerce namespace that extends the base OG spec. Here are the six properties worth setting on every Shopify product page, ranked by their impact on AI shopping indexes:
og:price:currency29.99) paired with an ISO 4217 currency code (USD). Used by AI agents for price-filtered queries ("under $30"), comparison ranking, and price-change alerts. Must be set together — amount without currency is invalid per the OG spec.instock, oos, preorder, pending, discontinued. AI shopping agents use this as a first-pass filter for buy-intent queries. Missing = ambiguous = often excluded.brand.name in your Product JSON-LD._800x) to avoid serving a 4 MB original.product.description | strip_html | truncate: 150. Acceptable default, but consider a dedicated product.metafields.seo.description value for higher-intent queries.new, refurbished, used. Required for Google Shopping and Amazon feeds; increasingly used by AI agents for resale/refurb queries. Most Shopify stores default to new and should set it explicitly rather than leaving it absent.What Dawn outputs by default — and what it misses
Shopify's Dawn theme (and its direct descendants — Craft, Sense, Crave, Studio, and most premium themes built on Dawn's architecture) outputs a reasonable base set of OG tags, but leaves the commerce namespace properties entirely absent:
| OG property | Dawn default | AI impact if missing |
|---|---|---|
| og:title | SET from product.title |
Low — crawlers fall back to <title> |
| og:url | SET from canonical | Low — crawlers use request URL |
| og:image | SET from featured image | Medium — some crawlers skip card generation |
| og:description | SET truncated description | Low — crawlers fall back to meta description |
| og:price:amount | MISSING | High — invisible to price-filtered queries |
| og:price:currency | MISSING | High — amount without currency is invalid |
| product:availability | MISSING | High — may be excluded from buy-intent results |
| product:brand | MISSING | Medium — brand queries may not surface the product |
| product:condition | MISSING | Low-medium — assumed new by most crawlers |
Third-party themes from Prestige, Turbo, Impulse, and Broadcast have similar gaps — the OG commerce namespace properties are rarely set because they were not part of Facebook's original OG priority list for social sharing previews.
The variant price problem
Shopify products with multiple variants (color, size, material) have a structural OG problem that goes beyond just adding missing tags. OG meta tags live in the <head> and are static on page load. Variant price changes happen via JavaScript — when a shopper clicks "Size: Large," the price displayed on screen changes, but the <meta property="og:price:amount"> in the head does not.
This means an AI crawler that fetches your product page sees the OG price for whichever variant Shopify renders as the default (usually the first active variant), regardless of which variant you intended as the canonical "hero" price.
The safest approach: use product.selected_or_first_available_variant in your OG Liquid output and ensure your product.liquid correctly pre-selects the variant you want indexed (typically the lowest-priced or highest-inventory variant).
For stores with extreme price ranges across variants (a product where size XS is $25 and size XXL is $60), consider whether you want to represent a single price in OG at all, or use a price range approach in your Product JSON-LD offers array instead — see our guide on Shopify subscription pricing and AI agents for a parallel treatment of the multi-price problem.
Liquid snippet: adding the missing four tags
Add this snippet to your theme's sections/main-product.liquid (or wherever your product <head> meta tags are rendered — check snippets/head-tags.liquid or layout/theme.liquid for the block that outputs og:title).
Find the block that looks like this in your theme:
{% if template.name == 'product' %}
<meta property="og:type" content="product">
<meta property="og:title" content="{{ product.title | escape }}">
<meta property="og:url" content="{{ canonical_url }}">
<meta property="og:image" content="{{ product.featured_image | image_url: width: 800 }}">
<meta property="og:description" content="{{ product.description | strip_html | truncate: 155 | escape }}">
{% endif %}
Immediately after the last existing <meta> tag in that block, insert:
{% comment %} OG commerce namespace — required for AI shopping agent price + stock indexing {% endcomment %}
{% assign og_variant = product.selected_or_first_available_variant %}
{% if og_variant and og_variant.price %}
<meta property="og:price:amount"
content="{{ og_variant.price | divided_by: 100.0 | round: 2 }}">
<meta property="og:price:currency"
content="{{ shop.currency }}">
{% endif %}
<meta property="product:availability"
content="{% if og_variant.available %}instock{% else %}oos{% endif %}">
{% if product.vendor != blank %}
<meta property="product:brand"
content="{{ product.vendor | escape }}">
{% endif %}
<meta property="product:condition" content="new">
Key notes on the snippet
divided_by: 100.0 | round: 2— Shopify stores prices as integers (cents). Dividing by 100.0 (float, not integer) produces a decimal.round: 2ensures you never output29.9999999from floating-point arithmetic.shop.currency— outputs the store's base currency as an ISO 4217 code (USD,EUR,GBP). If you use Shopify Markets with per-country pricing, this will always be the base currency — the per-market currency is a runtime variable that OG tags cannot represent statically. This is acceptable: AI crawlers do their own currency conversion.og_variant.available— Shopify'savailableliquid property returnstrueif the variant has quantity > 0 OR if the product has continue selling when out of stock enabled. It correctly maps toinstockvsoosfor standard inventory policies.product.vendor— Shopify's vendor field. If you use it for manufacturer/brand name (the recommended approach), this is the correct source. If your vendor field contains fulfillment partner names or warehouse names, clean those up before using this tag, or hardcode the brand name.
Related guides
Four mistakes that invalidate your OG tags
| money filter for og:price:amount
The money filter outputs a locale-formatted string: $29.99, €29,99, £29.99. The OG spec requires a plain decimal: 29.99. Facebook's validator will accept $29.99 because it strips the currency symbol, but AI crawler parsers may not. Always use | divided_by: 100.0 | round: 2.
og:price:amount without og:price:currency
The Open Graph commerce spec treats og:price:amount and og:price:currency as a pair. Amount without currency is undefined — is 29.99 US dollars, Japanese yen, or Hungarian forint? Google's product feed spec rejects amount-only prices. Always set both tags together.
product:availability as instock for all products
Some theme developers hardcode content="instock" to avoid complexity. When a product sells out, the OG tag remains instock indefinitely. AI crawlers that cache this value will continue surfacing the product for buy-intent queries, leading to user frustration when the product page shows out-of-stock. Always derive availability dynamically from og_variant.available.
og:image
Dawn correctly outputs an absolute Shopify CDN URL for og:image. But some custom themes or Liquid edits produce a relative path like /cdn/shop/products/photo.jpg. The OG spec requires absolute URLs. A relative URL will cause the image to fail in Facebook Debugger, Twitter Card Validator, and AI crawler image parsers simultaneously. Always ensure your og:image starts with https://.
How to test your OG output
Before and after applying the snippet, verify your OG output using a combination of these tools:
1. View source / curl
The simplest check. curl -s 'https://yourstore.myshopify.com/products/your-product' and search the output for og:price. If you see the tag with a numeric value, it is being rendered. If you only see og:title and og:url, you have the Dawn gap described above.
2. Facebook Sharing Debugger
Use Facebook's Sharing Debugger (developers.facebook.com/tools/debug) to see exactly how Facebook's crawler parses your OG tags. It surfaces missing required properties, invalid values, and stale cache. This is the most comprehensive validator for OG commerce namespace properties including og:price:amount.
3. LinkedIn Post Inspector
LinkedIn's inspector (linkedin.com/post-inspector) tests a subset of OG tags and is particularly useful for catching absolute-URL failures on og:image.
4. CatalogScan
CatalogScan's AI readiness scan checks OG completeness as one of its 18 scored signals. Run a scan on your domain to see exactly which OG properties are present, which are missing, and how the missing properties affect your overall AI readiness score. The scan also cross-checks OG price against your Product JSON-LD price to flag staleness mismatches.
See our guide on Shopify structured data testing for the full three-tool workflow we use to validate structured data and OG tags together before and after a theme edit.
Understanding the crawl lag
After you deploy the snippet, AI shopping indexes do not update immediately. GPTBot and PerplexityBot typically re-crawl Shopify product pages on a cadence determined by your site's crawl budget — usually between 3 and 21 days for an established store, faster for high-traffic stores with recent schema changes. To accelerate re-indexing, ping IndexNow for affected URLs and ensure your robots.txt does not restrict GPTBot or PerplexityBot. Review our guide on Cloudflare settings that silently block AI crawlers if your store uses Cloudflare and you are not seeing crawl activity in your logs.
FAQ
og:price:amount by default?og:title, og:url, og:image, and og:description for product pages, but does not output og:price:amount, og:price:currency, product:availability, or product:brand. These four properties are what AI shopping agents use for price filtering, stock filtering, and brand attribution queries — you need to add them manually using the Liquid snippet in this guide.og:price:amount and Product JSON-LD price for AI agents?og:price:amount is read from the HTML <head> on first parse — before JavaScript runs and before the crawler's JSON-LD parser processes the body. Product JSON-LD is more authoritative (it includes currency, condition, and eligibleQuantity), but it is parsed second. If og:price:amount is absent or stale, a crawler may cache a wrong price before ever reaching your Product schema. Both should be present and in sync.| money or a raw number for og:price:amount?| money. The OG spec requires a plain decimal like 29.99, not a formatted string like $29.99. In Shopify Liquid, output the raw value with {{ product.selected_or_first_available_variant.price | divided_by: 100.0 | round: 2 }}. Pair it with og:price:currency set to {{ shop.currency }}.product:availability have for out-of-stock products?oos when the selected variant is sold out and continue-selling is disabled. Use instock when available quantity is greater than zero. Use preorder for products in a pre-order window. AI shopping agents use this as a first-pass inventory filter — a product marked oos is excluded from most "buy now" queries even if your Product JSON-LD still shows InStock.og:price:amount, og:price:currency, product:availability, and product:brand on product pages, and also cross-checks that the OG price matches your Product JSON-LD price. Run a free scan to see your store's current OG signal score.See your store's OG signal score
CatalogScan checks all 18 AI readiness signals — including OG completeness — in under 60 seconds.
Run a free scan 100-store leaderboard