[FEATURE] Re-attach project-scoped .mcp.json MCP servers when a conversation is resumed

Status Open
Maintainer reply None cached
Activity 0 comments · opened Jul 27, 2026

Summary

When a conversation is resumed — after a VS Code window reload, or after closing and reopening a project — Claude Code does not re-read the project-scoped .mcp.json. The set of MCP servers is frozen at the moment the conversation was originally created. A project MCP server that was present at creation is dropped on resume and cannot be brought back into that conversation by any in-session action. The only way to get the server back is to start a brand-new conversation, which forces the user to abandon their working thread.

Environment

  • Claude Code VS Code extension (also reproducible via CLI --resume), 2026.
  • Project-scoped server declared in <workspace>/.mcp.json under mcpServers (stdio transport, command: node).

Steps to reproduce

  1. In a workspace with a valid .mcp.json declaring a stdio server (e.g. my-server), start a new conversation. my-server connects and its tools are available (/mcp lists it as connected). ✅
  2. Reload the VS Code window (Developer: Reload Window) or close and reopen the project. The extension re-activates; .mcp.json is unchanged and present on disk.
  3. Open (resume) the same conversation. /mcp no longer lists my-server at all; its tools are gone.
  4. Try to recover it in that conversation:
  • /mcp reconnect my-server / /mcp reconnect all → no effect (only acts on servers already in the loaded set).
  • /mcp enable my-server → no effect (server not in the set).
  • /reload-plugins → only affects plugin-bundled servers, not project .mcp.json.
  • claude mcp add ... from a terminal → written to disk but not picked up by the running session.
  1. The only thing that works: start a new conversation (which re-reads .mcp.json at session start). The resumed conversation can never regain the server.

Expected

Either of:

  • On resume, Claude Code re-reads the project .mcp.json and (re)connects its declared servers, the same way it re-reads settings.json/settings.local.json on resume; or
  • An in-session command to attach/load a project .mcp.json server that is not currently in the loaded set (e.g. /mcp add <server> / /mcp load / /mcp rescan).

Actual

The project server set is bound at conversation-creation time. Resume restores that frozen set and does not re-scan .mcp.json. No in-session command can attach a not-yet-loaded project server. Users must start a new conversation and lose their thread context.

Why this matters

For IDE integrations that provision a project-local .mcp.json (per-project tooling), users who reload the window or switch projects silently lose their tools on any long-lived conversation, with no in-product way to recover short of starting over. The session history is preserved, but the working thread and its tool access are not recoverable together.

Related

Appears to be the same underlying gap as several existing requests, which are closed as not planned / duplicate or still open:

  • #61474 (open) — /mcp reconnect / attach command
  • #46426 — hot-reload MCP servers without restarting the session (closed, not planned)
  • #17675 — /restart to reload MCP servers without losing session (closed, duplicate)
  • #34320 — /restart command (closed, not planned)
  • #47795 — reload/restart session shortcut (closed, duplicate)

Consolidating these under "re-attach project MCP on resume" would cover the concrete IDE-integration use case above.

View original on GitHub ↗