Chrome integration: Claude Code never connects to native bridge socket (macOS)

Resolved 💬 2 comments Opened Mar 9, 2026 by noxomitanaka Closed Apr 6, 2026

Environment

  • Claude Code: 2.1.71
  • macOS: Darwin 25.3.0 (arm64, Sequoia)
  • Chrome: 145.0.7632.160
  • Chrome extension: Claude v1.0.59 (ID: fcoeoabgfenejglbffodgkkbkcdhcgfn)
  • Started with: claude --chrome

Problem

mcp__claude-in-chrome__tabs_context_mcp always returns "Browser extension is not connected" despite the native bridge socket being fully functional.

Diagnosis

What works

  1. Native Messaging Host launches correctly (Chrome → --chrome-native-host → creates Unix socket)
  2. Socket exists at /tmp/claude-mcp-browser-bridge-{username}/{pid}.sock with correct permissions (dir=0700, sock=0600, uid matches)
  3. Chrome extension responds to messages through the socket (verified via manual Python connection using Chrome's 4-byte LE length-prefix protocol — returns {"result":{"content":"Unknown method: ..."}} for test messages)
  4. Node.js stat() confirms: isSocket: true, mode 0600, uid matches process.getuid()

What fails

  • Claude Code (PID) never opens a connection to the socket — confirmed via lsof monitoring during tabs_context_mcp calls. Only the native host process appears on the socket; the Claude Code process never connects.
  • This was tested across 5+ restarts of both Claude Code and Chrome, with the socket verified to exist before each Claude Code launch.
  • Feature flag tengu_copper_bridge defaults to false, so the code path should use local socket via getSocketPaths → multi-socket client (kRT/ZRT). But the connection never happens.

Code analysis (minified binary)

  • h88() correctly routes to kRT (multi-socket client) when bridgeConfig is undefined and getSocketPaths exists
  • B77() (getSocketPaths) correctly scans /tmp/claude-mcp-browser-bridge-{username}/ for .sock files
  • Socket security validation (validateSocketSecurity) should pass (permissions and ownership are correct)
  • The connection class d5T uses this.context.getSocketPath?.() ?? this.context.socketPath — unclear if getSocketPath (singular) is properly wired from getSocketPaths (plural)

Steps to reproduce

  1. Install Chrome extension "Claude" from Chrome Web Store
  2. Verify socket exists: ls /tmp/claude-mcp-browser-bridge-$(whoami)/
  3. Start claude --chrome
  4. Call any mcp__claude-in-chrome__* tool
  5. Always returns "Browser extension is not connected"

Expected

Claude Code should connect to the existing socket and communicate with the Chrome extension.

View original on GitHub ↗

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