Browser tools, protocol, and runtime
WebMCP + MCP = MCP-B
MCP-B combines the WebMCP page API with MCP-style transport and extensions in one browser runtime. Use WebMCP for page-level tool registration. Use MCP-B for resources, prompts, relay, React hooks, and browser tooling. You can start with WebMCP and add MCP-B later.
Read What is WebMCP?, WebMCP vs MCP, and Native vs Polyfill vs Global.
Live on this page
This page has a real WebMCP tool. Try calling it.
The tool below is registered right now using navigator.modelContext.registerTool(). Use the MCP-B extension or Chrome’s native WebMCP support to call it from an AI agent.
Tool registration (live)
Resource registration (MCP-B)
Continue with the first tool tutorial, the @mcp-b/webmcp-polyfill reference, or the @mcp-b/webmcp-ts-sdk reference.
Packages
Browse the package set in one place.
These are the main packages in the workspace, grouped by the standard boundary.
Core WebMCP
| Package | Description |
|---|---|
Polyfills navigator.modelContext for browsers without native support | |
| TypeScript types for the WebMCP standard surface | |
| React hook for tool registration with automatic lifecycle |
MCP-B
| Package | Description |
|---|---|
| Entry point — sets up polyfill + MCP server in one import | |
| BrowserMcpServer with prompts, resources, sampling, elicitation | |
| PostMessage and WebSocket transports for cross-context communication | |
| Bridges tools across iframes via PostMessage | |
| React provider and hooks for MCP-B extensions |
Calling tools
| Package | Description |
|---|---|
| Bridges browser tools to desktop MCP clients via WebSocket + stdio | |
| Chrome extension tools for reading and interacting with pages | |
| MCP server that connects to Chrome DevTools Protocol |
