What is MCP (Model Context Protocol)?

MCP, the Model Context Protocol, is the open standard that lets a coding agent call external tools and read live data exposed by an MCP server, such as GitHub pull requests, Sentry errors, a browser or a database. Claude Code, Codex and Cursor are all MCP clients. Anthropic created MCP and donated it to the Agentic AI Foundation in December 2025.

Last updated
By
Published
In Polish
MCP (Model Context Protocol)
First set up at
All levels, free guide
Also searched as
Model Context Protocol, MCP server

$59.99 once for 12 months of access. Nothing renews on its own. 30-day refund on a first purchase.

On this page Why it mattersWhere each agent stores MCP serversWhich protocol revision each agent speaksHow each tool does itQuestions

Why it matters.

MCP is how an agent reaches state that lives outside the repository: pull requests, errors, tickets, a database. A server in the repo is a dependency every teammate and every agent session inherits, so it goes through the same path as a new package: confirm its publisher, scope it to read-only, and review the config file in a pull request.

Where each agent stores MCP servers

The three agents read different files, and each one fails differently when you use another agent’s syntax.

MCP server configuration files and commands in Claude Code, Codex and Cursor
TaskClaude CodeCodexCursor
Project scope (commit it) .mcp.json at the repo root .codex/config.toml, read only when the project is trusted .cursor/mcp.json
Personal scope claude mcp add (default local scope, per project in ~/.claude.json) or --scope user ~/.codex/config.toml (what codex mcp add writes) ~/.cursor/mcp.json
Remote server claude mcp add --transport http NAME URL codex mcp add NAME --url URL "url": "…" in mcpServers
Log in /mcp in a session, or claude mcp login NAME codex mcp login NAME From Cursor’s MCP settings when the server asks
Check claude mcp list, claude mcp get NAME codex mcp list, codex mcp get NAME --json The server’s status in Cursor’s MCP settings

The Claude Code and Codex cells were run on Claude Code 2.1.283 and codex-cli 0.157.1 on 2026-09-26. The Cursor file shapes come from vendor READMEs and were not tested in Cursor. Source: MCP overview, 2026-09-26.

Which protocol revision each agent speaks

The client, not the server, chooses the protocol, so a server that only speaks the new revision can work in one agent and fail in another.

Support for MCP specification 2026-07-28 in Claude Code, Codex and Cursor
AgentSpeaks 2026-07-28?Checked
Claude Code Negotiated by default with direct HTTP servers on all installs since v2.1.274, and with stdio servers from v2.1.292 (both release channels on 2026-10-17); opt out with MCP_PROTOCOL_NEGOTIATION=legacy Changelog, 2026-10-12; npm dist-tags, 2026-10-17
Codex No: mcp_2026_07_28 is under development and off, so connections use the older protocol codex features list, codex-cli 0.162.1, 2026-10-12
Cursor Not verified: cursor.com was unreachable on 2026-09-26 Not checked

Source: MCP overview, 2026-09-26.

How each tool does it.

Cursor, Claude Code and Codex each name this their own way. Each note carries the date it was checked.

Cursor

An MCP client: the docs list MCP among its capabilities. Support for spec 2026-07-28 was not verified on 2026-09-26.

The MCP overview gives .cursor/mcp.json as the project file and ~/.cursor/mcp.json as the personal one. Those shapes come from vendor READMEs and were not tested in Cursor (overview of 2026-09-26).

Cursor docs, 2026-08-28

Claude Code

claude mcp add --transport http NAME URL adds the server to your own local scope (in ~/.claude.json); --scope project writes the shared .mcp.json instead, which each teammate approves once and which shows as Pending approval until then.

Claude Code negotiates MCP spec 2026-07-28 with direct HTTP servers by default, on all installs since v2.1.274, and with local stdio servers from v2.1.292 (both release channels on 2026-10-17); MCP_PROTOCOL_NEGOTIATION=legacy opts out.

MCP overview, Claude Code 2.1.283, 2026-09-26

Codex

codex mcp add NAME --url URL writes ~/.codex/config.toml; a project .codex/config.toml is read only when the project is trusted.

Codex 0.162.1 does not speak MCP spec 2026-07-28 (mcp_2026_07_28 is under development and off, checked 2026-10-12; the same in 0.157.1), so a server that only speaks the new revision can work in Claude Code and fail in Codex. A headers = {…} table in config.toml is ignored: use http_headers, env_http_headers or bearer_token_env_var.

MCP overview, Codex CLI 0.162.1, 2026-10-12

Questions about MCP.

What is an MCP server?

A process that exposes tools, resources or prompts to the agent over MCP. The agent reads each tool’s name and description, decides when to call it and receives a structured result that becomes context for the next step. It runs locally over stdio, where the agent starts it, or remotely over Streamable HTTP, usually with OAuth. Add one with claude mcp add or codex mcp add.

Do all three tools support MCP?

Yes, all three are MCP clients, but not at the same protocol revision. On 2026-10-12 Claude Code negotiated spec 2026-07-28 with HTTP servers by default, and with stdio servers from v2.1.292 (on both release channels on 2026-10-17); Codex did not (mcp_2026_07_28 is under development and off, checked on 0.157.1 and again on 0.162.1); Cursor’s support was not verified. A server that only speaks the new revision can work in Claude Code and fail in Codex.

How is MCP different from Agent Skills?

A skill is instructions, not a live connection: it holds no credentials or server of its own. An MCP server is a running process that gives the agent new tools and live data. Each server adds tool definitions to the context, though Claude Code and Codex load them on demand through tool search, which is on by default.

Is a server from the registry safe to add?

Treat every server as a new trust boundary. The Official MCP Registry is still in preview and its only gate is namespace verification, so confirm the publisher against the vendor’s own README, scope the server to read-only, and add it through a reviewed pull request.

Does this page answer your questions?

One tap, no sign-in.

not at all fully

Read the guides in the same words.

Open every guide with the Toolkit. Each term is defined once here, and the guides use it the same way.

$59.99 once for 12 months of access. Nothing renews on its own. 30-day refund on a first purchase.