← All tutorials
WebMCP & A2A

WebMCP & A2A — the agent stack grows outward

MCP connects an agent downward to tools and data. Two newer open protocols extend that in other directions: WebMCP brings MCP-style tools into the browser, and A2A connects agents sideways to other agents. Together they sketch an "agentic web."

Agent → tools

🔌 MCP

The base layer: an agent uses external tools & data through one standard protocol.

Agent → web page

🕸️ WebMCP

Websites expose tools to the AI agent in the browser, so it acts through the page, not by scraping it.

Agent → agent

🤝 A2A

Agents from different vendors discover each other and delegate tasks.

Moving target. Both are emerging 2024–2025 efforts (WebMCP is an early web-standards proposal; A2A was introduced by Google and moved to the Linux Foundation). Treat specifics here as the shape of the idea, not a frozen spec — check the current standards before building.

Base layer  Recap: where MCP sits

MCP (the Model Context Protocol) standardizes how an AI app connects to tools and data: a server exposes tools/resources/prompts, and any MCP host can discover and call them — turning an M×N integration mess into M+N. It's vertical: it links an agent down to capabilities.

agent↓ MCP tools · data · APIs

WebMCP and A2A keep that "one open protocol" philosophy but point it in new directions. If MCP is new to you, start with the APIs vs MCP guide, then come back.

In the browser  WebMCP — tools on the page

WebMCP emerging web-standards proposal

Solves Brittle web automation. Today a browser agent "uses" a website by reading the DOM and clicking pixels — fragile, slow and blind to intent. WebMCP lets a website itself declare tools (via a browser JavaScript API) that an in-page AI agent can call directly, with structured inputs — e.g. add_to_cart(sku) or search_flights(from, to, date). The site cooperates instead of being scraped.

Limits Early proposal — the API surface, browser support and (crucially) the security/permission model are still being worked out. It needs sites to adopt it, and running page-provided tools raises trust, consent and abuse questions the standard must answer. Expect churn.

Choose You're building a browser-based agent, or want your web app to be reliably usable by AI assistants — declaring intent-level tools beats hoping a scraper clicks the right button.

The mental model: WebMCP makes a web page behave like an MCP server whose client is the agent running in the browser. Same "declare tools, discover, call" idea — moved to the page.

Between agents  A2A — Agent2Agent

A2A Agent2Agent · introduced by Google, 2025 · now Linux Foundation

Solves Agent interoperability. Real work often needs a specialist agent built by another team, vendor or framework. A2A gives agents a common way to discover each other (a public Agent Card describing skills and endpoint), authenticate, and delegate tasks — exchanging messages, streamed progress and result artifacts — regardless of how each agent is built internally.

Limits Young, with adoption and trust/security still maturing; opaque "black-box" agents are harder to reason about than a typed tool call; and it overlaps with other coordination approaches, so the ecosystem is still shaking out. Multi-agent systems also add latency and failure modes.

Choose You're composing multiple autonomous agents — especially across teams or organizations — or exposing your agent so others' agents can call it.

MCP vs A2A in one line: MCP connects an agent to tools (vertical); A2A connects an agent to other agents (horizontal). An agent can be an A2A peer and an MCP host at the same time.

Big picture  How they fit together

One agent can speak all three at once — down to tools (MCP), out to the page (WebMCP), and across to peers (A2A):

How MCP, WebMCP and A2A connect an agent A central agent connects upward via WebMCP to a website, downward via MCP to tools and data, and sideways via A2A to other agents. WebMCP MCP A2A Your agent Website (in browser) database API files Specialist agent B Specialist agent C

The three are complementary, not competing: they cover different edges of the same agent. A shopping assistant might use WebMCP to operate a retailer's site, MCP to read your calendar, and A2A to hand payment off to a specialist finance agent.

Concretely  What they look like

The gist of each, in a few lines. Both are moving proposals — the exact shapes are illustrative.

emerging shapes (illustrative)
// WebMCP: a website registers a tool for the browser's AI agent, so the
// agent calls add_to_cart(sku) directly instead of scraping/clicking.
// (Proposal-stage API — the exact surface is still being standardized.)
window.agent?.registerTool?.({
  name: "add_to_cart",
  description: "Add a product to the shopping cart.",
  inputSchema: {
    type: "object",
    properties: { sku: { type: "string" } },
    required: ["sku"],
  },
  async execute({ sku }) {
    return await cart.add(sku);          // the site's own code runs
  },
});
Same DNA as MCP: declare a capability, publish a machine-readable description, let a client discover and invoke it. WebMCP declares tools on a page; A2A declares skills for an agent.

MCP vs WebMCP vs A2A

MCPWebMCPA2A
ConnectsAgent → tools/dataAgent → a website's toolsAgent → other agents
DirectionVertical (down)Vertical, in the browserHorizontal (across)
Runs whereLocal or remote serverIn the web page (client-side)Between networked agents
ExposesTools · resources · promptsPage-defined toolsAgent Card (skills)
DiscoveryClient lists server toolsPage registers tools with the browserFetch the agent's card
MaturityEstablished, growingEarly proposalYoung, gaining backers
Not either/or. They stack. The safe bet is still to build capabilities as plain APIs, wrap them in MCP for AI hosts, and reach for WebMCP or A2A when you specifically need in-browser tools or cross-agent delegation.

Cheat sheet

QuestionShort answer
What does WebMCP do?Lets a website expose tools to the AI agent in the browser — no scraping.
What does A2A do?Lets agents discover and delegate tasks to each other across frameworks/vendors.
MCP vs A2A?MCP = agent→tools (vertical); A2A = agent→agent (horizontal).
How does an agent advertise itself in A2A?An "Agent Card" (JSON) describing its skills and endpoint.
Can one agent use all three?Yes — MCP for tools, WebMCP in the browser, A2A to peers.
Biggest caveat?Both are emerging — specs and security models are still moving.

Knowledge check

Six questions on WebMCP and A2A. Pick an answer for each, then check your score.

1. What does WebMCP let a website do?

2. A2A is primarily about connecting…

3. In A2A, how does an agent advertise its capabilities?

4. How do MCP and A2A relate?

5. Why is WebMCP better than DOM scraping for browser agents?

6. What's the right posture toward both protocols today?

Next steps

🔌 APIs vs MCP

The base layer — how agents connect to tools, and the M×N problem MCP solves.

🧰 Agent Development Kits

Build the agents that speak these protocols — Google ADK, Strands, LangGraph.

📡 IoT × Agents

Agents acting in the world — a device-triggered agent that reasons and acts.

🧩 Build MCP from scratch

Get hands-on — build an MCP server and a client/task before extending to WebMCP/A2A.

📓 All tutorials

The hub — LLM apps, embeddings, retrieval, agent kits, AWS & IoT.