Chrome MCP: 'Browser extension is not connected' despite native messaging working correctly

Resolved 💬 4 comments Opened Apr 1, 2026 by sichiro Closed Jun 6, 2026

Bug Description

mcp__claude-in-chrome__tabs_context_mcp always returns "Browser extension is not connected" despite all components being functional individually.

Environment

  • Claude Code version: 2.1.89 (CLI, via ~/.local/bin/claude)
  • OS: macOS Darwin 25.4.0 (arm64)
  • Chrome: latest
  • Extension: Claude in Chrome (Beta) v1.0.64 (fcoeoabgfenejglbffodgkkbkcdhcgfn)
  • Session: launched via cmux (not VS Code)

What Works

  1. Extension installed & enabled — confirmed in chrome://extensions
  2. Native Messaging Hostcom.anthropic.claude_code_browser_extension.json correctly points to ~/.claude/chrome/chrome-native-host
  3. Native host script — shell wrapper calls ~/.local/share/claude/versions/2.1.89 --chrome-native-host
  4. Native host process — running correctly
  5. Chrome DevTools console testsendNativeMessage returns {type: 'pong'} successfully
  6. Unix socket — exists at /tmp/claude-mcp-browser-bridge-<user>/<pid>.sock
  7. Socket responds — length-prefixed JSON messages get responses (e.g., {"result":{"content":"Unknown method: ..."}})
  8. /chrome status — shows "Status: Enabled, Extension: Installed"
  9. /chrome → "Reconnect extension" — completes but doesn't fix

What Doesn't Work

  • mcp__claude-in-chrome__tabs_context_mcp always returns "Browser extension is not connected"
  • All chrome MCP tools fail with the same message

Root Cause Investigation

The socket responds with {"result":{"content":"Unknown method: tabs_context_mcp"}} for all MCP methods, suggesting the native host is listening but the Chrome extension's service worker hasn't established its connection to relay commands to the browser.

Additional Context

  • Claude.app conflict: Initially, com.anthropic.claude_browser_extension.json (Claude desktop app) was intercepting the Chrome extension connection. After removing it (backed up as .bak) and killing the Claude.app process, the CLI native host took over correctly — but the issue persists.
  • The native host socket PID matches the running 2.1.89 --chrome-native-host process
  • No errors in the extension's service worker DevTools console

Steps to Reproduce

  1. Install Claude in Chrome extension
  2. Ensure ~/.claude/chrome/chrome-native-host points to current Claude Code version
  3. Ensure com.anthropic.claude_code_browser_extension.json exists in Chrome NativeMessagingHosts
  4. Start Claude Code CLI session
  5. Call mcp__claude-in-chrome__tabs_context_mcp → always fails

Expected Behavior

Should connect to the Chrome extension and return tab context information.

View original on GitHub ↗

This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗