SYSTEM Cited by 1 source
WebMCP (Cloudflare)¶
WebMCP lets a website expose its actions directly to AI agents through the browser, instead of forcing an agent to parse the page's HTML and synthesize clicks. It is the "callable" primitive of the Agentic Internet and a browser-side companion to MCP (Source: sources/2026-08-06-cloudflare-building-an-open-agentic-internet).
The problem it solves¶
On the human web, actions like "add an item to a to-do list" are built for humans clicking through a UI. An agent trying to do the same has to "parse the HTML, guess which button is 'Add', synthesize a click, and hope the DOM didn't change since it last looked." That is brittle and opaque to the site owner.
The registerTool contract¶
WebMCP exposes a page's actions as explicit tools via a browser API,
document.modelContext.registerTool:
document.modelContext.registerTool({
name: "add-todo",
description: "Add a new item to the user's active todo list",
inputSchema: {
type: "object",
properties: {
text: { type: "string", description: "The todo item text" }
},
required: ["text"]
},
async execute({ text }) {
await addTodoItemToCollection(text);
return { content: [{ type: "text", text: `Added: "${text}"` }] };
}
});
The tool contract becomes explicit: no HTML parsing, no guessing at form fields. Because the tools run inside the page, they reuse the user's existing session and state — the agent acts with the same authority the human already has in that tab.
Relationship to Code Mode¶
Where WebMCP makes a page's actions callable, Code Mode goes one step further for agents that think in code: agents call endpoints by writing code rather than emitting prose tool calls, which Cloudflare argues is faster and more accurate. Because agents call endpoints instead of scraping pages, the content owner gets a clear signal of what content is actually used — the same discoverability/attribution benefit that motivates the broader Agentic Internet model.
Related¶
- systems/model-context-protocol · systems/code-mode · systems/kitesurf · systems/cloudflare-agents-sdk
- agentic-internet · server-side-tool-execution · dual-interface-human-and-agent
- companies/cloudflare