Cloud MCP servers fail to connect in proxy environment
Summary
Cloud MCP integrations (Extended Mind, Atlassian, Google Calendar) fail to connect when Claude Code is running behind an HTTP proxy, even though the proxy allows access to all required domains.
Environment
- Claude Code version: 2.1.81
- macOS (Darwin 25.3.0, arm64)
- Proxy: corporate HTTP proxy (CONNECT tunnel)
Proxy Configuration
In ~/.claude/settings.json:
{
"env": {
"HTTP_PROXY": "http://<proxy>:8080",
"HTTPS_PROXY": "http://<proxy>:8080",
"NO_PROXY": "127.0.0.1,localhost"
}
}
The Claude Code process confirms these env vars are set (ps eww shows them).
Symptoms
- At session start:
"Some MCP servers are still connecting: claude.ai Extended Mind, claude.ai Atlasssian MCP, claude.ai Google Calendar" - The servers never finish connecting — tools (
context_get,context_log, etc.) never become available ToolSearchreturns no results for any cloud MCP tool
Verified: Proxy works for all required domains
All relevant domains are reachable through the proxy (tested via curl --proxy):
| Domain | HTTP Status | Response Time |
|--------|-------------|---------------|
| api.anthropic.com | 404 | 0.11s |
| claude.ai | 403 | 0.11s |
| www.google.com | 302 | 0.36s |
| calendar.google.com | 200 | 0.29s |
| api.atlassian.com | 301 | 0.29s |
| id.atlassian.com | 301 | 0.16s |
| accounts.google.com | 302 | 0.21s |
Works in Claude Chat (Desktop App)
The same MCP integrations work correctly in the Claude Desktop app (chat mode) on the same machine and network. The Desktop app uses the same system proxy (scutil --proxy confirms HTTPS proxy is set to the same address).
Likely Cause
The cloud MCP client in Claude Code does not properly respect HTTP_PROXY/HTTPS_PROXY environment variables when establishing connections to cloud MCP server endpoints. The main API connection to api.anthropic.com works correctly through the proxy.
Steps to Reproduce
- Configure Claude Code with
HTTP_PROXY/HTTPS_PROXYpointing to a corporate proxy - Enable cloud MCP integrations (Extended Mind, Atlassian, Google Calendar)
- Start a Claude Code session
- Observe that cloud MCP servers remain in "connecting" state indefinitely
ToolSearchfor any cloud MCP tool returns no results
Expected Behavior
Cloud MCP servers should connect through the configured proxy, just as the main API connection does.
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗