---
title: WebMCP
description: Experimental browser agent tools that expose storefront search and cart actions through the proposed WebMCP API.
url: "https://shop-docs.labs.vercel.dev/docs/anatomy/webmcp"
docs_index: /llms.txt
lastUpdated: 2026-09-30
type: guide
---

> For an index of all documentation, see [/llms.txt](/llms.txt).

WebMCP is an **experimental** browser API for exposing structured tools to AI agents running in or alongside a browser. The storefront can expose Shopify catalog search and cart actions through this API.

The integration is disabled by default. The proposed API may change or be removed, and unsupported browsers receive no fallback interface.

## Decide whether to enable it

Enable WebMCP only for active testing. When enabled in a supporting browser, Shopify registers storefront tools that agents can discover and call with structured inputs. Cart actions use the same cart the shopper sees.

Shopify defines and hosts the available tools. The template cannot select or change individual tools, and Shopify may update them independently.

WebMCP and Shopify analytics are separate choices. Enabling WebMCP loads Shopify's browser scripts, including consent, but does not enable Shopify page-view reporting.

## Test locally

For local testing, use a Chrome build that exposes the WebMCP testing flag:

1. Check that your Chrome build supports WebMCP testing.
2. Open `chrome://flags/#enable-webmcp-testing`.
3. Enable **WebMCP for testing**, then relaunch Chrome.
4. Set `shopify.webmcp.isEnabled` to `true` in `lib/config/index.ts`, then load the site.
5. Use a WebMCP inspector or a connected browser agent to list and invoke the registered tools.
6. Confirm that search returns structured catalog results and cart actions update the shopper's cart.

Browser support and origin-trial requirements can change. Check your browser's current WebMCP documentation before enabling it on a public deployment.

Leave the feature disabled for shoppers unless you accept the compatibility and stability limits of an experimental API.

---

For a semantic overview of all documentation, see [/sitemap.md](/sitemap.md)

For an index of all available documentation, see [/llms.txt](/llms.txt)

For agent-facing discovery, including API and MCP surfaces, see [/agents.md](/agents.md)