Too many MCP servers? How they eat Claude Code's context

Too many MCP servers in Claude Code take little context with tool search on. Tools loaded upfront and big results still fill it, and /context shows which.

Contents

Too many MCP servers cost Claude Code less context than they used to. Tool search is on by default, so a session starts with each server's tool names and instructions only, and a full definition arrives when Claude calls that tool. Tools set to load upfront and large results still fill it. /context shows yours, and /mcp turns a server off per project.

"Never run more than a few MCP servers" dates from a Claude Code that sent every tool definition with every request. Everything below is from Anthropic's docs as read on 22 October 2026.

What an MCP server adds to every session#

Anthropic's MCP page, in its section on tool search: "Tool search keeps MCP context usage low by deferring tool definitions until Claude needs them. Only tool names and server instructions load at session start, so adding more MCP servers has minimal impact on your context window."

At session start, before your first message, each enabled server puts two things in the window:

  • one short line per tool, with its name
  • its server instructions, cut at 4,096 characters by default

Later in the session it adds:

  • a tool's full definition, once Claude finds it through the ToolSearch tool and calls it (a deferred tool's description is cut at 16,384 characters)
  • every result the tool returns, which is often the bigger share (see below)

The same page says Claude Code "doesn't impose a fixed per-server tool cap; the practical limit is your context window budget."

Illustration, not measured data. Two context windows side by side, each holding the same system prompt, tools and CLAUDE.md and five MCP servers. With tool search on, each server is a thin line of tool names and most of the window is room for your work. Loaded upfront, each server is a thick block of full definitions and the room left is much smaller. What MCP servers add before you typeIllustration, not measured dataTool search on (default)tool names and server instructionsSystem prompt, tools, CLAUDE.mdroom for your workLoaded upfrontfull definitions for every toolSystem prompt, tools, CLAUDE.mdroom for your work

When too many MCP servers still fill the context#

Full definitions go back into every request in these cases:

Situation What happens
ENABLE_TOOL_SEARCH=false Every MCP tool loads in full, every request
ENABLE_TOOL_SEARCH=auto (or auto:N) Tools load upfront until their definitions pass 10% (or N%) of the context window; then tool search turns on
A server set to "alwaysLoad": true That server's tools load in full, whatever the setting
A tool its author marked to load upfront That tool loads in full, unless your config sets the server to "alwaysLoad": false
A model before Claude Opus 4 and Sonnet 4 Claude Code loads all MCP tools upfront
Microsoft Foundry deployments hosted on Azure, or a HIPAA configuration Tool search is off

Results are the other half. A tool's output sits in the context like a file Claude read, until you run /clear or the chat compacts. Past 10,000 tokens in one MCP result, Claude Code prints a warning, and by default it limits the result to 25,000 tokens (set MAX_MCP_OUTPUT_TOKENS=50000 before claude to raise that). A text result longer than 50,000 characters goes to a file instead, and Claude opens the file when it needs it. So a database server that returns a whole schema, or a logging server that returns long logs, takes its space through tools/call results and not through its tool list.

How to see what MCP servers take up#

  1. Run /context. Its breakdown has an MCP tools row. Tools marked (deferred) or (loaded on-demand) take no space yet.
  2. On a subscription, run /usage. Its breakdown attributes recent usage to individual MCP servers, counting only the requests that carried one of that server's tool results, and it suggests changes for anything at 10% or more.
  3. Run /mcp for the list of configured servers and the status of each.

A large MCP tools row while tool search should be on usually means an alwaysLoad entry in .mcp.json or an ENABLE_TOOL_SEARCH value in your shell or in the env block of settings.json.

How to control which MCP servers load in a project#

  1. Toggle a server off in /mcp. Claude Code keeps its configuration and stops connecting to it in this project, and saves the choice per project in ~/.claude.json.
  2. Pick the scope when you add it. claude mcp add --scope user puts a server in every project on your computer. The default, local scope, keeps it to the current project, and --scope project writes it to the project's .mcp.json for the team. The scopes, and where each one is stored, are in setting up MCP servers once for every project.
  3. Use the CLI where there is one. Anthropic's words: tools like gh, aws, gcloud and sentry-cli "are still more context-efficient than MCP servers because they don't add any per-tool listing."
  4. Set alwaysLoad only on the few servers Claude needs on every turn. Each upfront tool takes context, and such a server also holds startup until its tools arrive, for up to the 5-second connect timeout. The docs' example:
json
{
  "mcpServers": {
    "core-tools": {
      "type": "http",
      "url": "https://mcp.example.com/mcp",
      "alwaysLoad": true
    }
  }
}
  1. In scripts, pin the list. claude -p --strict-mcp-config --mcp-config ./mcp.json uses only the servers in that file, and --disallowedTools "mcp__*" removes every MCP tool.
  2. For a server with huge results, ask for less in the prompt ("only the failing rows"), or call it from a subagent, whose context fills instead of yours.

When a project needs a server at all is a question of what it does; our list of the best MCP servers for Claude Code says what each one is for.

How Shuriken handles it#

Shuriken keeps one list of MCP servers for all your projects and accounts, Global MCPs, in Settings › Extensions › MCP servers. When you add one, it asks "Which projects can use it?": All projects, or the ones you pick. Chats your agents start in those projects get the server, and one sign-in covers every project that uses it (MCP servers, set up once for chosen projects has the details).

Each Claude Code chat also has a context meter by the message box. It opens a map of the window in a grid or a treemap, with MCP tools as their own block, and tools behind tool search listed as "Not loaded (tool search)". Under "What would free space", a server that takes real room gets the line "Turn off (server) for this chat to free (tokens)", with the server's name, the token count and a Turn off button. A server whose tools load only when used gets "loads its tools only when used, so turning it off frees almost nothing".

What a server's results take is still down to the server and the prompt. The rest of the context and usage picture is in why Claude Code uses so many tokens.

Sources

  1. Connect Claude Code to tools via MCP: scale with MCP tool search (Claude Code docs) (accessed 22 October 2026)
  2. Manage costs effectively: reduce MCP server overhead and the /usage breakdown (Claude Code docs) (accessed 22 October 2026)
  3. Explore the context window (Claude Code docs) (accessed 22 October 2026)
  4. CLI reference: --strict-mcp-config and --disallowedTools (Claude Code docs) (accessed 22 October 2026)
  5. Best practices for Claude Code: use CLI tools (Claude Code docs) (accessed 22 October 2026)

Frequently asked questions

Do MCP servers use context in Claude Code?

A little at the start. Tool search is on by default, so only tool names and server instructions load, and a full definition loads when Claude uses the tool. Servers or tools set to load upfront, ENABLE_TOOL_SEARCH=false, and every tool result still take context.

How many MCP servers is too many?

Claude Code sets no per-server tool cap; Anthropic says the practical limit is your context window. If /context shows a large MCP tools row while tool search is on, look for a server with alwaysLoad set.

How do I disable an MCP server for one project?

Run /mcp in that project and toggle the server off. Claude Code keeps its configuration and stops connecting to it there, and saves the choice per project in ~/.claude.json.

Do big MCP tool results fill the context?

Yes, like any tool output. Claude Code warns past 10,000 tokens, caps a result at 25,000 tokens by default (MAX_MCP_OUTPUT_TOKENS), and writes a text result over 50,000 characters to a file that Claude reads only when it needs it.

Free tools