Chrome MCP disconnects after Claude Code profile switch, requires multiple app relaunches
Bug Description
After switching Claude Code accounts (profile switch), the Claude-in-Chrome extension loses its connection to CC. mcp__Claude_in_Chrome__* tools become unavailable across ALL running sessions. Recovery requires relaunching the Claude desktop app 2-3 times.
Steps to Reproduce
- Have multiple CC sessions active with Chrome MCP working
- Switch CC account (log out / log in with different Google account in CC)
- CC reinitializes — Chrome extension's session binding drops
- All existing sessions: Chrome MCP tools fail silently (disconnected)
- New sessions also don't connect until app is relaunched 1-3 times
Root Cause
The Claude-in-Chrome extension holds a WebSocket/native-messaging session bound to the previous CC account context. When CC switches accounts, it doesn't signal the extension to reconnect with the new context. The chromeTabGroupId stored in session JSONs (%APPDATA%\Claude\claude-code-sessions\{accountUuid}\{projectUuid}\local_{sessionId}.json) also becomes stale.
Expected Behavior
After profile switch, CC should automatically re-establish the Chrome MCP connection without requiring an app relaunch.
Workaround
- Open
chrome-extension://fcoeoabgenejglbffodgkkbkcdhcgfn/options.html— this reinitializes the extension's CC connection (fixes connection drop) PreToolUsehook that propagates the freshestchromeTabGroupIdacross all sessions (fixes stale ID issue)
Both workarounds are client-side patches; the fix should be in CC's profile-switch flow.
Environment
- OS: Windows 11
- Claude Code: v2.1.101 (desktop / Electron)
- Frequency: 100% reproducible on every profile switch
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗