Skip to content
BENIBIX Learn

--strict-mcp-config Flag

Also known as claude --strict-mcp-config

It loads only the MCP servers you pass with --mcp-config.

Think of it like

It is like you say, we play with this one box. The rest stay on the shelf.

Example

Jack's eval runs must be the same on every laptop. He adds --strict-mcp-config, so no one's own servers sneak extra tools into the test.

Why it matters

Extra servers add tools that can change what Claude does. This keeps them out.

Definition

--strict-mcp-config skips the MCP servers set up in places such as .mcp.json, ~/.claude.json or a plugin. Only the servers you pass with --mcp-config load. Then a run gets the same servers on each machine. What each person set up does not count.

Example code

bash
claude --strict-mcp-config --mcp-config ./mcp.json
Use these servers and no others.
With --strict-mcp-config, only the passed servers load.

Common mistake

Using it with no --mcp-config. Then no MCP servers load at all.

Key takeaways

  1. 1
    Only yours. From --mcp-config.
  2. 2
    Skips the rest. .mcp.json, plugins.
  3. 3
    Same everywhere. Good for tests.

Compare

Learn it properly