You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Feature: Lazy MCP server initialization (don't block startup) #26666
Claude Code blocks the input prompt until all configured MCP servers have spawned and completed their tool discovery handshake. With even 1-2 MCP servers configured, this adds 3-10+ seconds to every session start.
This is frustrating because the user can't type anything during this time, even though MCP tools are rarely needed in the very first prompt.
Proposed solution
Initialize MCP servers lazily or in parallel with user input:
Show the input prompt immediately
Spawn MCP servers in the background while the user types
If the first prompt doesn't need any MCP tools, there's zero perceived delay
If it does, wait only at tool invocation time (with a brief "connecting to MCP server..." indicator)
This is similar to how ENABLE_TOOL_SEARCH already defers tool definitions from context — but applied to the actual process startup.
Current workarounds
Remove all MCP servers from config (defeats the purpose)
Use --strict-mcp-config with an empty file (inconvenient)
Set MCP_TIMEOUT to cap wait time (still blocks)
Expected behavior
MCP server readiness should never block the user from typing their first prompt. The startup sequence should be:
1. Load config → instant
2. Show input prompt → instant
3. Spawn MCP servers → background (parallel with user typing)
4. User submits prompt → if MCP tools needed, wait for ready; otherwise proceed immediately
This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.
Activity
github-actions commentedon Feb 18, 2026
Found 3 possible duplicate issues:
This issue will be automatically closed as a duplicate in 3 days.
🤖 Generated with Claude Code
github-actions commentedon Feb 22, 2026
This issue has been automatically closed as a duplicate of #18497.
If this is incorrect, please re-open this issue or create a new one.
🤖 Generated with Claude Code
github-actions commentedon Mar 2, 2026
This issue has been automatically locked since it was closed and has not had any activity for 7 days. If you're experiencing a similar issue, please file a new issue and reference this one if it's relevant.