AI & GEO

How AI agents use your website with WebMCP

How forms and functions become tools for browser agents, what Chrome supports today and how to measure agent calls.

document.modelContextproduct_searchadd_to_cartcheck_delivery_timeAgent
Michael WeberLast updated: October 15, 20269 min read
In short
  • WebMCP is a proposed web standard. It lets a website register functions such as search, cart or appointment booking as tools that an AI agent in the browser can call directly.
  • As of October 15, 2026, WebMCP runs in Chrome as an origin trial from version 149. Edge is also running an origin trial. The specification is a draft of the W3C Web Machine Learning Community Group, and according to Google, Gemini in Chrome will support WebMCP soon.
  • Getting started is easy. Two attributes turn an existing form into a tool, and a property in the submit event shows you whether an agent or a human submitted it.

What is WebMCP?

Browser agents such as Gemini in Chrome, Claude in Chrome or Perplexity Comet mostly operate websites the way a human does. They read screenshots or the DOM, look for the right field and click. That is slow and breaks as soon as the layout changes. With WebMCP, the website itself describes which actions exist, which inputs they need and what comes back.

The proposal was developed by teams at Google and Microsoft. The first explainer appeared on 13 August 2025. The specification is a Draft Community Group Report of the W3C Web Machine Learning Community Group. This means WebMCP is not yet an official W3C standard, and details may change.

WebMCP and MCP

The name is based on the Model Context Protocol, which Anthropic introduced in 2024 and handed over to the Linux Foundation's Agentic AI Foundation in December 2025. Both use the same idea of tools with a name, a description and an input schema. However, they work in different places.

MCP serverWebMCP
Where the tools runOn a server, in the backendIn the browser, in the website's open tab
When availablePermanently, even without the website openOnly while the page is open
Who uses themAI assistants and coding agents that the user connects to the serverThe agent built into the browser
LoginSeparate registration per agent, often via OAuthThe user's existing session on the website
Typical exampleAn AI assistant reads the data of an SEO toolAn agent searches the shop and adds a product to the cart

How WebMCP works

Chrome offers two ways. The declarative variant extends existing HTML forms, the imperative one registers tools via JavaScript.

Declarative with forms

A form becomes a tool as soon as it carries toolname and tooldescription. The browser derives the input schema from the fields, their types and attributes such as required. With toolparamdescription you explain individual fields. Without toolautosubmit, the agent only fills in the form and the human submits it.

<form action="/search" toolname="product_search" tooldescription="Searches the shop for products by keyword and returns the list of results" toolautosubmit> <input name="q" required toolparamdescription="Search term, for example teak garden chair"> <button>Search</button> </form>

In the submit event, agentInvoked shows whether an agent triggered the form. Via respondWith() you return a structured result to it. According to the explainer, the declarative variant is not yet part of the specification. So the attribute names may still change.

Imperative via JavaScript

For configurators, carts or multi-step flows, you register a tool with document.modelContext.registerTool(). It needs a name, a description, an input schema as JSON Schema and a function that calls your existing logic.

const controller = new AbortController(); await document.modelContext.registerTool({ name: "add_to_cart", description: "Adds a product to the cart in the requested quantity", inputSchema: { type: "object", properties: { sku: { type: "string", description: "Item number" }, quantity: { type: "integer", minimum: 1, default: 1 } }, required: ["sku"] }, async execute({ sku, quantity = 1 }) { await cart.add(sku, quantity); // existing shop logic gtag("event", "webmcp_tool", { tool: "add_to_cart" }); // measure return `${quantity} × ${sku} is in the cart`; } }, { signal: controller.signal }); // unregister later, for example when the item is sold out controller.abort();

With annotations you mark tools that only read (readOnlyHint) or have consequences (consequentialHint). Older guides use navigator.modelContext. The specification and the Chrome documentation now use document.modelContext.

What can browsers and agents do today?

WhoAs of 15 October 2026
ChromeEarly Preview since 10 February 2026, origin trial from Chrome 149. Can be tested locally via chrome://flags/#enable-webmcp-testing.
Gemini in ChromeIn May 2026 Google announced that Gemini in Chrome will soon support WebMCP. Google gives no date for the broad rollout.
MicrosoftCo-author of the specification. WebMCP also runs in Edge as an origin trial, according to Microsoft until 30 March 2027.
Firefox, SafariNo public announcements found.
Chrome DevTools“WebMCP” panel under Application with all the page's tools and a log of the calls.

By default, WebMCP tools are only allowed on the page itself and in frames of the same origin. Frames of a different origin need allow="tools". Chrome describes the interface as a tool for flows in the browser where a human is present.

Measuring what agents do

Browser agents that work via screenshot and click often look like fast human visits in log files and web analytics. WebMCP, on the other hand, delivers clear signals.

  1. For imperative tools, you write an event directly in execute, as in the example above. The code runs on every call.
  2. For forms, you evaluate agentInvoked in the submit handler and send it as a parameter to your web analytics.
  3. Route the events into GA4, the dataLayer or your data warehouse so you can see the trend over weeks.
  4. Check the registration in the DevTools panel and test individual tools with the Model Context Tool Inspector extension.

Common mistakes

  • toolautosubmit is also set on forms that order, book or send data. Only let read-only actions such as a search submit automatically.
  • Descriptions are vague (“Form 1”). The agent chooses tools based on the description.
  • The code only uses navigator.modelContext and does not follow the current state of the specification.
  • Tools sit in a frame of a different origin without allow="tools".
  • Tools stay registered even though the action is currently not possible, for example with an empty cart.
  • Someone expects better rankings or more mentions in ChatGPT. No provider has announced any such effect. WebMCP makes your website usable for agents.

Frequently asked questions

What is the difference between WebMCP and MCP?

An MCP server runs in the backend and is permanently available to connected AI assistants. WebMCP tools are registered by the website in the browser, and they are only available while the page is open.

Is WebMCP already a standard?

Not yet. The specification is a draft of the W3C Web Machine Learning Community Group and is not on the W3C Standards Track (as of October 15, 2026).

How do I enable WebMCP in Chrome?

For local tests, set chrome://flags/#enable-webmcp-testing to Enabled and restart Chrome. For visitors to your website, sign up for the origin trial from Chrome 149.

Do I need WebMCP right now?

The reach is small today, because hardly any agent uses WebMCP. The effort for search and contact forms is small too. If you annotate and measure early, you will see when agents actually arrive.

How is it different from Playwright MCP?

Playwright MCP controls a browser from the outside via automation, much like a test script. With WebMCP, the website provides its tools itself and decides what an agent is allowed to do.

The searchVIU WebMCP Audit runs as part of the crawl. It records every form on every URL, detects WebMCP attributes and the tools that pages register during rendering, and flags outdated navigator.modelContext. It groups identical forms across many URLs and connects them with the clicks from Search Console. That way you see which forms are worth tackling first. The searchVIU MCP server is something else. It gives your AI assistant read access to your project's data. Find out more on the Agent Readiness page.

Request a demo

Sources

Retrieved on October 15, 2026. If something is out of date or missing, let us know.

  1. W3C Web Machine Learning CG, WebMCP (Draft Community Group Report): https://webmachinelearning.github.io/webmcp/ · As of Oct 15, 2026
  2. WebMCP explainer on GitHub: https://github.com/webmachinelearning/webmcp · first published Aug 13, 2025
  3. Chrome for Developers, WebMCP: https://developer.chrome.com/docs/ai/webmcp · As of Oct 7, 2026
  4. Chrome for Developers, Imperative API: https://developer.chrome.com/docs/ai/webmcp/imperative-api · As of Oct 15, 2026
  5. Chrome for Developers, Declarative API: https://developer.chrome.com/docs/ai/webmcp/declarative-api · As of Sep 25, 2026
  6. Chrome for Developers, WebMCP and MCP compared: https://developer.chrome.com/docs/ai/webmcp/compare-mcp
  7. Chrome for Developers, Early Preview Program: https://developer.chrome.com/blog/webmcp-epp · Feb 10, 2026
  8. Chrome for Developers, 15 updates from Google I/O 2026: https://developer.chrome.com/blog/chrome-at-io26 · May 19, 2026
  9. Chrome DevTools, WebMCP panel: https://developer.chrome.com/docs/devtools/application/webmcp · As of May 12, 2026
  10. Microsoft Edge, Origin Trials (WebMCP trial): https://developer.microsoft.com/en-us/microsoft-edge/origin-trials/trials · retrieved Oct 17, 2026
  11. Anthropic, Donating MCP to the Agentic AI Foundation: https://www.anthropic.com/news/donating-the-model-context-protocol-and-establishing-of-the-agentic-ai-foundation · Dec 9, 2025