What is MCP and how does it connect an AI agent to a browser?
Published December 5, 2026 · Updated December 5, 2026 · Mirage Browser
MCP, the Model Context Protocol, is an open standard that lets an AI application call tools of other programs. The application, such as Claude or Cursor, is the host; each program it talks to is a server. When a browser is an MCP server, the agent can open pages, read and click, and the browser decides which calls pass.
Why was MCP needed?
Before it, every AI application wrote its own connector for every tool. A browser plugin for one assistant did not work in another. MCP gives both sides one protocol: a tool written once as an MCP server works in any MCP host, and a host gains new abilities by adding servers instead of new code.
Who is who in MCP?
| Part | Role | Example |
|---|---|---|
| Host | The AI application the person uses; manages consent and the model | Claude Desktop, Claude Code, Cursor |
| Client | A connection inside the host, one per server | Created by the host for you |
| Server | A program that exposes tools, resources and prompts | A browser, a database, a file system |
Messages are JSON-RPC. A local server usually runs as a process the host starts, talking over standard input and output; a remote one is reached over HTTP.
What does a server expose?
- Tools: actions with typed arguments, such as
navigateorclick. The model decides when to call them. - Resources: data the host can read, such as a file or a page snapshot.
- Prompts: ready instructions a person can pick.
The specification also says servers should not see the whole conversation or each other: the host passes each server only what it needs.
Who decides what the agent may do?
Two places, and both matter. The host asks the person before connecting a server and can ask before tool calls. The server decides what each call is allowed to do in its own world. For a browser the second is the stronger check, because only the browser knows which profile, site and action a call touches. A model can be persuaded by text on a page; a server policy cannot.
How does a browser become an MCP server?
The browser app starts in MCP mode when the host launches it, and lists browser tools. With Mirage, one line in Claude Code:
claude mcp add mirage -- "/Applications/Mirage Browser.app/Contents/MacOS/Mirage Browser" --mcpThen the agent can call list_profiles, open_profile, navigate, snapshot, click and fill. Every call is checked against the profile’s policy: allowed domains, which risky actions wait for a person, and limits. Profiles without a policy stay closed to agents, and each call is written to a journal.
Is MCP safe?
The protocol carries calls; safety comes from what hosts and servers enforce. Give an agent the least it needs, keep risky actions behind approval and read the journal. More in How do I give an AI agent a browser without giving it everything? and on the AI agents and MCP page.