Shopify agents.md.liquid: Making Your Store Ready for AI Agents

Shopify is introducing agents.md.liquid, a new theme template designed to help AI agents and shopping assistants understand how to discover and interact with a Shopify store

Shopify agents.md.liquid: Making Your Store Ready for AI Agents
4 sections

The new agents.md.liquid template allows Shopify developers to customize the information that AI agents and shopping assistants use to discover a store's commerce capabilities. Shopify describes agents.md as the canonical, agent-facing description of a store.

What Is agents.md?

agents.md is a special file available at:

https://your-store.com/agents.md

Unlike traditional SEO files that are primarily designed for search engines, agents.md is designed specifically for AI agents and shopping assistants.

It can provide information such as:

  • Store information
  • Product and collection browsing URLs
  • Store policies
  • Universal Commerce Protocol (UCP) discovery
  • Model Context Protocol (MCP) endpoints
  • Guidance for shopping agents
  • Shopify automatically generates an agents.md file for every store, so most merchants don't need to create anything manually.

    Why Is This Important?

    Imagine a customer asking an AI shopping assistant:

    "Find me a pair of running shoes from this store under $100."

    Instead of an AI having to guess how the storefront works by reading HTML, agents.md provides a structured description of how the store can be discovered and interacted with.

    This is part of a broader shift from traditional human-only storefronts toward storefronts that can also communicate with AI-powered shopping agents.

    In other words:

    Traditional Store

    ↓ Human → Website → Products

    is evolving toward:

    AI Agent

    ↓ agents.md

    ↓ UCP / MCP

    ↓ Store Commerce Capabilities

    ↓ Products / Collections / Checkout

    Shopify Already Provides a Managed Version

    One of the most important details is that Shopify automatically manages agents.md by default.

    For most stores, this managed version is sufficient because Shopify keeps it aligned with the store's agent-discovery capabilities and commerce configuration.

    Therefore, developers shouldn't automatically add an agents.md.liquid file just because the feature exists.

    Shopify recommends customizing it only when your store has advanced requirements that aren't covered by the default version.

    What Is agents.md.liquid?

    If you need more control, you can create:

    templates/agents.md.liquid

    This template controls the content served at:

    /agents.md

    It uses a combination of Markdown and Liquid.

    For example:

    liquid
    # Agent Instructions — {{ agents.store_name }}
    
    This document describes how AI agents can interact with
    {{ agents.store_url }}.
    
    ## Commerce Protocol
    
    - Discovery: `GET {{ agents.ucp_discovery_url }}`
    - MCP endpoint: `POST {{ agents.mcp_endpoint_url }}`
    
    ## Supported UCP Versions
    
    {% for version in agents.ucp_versions %}
    - {{ version }}
    {% endfor %}

    Shopify provides a special agents object so developers can dynamically access important store and commerce information.

    The agents Object

    The agents object is particularly important because it helps developers avoid hardcoding information that could become outdated.

    It provides properties such as:

    PropertyPurpose
    agents.store_nameStore name
    agents.store_urlPrimary store URL
    agents.ucp_discovery_urlUCP discovery endpoint
    agents.mcp_endpoint_urlMCP endpoint
    agents.ucp_versionsSupported UCP versions
    agents.currencyPrimary store currency
    agents.sitemap_urlStore sitemap URL

    These values are automatically populated by Shopify and stay synchronized with the store's commerce configuration.

    This is preferable to hardcoding URLs such as:

    https://example.com/api/ucp/mcp

    because the agents object keeps these values up to date.

    An Important Difference From Normal Liquid Templates

    Developers need to be careful here.

    agents.md.liquid does not have the same Liquid context as a normal theme template.

    Only these objects are available:

    request

    agents

    Standard Shopify Liquid objects such as:

    {{ shop }}

    {{ collections }}

    {{ pages }}

    {{ blogs }}

    {{ articles }}

    aren't available in this template and will render blank.

    This restriction exists because the file needs to be safe to broadly cache and serve to AI agents.

    Therefore, if you want to include store information, use the agents object or explicitly hardcode the information you need.

    agents.md vs llms.txt

    Shopify also connects agents.md with the increasingly common llms.txt ecosystem.

    By default:

    /agents.md

    /llms.txt

    /llms-full.txt

    can provide the same agent-discovery content.

    If you want /llms.txt or /llms-full.txt to contain different information, you can create dedicated Liquid templates for those URLs.

    Tags
    Sources

    Related Articles

    Why Return Shipping Fees Are Now Taxed in the US – What Shopify Merchants Need to Know

    Why Return Shipping Fees Are Now Taxed in the US – What Shopify Merchants Need to Know

    Starting Oct 23 2026, Shopify Tax will automatically apply sales tax to return shipping fees for US orders. Learn who’s affected, how the calculation works, and the exact steps merchants and developers must take to stay compliant.

    September 25, 20266 min
    AI Toolkit Skills Consolidated into a Single `shopify` Skill – What Developers Need to Know

    AI Toolkit Skills Consolidated into a Single `shopify` Skill – What Developers Need to Know

    Shopify’s AI Toolkit now bundles all previously separate shopify‑* skills into one unified `shopify` skill. Learn who is impacted, why it matters, and the exact steps to update your environment.

    September 25, 20264 min
    Filterable Logs & Health Metrics Now Live in the Shopify Developer Dashboard

    Filterable Logs & Health Metrics Now Live in the Shopify Developer Dashboard

    Shopify’s latest update adds a filterable stream of logs and health metrics for custom apps directly in the Developer Dashboard, giving developers and merchants instant visibility into API usage, webhook health, and page performance.

    September 25, 20265 min
    Your New Command Center: Inside Shopify’s Revamped Dev Dashboard

    Your New Command Center: Inside Shopify’s Revamped Dev Dashboard

    Discover how Shopify’s updated Dev Dashboard centralizes store management, collaborator access, and app health. Learn who it impacts, what’s changed, and actionable steps to start using it today.

    September 25, 20264 min