ENABLE_CLAUDEAI_MCP_SERVERS
Updated by Alex Sorokoletov
ENABLE_CLAUDEAI_MCP_SERVERS is a Claude Code environment variable: Enable Claude.ai-hosted MCP servers. Its release history is not tracked here. It is listed in the official reference.
| Status | Present in v2.1.294 |
|---|---|
| Category | MCP |
| Official docs | Listed |
How to set it
For one session, export it in the shell that starts Claude Code:
export ENABLE_CLAUDEAI_MCP_SERVERS=<value>
claudeTo apply it to every session, add it to the env object of a settings file:
// ~/.claude/settings.json
{
"env": {
"ENABLE_CLAUDEAI_MCP_SERVERS": "<value>"
}
}Related variables
CLAUDE_CODE_ENABLE_REFRESH_MCP_TOOLS: Enables an on-demand MCP-tool refresh capability, grouped with CLAUDE_CODE_ENABLE_TASKS and CLAUDE_CODE_ENABLE_REMOTE_RECAP.ENABLE_MCP_LARGE_OUTPUT_FILES: Enable large output files for MCP.CLAUDE_CODE_MCP_PREWAIT_SERVERSCLAUDE_CODE_MCP_PREWAIT_SERVERS_MSCLAUDE_CODE_SKIP_PLUGIN_MCP_SERVERSCLAUDE_CODE_SKIP_PLUGIN_MCP_SERVERS_EXCEPTCLAUDE_CODE_MAX_MCP_DESCRIPTION_LENGTHCLAUDE_CODE_MCP_ALLOWLIST_ENV: Specifies an allowlist of environment variables that MCP servers can access.
Frequently asked questions
What does ENABLE_CLAUDEAI_MCP_SERVERS do?
Enable Claude.ai-hosted MCP servers
Which Claude Code version has ENABLE_CLAUDEAI_MCP_SERVERS?
Its release history is not tracked here.
How do I set ENABLE_CLAUDEAI_MCP_SERVERS?
Export it before starting Claude Code (export ENABLE_CLAUDEAI_MCP_SERVERS=value), or add it to the "env" object in ~/.claude/settings.json to apply it to every session.
All variables, searchable: Claude Code environment variables.