{"slug": "cloudflare-previews-automatic-webmcp-support-for-web-pages", "title": "CloudFlare Previews Automatic WebMCP Support for Web Pages", "summary": "Cloudflare announced a developer preview that lets any website enable a WebMCP (Web Model Context Protocol) interface with a single dashboard switch, allowing browser-based AI agents to interact with unmodified web pages through structured tools. The preview includes two tool packs: Content Credentials for reading C2PA metadata and Site MCP server for proxying MCP tools. The feature is available in Chrome 145+ and can be enabled via Agent Readiness > Labs in the Cloudflare Dashboard.", "body_md": "Cloudflare announced a [developer preview that lets any website enable a WebMCP](https://blog.cloudflare.com/webmcp/) (Web Model Context Protocol) interface with a single dashboard switch. This allows browser-based AI agents to interact with unmodified web pages through structured tools instead of scraping or guessing, keeping human traffic and control on the original site.\n\nThe core idea behind WebMCP is exposing structured, machine-readable tools directly to AI agents through a standard protocol. This allows them to call explicit functions like `searchFlights`\n\nor `bookTicket`\n\nwithout resorting to scraping and parsing HTML, which consumes tokens, or clicking UI buttons to trigger behavior. WebMCP makes interactions faster, more efficient, and far less fragile than traditional browser automation, which often breaks when the UI changes.\n\nTo adopt WebMCP, a website must expose its functionality as tools using either the [ document.modelContext API](https://developer.chrome.com/docs/ai/webmcp/imperative-api), which allows developers to register tools, define their schemas, and write the code that implements them, or a\n\n[declarative JavaScript API](https://developer.chrome.com/docs/ai/webmcp/declarative-api)that allows to add annotations to a standard HTML forms to create a WebMCP tool.\n\nWhat CloudFlare's current preview is aiming at is giving any site on Cloudflare the possibility to support WebMCP with a single switch by selecting *tool packs* from a pre-defined library. CloudFlare is currently including two tool packs in this preview: Content Credentials to allow agents to read C2PA content-provenance metadata from images on the page, and Site MCP server, which can proxy a site's MCP server tools to the in-browser agent. CloudFlare says the tool pack library will grow and that when new packs become available, a site can enable them without redeploying.\n\nCloudFlare's implementation is built around a `bridge.js`\n\nmodule, which is silently injected into a served webpage using HTMLRewriter:\n\n```\n<!-- Cloudflare injects this at the edge. Same origin, and your HTML is otherwise untouched. -->\n<script type=\"module\"\n        src=\"/.webmcp/bridge.js\"\n        data-packs=\"c2pa,mcp-server-client\"\n        data-mcp-url=\"/mcp\"></script>\n```\n\nThe module reference lists the tool packs adopted by the page in the `data-packs`\n\nattribute along with any additional parameter required (e.g., `data-mcp-url`\n\nfor the Site MCP server tool pack).\n\nFrom there, the bridge composes the packs named in\n\n`data-packs`\n\ninto one tool list and registers each with`.registerTool`\n\n. A pack is just a set of MCP tool descriptors and their handlers. Static packs, such as Content Credentials, declare their tools up front. A dynamic pack, such as the Site MCP Server pack, discovers its tools at boot before registering anything.\n\nExisting MCP tools running on the server are discovered through the standard MCP `Tool`\n\ntype, so for each of them the bridge registers a WebMCP proxy whose `execute()`\n\nmethod calls the site back on the same origin. Likewise, the bridge pass through a standard `CallToolResult`\n\nto handle the execution result.\n\nCloudFlare WebMCP preview is highly work in progress. The WebMCP standard is itself a preview and only supported in [Chrome 145+](https://developer.chrome.com/docs/ai/webmcp). You can enable WebMCP by going to Agent Readiness > Labs in the Cloudflare Dashboard, toggle on WebMCP for your domain, and select the desired tool packs.", "url": "https://wpnews.pro/news/cloudflare-previews-automatic-webmcp-support-for-web-pages", "canonical_source": "https://www.infoq.com/news/2026/08/cloudflare-webmcp/?utm_campaign=infoq_content&utm_source=infoq&utm_medium=feed&utm_term=global", "published_at": "2026-08-10 20:00:00+00:00", "updated_at": "2026-08-10 20:22:21.852054+00:00", "lang": "en", "topics": ["ai-agents", "ai-infrastructure", "developer-tools"], "entities": ["Cloudflare", "WebMCP", "Chrome 145", "C2PA", "Site MCP server", "HTMLRewriter", "bridge.js"], "alternates": {"html": "https://wpnews.pro/news/cloudflare-previews-automatic-webmcp-support-for-web-pages", "markdown": "https://wpnews.pro/news/cloudflare-previews-automatic-webmcp-support-for-web-pages.md", "text": "https://wpnews.pro/news/cloudflare-previews-automatic-webmcp-support-for-web-pages.txt", "jsonld": "https://wpnews.pro/news/cloudflare-previews-automatic-webmcp-support-for-web-pages.jsonld"}}