MCP Transport Mechanisms — stdio vs SSE
Core 6 min +25 XP
💡
THE ANALOGY
Phone call vs text message. A phone call (stdio) is direct, synchronous, and the connection stays open for the whole conversation. A text message (SSE) is asynchronous, event-based, and works across network boundaries. Different communication patterns for different contexts.
⚠️ EXAM TRAP — The Wrong Answer People Choose
Assuming stdio transport is always local. stdio is a process communication mechanism — it requires the MCP server to be running on the same machine as the client. SSE (Server-Sent Events) is used for remote MCP servers accessible over HTTP.
KEY POINTS
1 stdio transport: MCP server runs as a subprocess of the client — communication via stdin/stdout. Local only. Simple. Used for local tools.
2 SSE (Server-Sent Events) transport: MCP server runs as a remote HTTP server — communication over HTTP. Used for shared enterprise tools.
3 stdio is simpler to implement and more secure (no network exposure). SSE enables shared access across teams and systems.
4 The transport choice affects security model, deployment architecture, and latency characteristics.
5 Most Claude Code integrations use stdio. Enterprise shared tools use SSE.