# MCP servers
Codey is an MCP client over stdio. Servers go in the config by hand, in the
same shape Claude Code and Codex use, so an entry can be carried across from
either unchanged:
```json
{
"mcp_servers": {
"fs": { "command": "npx", "args": ["-y", "@modelcontextprotocol/server-filesystem", "."] },
"db": { "command": "my-db-mcp", "env": { "DB_URL": "postgres://localhost/dev" } }
}
}
```
Each server is started once, when the session opens, in the working root, and
every tool it lists is offered as `mcp__<name>__<tool>` — the name being the
key you gave it, not whatever the server calls itself. Subagents get the same
tools from the same processes. Every call prompts like `bash` does, with
"always this tool" to stop asking. A server that is not installed, does not
answer within thirty seconds or speaks a protocol version Codey does not is
reported at startup and left out; the session goes on without it. A server
that dies later is not restarted, and its tools say so when called.
Only tools are used: not resources, prompts or sampling, and no HTTP
transport. Pictures a tool returns are described to the model rather than
shown. A server's directory is fixed when it starts, so after `/worktree` it
is still serving the root the session began in. `-no-mcp` starts none of them
for one run.
## Claude Code's servers are not read
Only the servers in Codey's own `mcp_servers` are started. The ones Claude Code
keeps — in `~/.claude.json` (`claude mcp add`, either scope) and in a
repository's `.mcp.json` — are ignored, so a server is never started because a
clone or another program put it there. To use one here, copy its entry into
`mcp_servers`; the shape is the same.