Vercel has added an experimental way to expose existing server tools to AI agents operating inside a webpage. In MCPThe Model Context Protocol — an open standard that lets any AI assistant plug into any tool or data source without custom integration code.Full definition →-handler version 2.2.0, developers select which tools to expose and load a script from their MCP endpoint. That script registers the selected tools with the page using WebMCP, a proposed standard for browser-AI agentAn AI system that doesn't just answer once but works toward a goal in a loop — taking actions, reading the results, and deciding what to do next.Full definition → access. Release announcement.
When an agent invokes a tool, the script forwards the call to the existing server as the signed-in user. This lets authenticated tools reuse the user's session without adding a separate browser-side OAuth flow. The integration connects a page's agent interface to server functionality the developer already maintains. How it works.
Key takeaways · AI-distilled
mcp-handler adds experimental support for WebMCP, the proposed standard for exposing MCP tools to in-browser agents, via opt-in tools in an experimental_webMcp config object.
A single script tag loaded from your MCP endpoint (with a ?webmcp-script parameter) registers the opted-in tools on the page for in-browser agents to call.
The script proxies each browser-side tool call back to your MCP server as the signed-in user, so authenticated tools work without a separate browser OAuth flow.
The feature ships in mcp-handler@2.2.0.
Terms in this piece · Glossary
MCP — The Model Context Protocol — an open standard that lets any AI assistant plug into any tool or data source without custom integration code.
AI agent — An AI system that doesn't just answer once but works toward a goal in a loop — taking actions, reading the results, and deciding what to do next.