Claude Code /claude-in-chrome always "Browser extension is not connected"; surfaces as JSON Parse error: Unexpected identifier "Browser"
Claude Code /claude-in-chrome always "Browser extension is not connected" — never reaches extension; surfaces as JSON Parse error: Unexpected identifier "Browser"
Summary
Every mcp__claude-in-chrome__* tool call from Claude Code returns "Browser extension is not connected" instantly. list_connected_browsers reports zero browsers, and switch_browser returns immediately instead of waiting its 2-minute window — i.e. the request never reaches the extension. In the UI this also appears as:
Couldn't list connected browsers: JSON Parse error: Unexpected identifier "Browser"
This looks like the plain-text "Browser extension is not connected…" string being passed to JSON.parse() somewhere in the client.
The same Chrome extension pairs fine with the Claude desktop app (it spawns the desktop native host on demand), so the extension and account are healthy — only the Claude Code pairing fails.
Environment
- Claude Code: 2.1.191
- macOS: Darwin 25.5.0 (arm64)
- Node: v24.14.0 (nvm), installed at
~/.nvm/versions/node/v24.14.0/lib/node_modules/@anthropic-ai/claude-code - Chrome extension "Claude for Chrome": v1.0.77 (id
fcoeoabgfenejglbffodgkkbkcdhcgfn) - Single Google account, extension and Code both logged into the same account.
- Both the Claude desktop app and Claude Code register native-messaging hosts for the same extension id:
com.anthropic.claude_browser_extension→/Applications/Claude.app/Contents/Helpers/chrome-native-hostcom.anthropic.claude_code_browser_extension→~/.claude/chrome/chrome-native-host(wrapper →claude.exe --chrome-native-host)
Observed behavior / evidence
- Every tool (
tabs_context_mcp,list_connected_browsers,switch_browser) returns the "not connected" string immediately.switch_browserdoes not wait the documented 2 minutes — the request never leaves the client. - When the extension connects, it launches the desktop host (
/Applications/Claude.app/Contents/Helpers/chrome-native-host) and creates/tmp/claude-mcp-browser-bridge-<user>/<pid>.sock. It never launches the Claude Code host (~/.claude/chrome/chrome-native-host). - With the desktop native-messaging manifest temporarily removed and the extension reloaded, the extension launched no host at all — it never attempts the
com.anthropic.claude_code_browser_extensionhost name. - Config is enabled:
claudeInChromeDefaultEnabled: true,hasCompletedClaudeInChromeOnboarding: true,cachedChromeExtensionInstalled: truein~/.claude.json.
Things ruled out
- Account mismatch (both on the same account; verified
oauthAccount.emailAddressin~/.claude.json). - Desktop app contending for the extension (quit; orphaned host process killed; stale socket removed).
- Extension not installed / not logged in / disabled (visible and logged in via side panel).
- Stale extension state (full uninstall + reinstall of v1.0.77 — no change).
- Integration disabled in Code (
claudeInChromeDefaultEnabled: true; also relaunched with--chrome).
Repro
- macOS, Claude Code 2.1.191, "Claude for Chrome" extension v1.0.77, both on same account.
- Run
/claude-in-chrome(or anymcp__claude-in-chrome__*tool). - Every call returns "Browser extension is not connected" instantly;
list_connected_browsersshows none;switch_browserreturns immediately rather than waiting.
Likely root cause (guess)
The Code client appears to JSON.parse() a response that is actually the plain "Browser extension is not connected" text (hence Unexpected identifier "Browser"), and the extension never registers itself as a Code-controllable browser for this account — possibly a regression where the desktop and Code browser-pairing paths collide on the shared extension id.
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗