Claude in Chrome browser extension not connecting to Claude Code CLI

Open 💬 50 comments Opened Jan 23, 2026 by dev-dav-ui

Environment:

  • Claude Code version: 2.1.17
  • macOS: Darwin 25.2.0
  • Chrome extension version: 1.0.40 (installed in Profile 31)

Description:
The Claude in Chrome browser extension works correctly on its own (side panel functions properly), but Claude Code CLI
cannot connect to it to control the browser.

Steps to reproduce:

  1. Install Claude in Chrome extension (version 1.0.40)
  2. Run claude --chrome in terminal
  3. Call tabs_context_mcp tool
  4. Receive error: "Browser extension is not connected"

Troubleshooting attempted:

  • Fully quit Chrome (Cmd+Q) and reopened
  • Toggled extension OFF/ON in chrome://extensions/
  • Opened Claude side panel (Cmd+E)
  • Verified native messaging host exists and is configured correctly

Native messaging host configuration:
File: ~/Library/Application Support/Google/Chrome/NativeMessagingHosts/com.anthropic.claude_code_browser_extension.json

{
"name": "com.anthropic.claude_code_browser_extension",
"description": "Claude Code Browser Extension Native Host",
"path": "/Users/dhanapale/.claude/chrome/chrome-native-host",
"type": "stdio",
"allowed_origins": [
"chrome-extension://fcoeoabgfenejglbffodgkkbkcdhcgfn/"
]
}

Native host script:
#!/bin/sh
exec "/Users/dhanapale/.local/share/claude/versions/2.1.17" --chrome-native-host

Expected behavior:
Claude Code CLI should connect to the browser extension and be able to control Chrome tabs.

Actual behavior:
tabs_context_mcp always returns "Browser extension is not connected" even though:

  • The extension is installed and functional
  • The side panel works correctly
  • Native messaging host files exist and are properly configured
  • Chrome process shows --claude-in-chrome-mcp flag running

View original on GitHub ↗

50 Comments

github-actions[bot] · 5 months ago

Found 3 possible duplicate issues:

  1. https://github.com/anthropics/claude-code/issues/17851
  2. https://github.com/anthropics/claude-code/issues/19557
  3. https://github.com/anthropics/claude-code/issues/14894

This issue will be automatically closed as a duplicate in 3 days.

  • If your issue is a duplicate, please close it and 👍 the existing issue instead
  • To prevent auto-closure, add a comment or 👎 this comment

🤖 Generated with Claude Code

ghost · 5 months ago

not connecting here...

EliMunkey · 5 months ago

Same issue here.

  • Claude Code: 2.1.19
  • macOS: 26.2
  • Chrome extension: 1.0.40
  • Extension works in sidebar, but CLI cannot connect
  • Tried: restarting Chrome, enabling "Allow JavaScript from Apple Events", reinstalling extension

The connection page opens briefly then closes immediately.

E-ChintanGohil · 5 months ago

I had same issue :

Solution applied by Claude Code and Explained !!

What happened:

  1. Both Claude Desktop app and Claude Code CLI can use the Chrome extension for browser

automation

  1. There were two native messaging host config files:
  • com.anthropic.claude_browser_extension.json → pointed to Claude Desktop app
  • com.anthropic.claude_code_browser_extension.json → pointed to Claude Code CLI
  1. The Chrome extension was using the first config file, which directed all connections to Claude

Desktop app instead of Claude Code CLI

The fix:

I updated com.anthropic.claude_browser_extension.json to point to Claude Code CLI's native host
path (~/.claude/chrome/chrome-native-host) instead of the Claude Desktop app path
(/Applications/Claude.app/...)

Note: If you reinstall or update Claude Desktop app, it may overwrite this config and you'll need
to update it again. To avoid this, you can either:

  • Not run Claude Desktop app while using Claude Code CLI for browser automation
  • Or re-apply the fix if the config gets overwritten
joemccann · 5 months ago

@E-ChintanGohil your solution worked. Here's the steps to fix for others:


# 1. Check what config files exist
echo "=== Checking native messaging host configs ==="
ls -la ~/Library/Application\ Support/Google/Chrome/NativeMessagingHosts/

# 2. Show current Desktop app config
echo -e "\n=== Current Claude Desktop config ==="
cat ~/Library/Application\ Support/Google/Chrome/NativeMessagingHosts/com.anthropic.claude_browser_extension.json

# 3. Back up the original
echo -e "\n=== Creating backup ==="
cp ~/Library/Application\ Support/Google/Chrome/NativeMessagingHosts/com.anthropic.claude_browser_extension.json \
   ~/Library/Application\ Support/Google/Chrome/NativeMessagingHosts/com.anthropic.claude_browser_extension.json.backup

# 4. Update the config to point to Claude Code's native host
echo -e "\n=== Updating config to use Claude Code ==="
cat ~/Library/Application\ Support/Google/Chrome/NativeMessagingHosts/com.anthropic.claude_browser_extension.json | \
  sed 's|/Applications/Claude.app/[^"]*|'"$HOME"'/.claude/chrome/chrome-native-host|g' > /tmp/claude_browser_extension.json && \
  mv /tmp/claude_browser_extension.json ~/Library/Application\ Support/Google/Chrome/NativeMessagingHosts/com.anthropic.claude_browser_extension.json

# 5. Verify the change
echo -e "\n=== Updated config ==="
cat ~/Library/Application\ Support/Google/Chrome/NativeMessagingHosts/com.anthropic.claude_browser_extension.json

# 6. Reminder
echo -e "\n=== NEXT STEPS ==="
echo "1. Fully quit Chrome (Cmd+Q)"
echo "2. Restart Chrome"
echo "3. Run: claude --chrome"
echo ""
echo "NOTE: If you update Claude Desktop, you may need to re-run this script."
agamm · 5 months ago
Solution applied by Claude Code and Explained !! What happened: 1. Both Claude Desktop app and Claude Code CLI can use the Chrome extension for browser automation 2. There were two native messaging host config files: - com.anthropic.claude_browser_extension.json → pointed to Claude Desktop app - com.anthropic.claude_code_browser_extension.json → pointed to Claude Code CLI 3. The Chrome extension was using the first config file, which directed all connections to Claude Desktop app instead of Claude Code CLI The fix: I updated com.anthropic.claude_browser_extension.json to point to Claude Code CLI's native host path (~/.claude/chrome/chrome-native-host) instead of the Claude Desktop app path (/Applications/Claude.app/...) Note: If you reinstall or update Claude Desktop app, it may overwrite this config and you'll need to update it again. To avoid this, you can either: Not run Claude Desktop app while using Claude Code CLI for browser automation Or re-apply the fix if the config gets overwritten

Just to simplify for anthropic team: if calude desktop is installed after cc it will overwrite the correct chrome path causing cc not to connect to chrome.

Junhan2 · 5 months ago

Solution Verified ✅

I had the same issue and successfully resolved it using the solution mentioned by @E-ChintanGohil and @joemccann.

Root Cause

When Claude Desktop app is installed, it overwrites the native messaging host config to point to its own path instead of Claude Code CLI.

Before (broken):

{
  "name": "com.anthropic.claude_browser_extension",
  "path": "/Applications/Claude.app/Contents/Helpers/chrome-native-host",
  ...
}

After (working):

{
  "name": "com.anthropic.claude_browser_extension",
  "path": "/Users/<username>/.claude/chrome/chrome-native-host",
  ...
}

Quick Fix (macOS)

# 1. Backup original config
cp ~/Library/Application\ Support/Google/Chrome/NativeMessagingHosts/com.anthropic.claude_browser_extension.json \
   ~/Library/Application\ Support/Google/Chrome/NativeMessagingHosts/com.anthropic.claude_browser_extension.json.backup

# 2. Update path to Claude Code CLI
sed -i '' "s|/Applications/Claude.app/Contents/Helpers/chrome-native-host|$HOME/.claude/chrome/chrome-native-host|g" \
   ~/Library/Application\ Support/Google/Chrome/NativeMessagingHosts/com.anthropic.claude_browser_extension.json

# 3. Verify the change
cat ~/Library/Application\ Support/Google/Chrome/NativeMessagingHosts/com.anthropic.claude_browser_extension.json

After Fix

  1. Quit Chrome completely (Cmd+Q)
  2. Restart Chrome
  3. Run claude --chrome and test with tabs_context_mcp

Environment

  • Claude Code: 2.1.19
  • macOS: Darwin 25.2.0
  • Chrome extension: 1.0.40

Hope this helps others facing the same issue! 🎉

thelabvenice · 5 months ago

yes fixed thx

krusty · 5 months ago

Additional Debugging Step

If you've already applied the fix from @joemccann and @E-ChintanGohil (updating the native messaging host config) but it's still not working, check for a stale native host process with a deleted socket.

Symptoms

  • claude mcp list shows claude-in-chrome · connected
  • Extension sidebar works (shows "Tabs read")
  • But Claude Code still gets "Browser extension is not connected" error

Diagnosis

# Check if native host is running with a deleted socket
ps aux | grep 'chrome-native-host' | grep -v grep
# If running, check if socket file actually exists:
ls -la /var/folders/*/T/claude-mcp-browser-bridge-*
# If ls shows "No such file" but lsof shows the socket, it's stale:
lsof -p <PID> | grep unix

Fix

# Kill the stale native host
pkill -f 'chrome-native-host'

# Then either:
# 1. Restart Chrome (Cmd+Q, reopen), OR
# 2. Just open Claude side panel (Cmd+E) to spawn fresh native host

This happens when the socket file gets deleted but the native host process keeps running, leaving Chrome connected to a socket that Claude Code can't find.

HunterJayPerson · 5 months ago

Same issue here, above fixes didn't help. A report generated by Claude Code after trying to debug:

Bug Report: Claude for Chrome MCP tools return "Browser extension is not connected" despite everything being correctly configured

Environment

  • OS: Windows 11
  • Node.js: v24.12.0
  • Claude Code: Latest (installed via npm globally)
  • Chrome Extension: Claude in Chrome (ID: *************gfn)
  • Claude Desktop: Not installed

Symptoms

  • /chrome shows "Status: Enabled, Extension: Installed"
  • /plugin reports "Reconnected to claude-in-chrome"
  • Extension works fine directly in Chrome browser
  • But all MCP tool calls (mcp__claude-in-chrome__*) return: "Browser extension is not connected" [as reported by Claude Code]

Verified Working Components

  1. Chrome is running:

chrome.exe running (multiple processes)

  1. Native messaging host registered correctly:

Registry: HKCU\Software\Google\Chrome\NativeMessagingHosts\com.anthropic.claude_code_browser_extension
Points to: C:\Users\*****\AppData\Roaming\Claude Code\ChromeNativeHost\com.anthropic.claude_code_browser_extension.json

  1. Config file contents (correct):

{
"name": "com.anthropic.claude_code_browser_extension",
"description": "Claude Code Browser Extension Native Host",
"path": "C:\\Users\\*****\\.claude\\chrome\\chrome-native-host.bat",
"type": "stdio",
"allowed_origins": [
"chrome-extension://fcoeoabgfenejglbffodgkkbkcdhcgfn/"
]
}

  1. Batch script contents (correct):

@echo off
REM Chrome native host wrapper script
REM Generated by Claude Code - do not edit manually
"C:\Program Files\nodejs\node.exe" "C:\Users\hunte\AppData\Roaming\npm\node_modules\@anthropic-ai\claude-code\cli.js" --chrome-native-host

  1. Native host process spawns correctly:

PID 9200 : "C:\Program Files\nodejs\node.exe" "...\cli.js" --chrome-native-host

  1. Named pipe is created and accessible:

\\.\pipe\claude-mcp-browser-bridge-hunte
PowerShell can connect to this pipe successfully:
$pipe = New-Object System.IO.Pipes.NamedPipeClientStream(".", "claude-mcp-browser-bridge-hunte", [System.IO.Pipes.PipeDirection]::InOut)
$pipe.Connect(1000) # SUCCESS

  1. MCP client process runs:

PID 16096 : "...\cli.js" --claude-in-chrome-mcp

Debugging Steps Attempted, Multiple Times, In Various Orders (all failed to resolve)

  1. Restarted Chrome multiple times
  2. Restarted Claude Code with --chrome flag
  3. Restarted entire computer
  4. Killed stale native host processes and let Chrome respawn fresh ones
  5. Used /chrome → "Reconnect extension"
  6. Used /plugin to reconnect (reports success but tools still fail)
  7. Disabled/re-enabled Chrome extension
  8. Killed multiple competing MCP client processes
  9. Verified no Claude Desktop installation (no competing com.anthropic.claude_browser_extension)

Key Observation

The disconnect appears to be between:

  • The CLI's internal state (which thinks it's connected after /plugin)
  • The actual MCP tool execution (which fails with "not connected")

The native host, named pipe, and MCP client all appear to be running correctly. The Chrome extension works fine when used directly in the browser. But the bridge between Claude Code's MCP tools and the native host is broken.

Process List When Issue Occurs

PID 9200 : cli.js --chrome-native-host (Native host - spawned by Chrome)
PID 16096 : cli.js --claude-in-chrome-mcp (MCP client)
PID 13228 : cli.js (Claude Code session 1)
PID 25944 : cli.js (Claude Code session 2)

alexbleakley · 5 months ago

For me, the native host works when run manually - creates pipe \\.\pipe\claude-mcp-browser-bridge-bleak and listens for connections. All config verified correct (registry, JSON manifest, batch file).

But Chrome never spawns it. Extension (v1.0.40) works fine in browser (sidebar, etc.) but never initiates the native messaging connection.

Claude's conclusion is that the extension never calls chrome.runtime.connectNative(). Something in the extension's connection trigger is broken or missing.

---
Update 2026-01-27. Further analysis by Claude:

What works (tested manually)

  1. Native host responds correctly when spawned manually and sent Chrome native messaging format via stdin
  2. Pipe communication works - connecting to the named pipe with length-prefixed JSON succeeds

What fails

When Chrome spawns the native host (via connectNative()):

  • Process runs (visible in task manager)
  • Pipe is created and accepts connections
  • But no response to pipe messages - times out

Implication

The native host code is fine. The failure is somewhere in the Chrome → native host initialization path. Either:

  • Extension isn't sending expected init messages after spawning
  • Chrome's process environment differs from manual spawn
  • Timing issue between native host startup and MCP server connection attempt
ghost · 5 months ago

@alexbleakley @HunterJayPerson as bizarre as this might sound, i have fixed by downloading Claude Desktop, forcing the conflict reported in the other responses and applying the workaround.

alexbleakley · 5 months ago

Thanks, @gabrielmonteiro-vtexads. I was desperate enough to give the Claude Desktop trick a go, but sadly it didn't resolve anything for me.

HunterJayPerson · 5 months ago

@gabrielmonteiro-vtexads Also didn't work for me, thanks anyway though.

HunterJayPerson · 5 months ago

I downgraded to Claude Code 2.1.19 and that solved the problem! Recommend avoiding Claude Code 2.1.20 if you are on Windows and using Claude for Chrome.

alexbleakley · 5 months ago

Thanks, @HunterJayPerson! I had tried this previously but I think I was at that time running into #16691.

The combination of the bun workaround I posted in #16691, installing claude 2.1.19 with npm, and running claude from ...\AppData\Roaming\npm\claude worked for me. But I spent a while debugging so I can't rule out that something else I did along the way was also necessary.

rambouhh · 5 months ago

@alexbleakley @HunterJayPerson rolling it back worked for me too, also on windows

agrath · 5 months ago

Still broken in 2.1.23 but working in 2.1.19, tried the json/path patch mentioned in https://github.com/anthropics/claude-code/issues/20298#issuecomment-3796542141 and restarting everything of course.

On my machine, I had switched to _claude native installer_ so couldn't use npm uninstall -g @anthropic-ai/claude-code and npm install -g @anthropic-ai/claude-code@2.1.19 to downgrade, claude --version always returned 2.1.23

Reverted with claude install 2.1.19 and chrome integration started working straight away with no other restarts required

subflow · 5 months ago

@agrath did like you claude install 2.1.19 and it worked right away after that. I have been uninstalling browsers, and extensions and reinstalled claude with no success. But 2.1.19 worked right away. Thanks!

mattnathan · 5 months ago

I'm having similar issues. A new Claude CLI session would connect to chrome, load a page, but then it'd get stuck with something (maybe it forgot to start the api or something). After fixing the issue it would try to load the page (tab_context) again and find it was disconnected. Restarting chrome and claude sessions did nothing. Running /chrome -> Reconnect did not fix it either.

I just managed to fix it while in session by running the following (in Claude Code CLI session):

/mcp
Select claude-in-chrome (said it was connected)
Select 2. Reconnect

I don't know why this worked and the /chrome version didn't. I don't know if this actually fixed things or it was a coincidence 🤷 It remained working for the rest of the session.

Anyway, running Claude Code 2.1.23

ginko-ai · 5 months ago

Appreciate the previous comments. I fixed my issue by downgrading to 2.1.19

ChrispyKreme86 · 5 months ago

same issue here:

macOS, Mac mini,
Claude Code v2.1.25, extension v1.0.41

edwinhu · 5 months ago

Subscribing for updates

ChrispyKreme86 · 5 months ago

Upgrading to the latest version fixed it for me. 2.1.29

GOUKI9999 · 5 months ago

Win11 user
Upgrading to the latest version now works for me. 2.1.29same issue
I had even removed Claude Desktop before
/mcp fine
/chrome fine
but can't connectet it from Claude Code

HunterJayPerson · 5 months ago

Confirmed the issue is fixed in 2.1.29 on my side, Win 11.

HunterJayPerson · 5 months ago

And back to not working in 2.1.31 for me, and reverting to 2.1.29 didn't fix it, but going all the way back to 2.1.19 did. I'm not sure what the actual underlying behaviour is, but this is what I noticed on the surface. Back to working on 2.1.19.

drrehak · 5 months ago

i rolled back to 2.1.19. no luck for me

benjamin-benz-42 · 5 months ago

For me (Mac) 2.1.31 is working partially:

  • it hates when two instances use it in parallel but in different Tabs
  • it somehow looses connection when it was idle too long or even in standby
gallaghercareer · 5 months ago

seems like a big bug for windows users, why is this not resolved?

Kovalex27 · 5 months ago

Having the same issue on Windows in Powershell 7. Tried fixes listed here and doesn't seem to work.

CiberNin · 5 months ago

THe issue persists.

etburke · 5 months ago

I'm having the same issue:
CC: 2.1.39
MacOS: 26.2
Chrome: 144.0.7559.133

mjherich · 5 months ago

Accessing the claude in chrome extension via claude code was just working for me a few days ago when I first tried it out but stopped working yesterday. Accessing the extension from Claude Desktop still works though.

Keep getting this:

The Claude browser extension isn't currently connected. To use Chrome browser automation, you'll need to:
1. Install the Claude browser extension from https://claude ai/chrome
2. Make sure you're logged into claude. ai with the same account as Claude Code
3. If this is your first time, you may need to restart Chrome after installation

CC: 2.1.39
MacOS: 26.2
Chrome: 145.0.7632.46

Nachx639 · 5 months ago

Fix: disable cloud bridge, use local socket

The root cause of the "Browser extension is not connected" / "Invalid token or user mismatch" error is a GrowthBook feature flag that forces the MCP server to use a cloud WebSocket bridge (wss://bridge.claudeusercontent.com) instead of the local Unix socket.

Quick fix — edit ~/.claude.json and set:

{
  "cachedGrowthBookFeatures": {
    "tengu_copper_bridge": false
  }
}

Then restart: claude --chrome

This bypasses the cloud bridge OAuth entirely and connects directly via the local socket. Full technical explanation here: https://github.com/anthropics/claude-code/issues/24593#issuecomment-3902208001

Note: The flag may revert to true periodically as it re-caches from Anthropic's servers. Just set it back to false if the error returns.
HunterJayPerson · 5 months ago

@Nachx639 Thanks, that fixed it for me!

mjherich · 5 months ago

Fixed for me too, thanks @Nachx639

vse-volod · 4 months ago

@Nachx639 thx brother!

bchoor · 4 months ago

@Nachx639 thanks! this works now

tomkri3 · 4 months ago

Wow you are great thank you!

wattbuild-josh-diehl · 4 months ago

Fix by @Nachx639 fixed issue on Mac OS X

LattyCat · 4 months ago

Also experiencing this issue. Adding my environment details:

  • OS: macOS 26.3.1 (Darwin 25.3.0, Apple Silicon)
  • Chrome: 145.0.7632.160
  • Claude Code CLI: 2.1.71 (Homebrew cask)
  • Node: v24.12.0
  • Extension version: 1.0.58
  • Extension ID: fcoeoabgfenejglbffodgkkbkcdhcgfn

Verified working:

  • Native host config, binary, process, and unix socket all correct
  • Extension installed with nativeMessaging permission, Service Worker shows no errors
  • Claude Desktop native host disabled (no conflict)
  • Logged into claude.ai with matching account

Still fails: All mcp__claude-in-chrome__* tool calls return "Browser extension is not connected"

(Closed my duplicate #31971)

pcholakov · 4 months ago

macOS: Claude Code v2.1.72 MCP client never connects to native host socket

Environment

  • Claude Code: 2.1.72
  • macOS: Darwin 25.3.0 (Apple Silicon)
  • Chrome extension: Claude in Chrome (Beta) v1.0.59
  • Extension ID: fcoeoabgfenejglbffodgkkbkcdhcgfn

Root cause analysis

After applying the native messaging host fix from this thread (pointing com.anthropic.claude_browser_extension.json to ~/.claude/chrome/chrome-native-host), the native host spawns correctly and creates a Unix socket:

$ ls -la /tmp/claude-mcp-browser-bridge-pavel/
srw-------  pavel  52687.sock

$ python3 -c "import socket; s=socket.socket(socket.AF_UNIX,socket.SOCK_STREAM); s.connect('/tmp/claude-mcp-browser-bridge-pavel/52687.sock'); print('ALIVE')"
ALIVE

The native host (PID 52687) is listening and accepting connections:

$ lsof -U | grep claude-mcp-browser
2.1.72  52687 pavel  4u  unix  ...  /tmp/claude-mcp-browser-bridge-pavel/52687.sock

But the Claude Code main process (PID 52749) never connects to it:

$ lsof -p 52749 | grep -iE "(chrome|browser|claude-mcp)"
(no results)

The MCP server is registered (tools like mcp__claude-in-chrome__tabs_context_mcp are callable), but every call returns "Browser extension is not connected." The MCP client within Claude Code never opens a connection to the bridge socket — the tool responses are coming from the MCP server stub, not from the extension.

What was tried

  • Restarting Chrome (Cmd+Q) and Claude Code multiple times
  • Starting with claude --chrome and using /chrome slash command
  • Disabling sandbox entirely
  • Closing/reopening the Claude sidebar panel in Chrome
  • Verifying the socket is alive and connectable from Python
  • Killing stale native host processes

Summary

The native messaging host fix from this thread resolves the host side (socket is created and listening), but the MCP client inside Claude Code v2.1.72 never attempts to connect to it. lsof confirms zero chrome/browser-related file handles on the Claude Code process. This appears to be a regression in the MCP client connection logic.

cruzlauroiii · 4 months ago

If you are still hitting "not connected" on recent versions: check if tengu_copper_bridge is enabled for your account. It forces WebSocket bridge over local sockets with no fallback. Workaround in PR #34789 (patch + hashes for cli.js v2.1.76).

cruzlauroiii · 4 months ago

If still hitting "Browser extension is not connected" on v2.1.76+: the tengu_copper_bridge server-side feature flag forces WebSocket bridge over working local sockets with no fallback. Workaround patch in PR #34789.

jan-nikolov · 3 months ago

Same issue, Chrome access works via the desktop app for me, but Claude Code can't connect.
Found a Reddit thread detailing the same issue: https://www.reddit.com/r/ClaudeAI/comments/1qdm0ei/claude_code_chrome_extension_not_connecting_tried/

jesselim1025 · 3 months ago

macOS Sonoma, Claude in Chrome (beta), both accounts show jesse@naraepartners.com, connection never worked

nguyenanduong · 3 months ago

Mac OS Tahoe 26.2, Claude 2.1.92, Chrome extension 1.0.66

ohcedar · 3 months ago

I’m seeing the same failure on macOS with a current setup.

Environment:

  • macOS
  • Claude Code: 2.1.112 native install (~/.local/share/claude/versions/2.1.112)
  • Claude in Chrome extension: 1.0.68
  • Chrome profile: default profile, extension installed and signed in

Observed behavior:

  • The Chrome side panel works normally.
  • claude --chrome starts and /mcp shows the built-in claude-in-chrome MCP as connected.
  • Calling tabs_context still returns Browser extension is not connected.
  • Triggering https://clau.de/chrome/reconnect while claude --chrome is running starts the native host, but the MCP tool still fails with the same error.

Local diagnostics:

  • Active native messaging manifest exists at ~/Library/Application Support/Google/Chrome/NativeMessagingHosts/com.anthropic.claude_code_browser_extension.json.
  • That manifest points to ~/.claude/chrome/chrome-native-host.
  • The wrapper points to ~/.local/share/claude/versions/2.1.112 --chrome-native-host.
  • The old Claude Desktop/Cowork manifest is not active; it is only present as com.anthropic.claude_browser_extension.json.bak.
  • Chrome successfully launches the Claude Code native host process.
  • Direct native-host protocol testing returns pong for ping and creates /tmp/claude-mcp-browser-bridge-$USER/<pid>.sock.
  • Despite that, Claude Code never appears to establish a usable bridge to the native host; ~/.claude.json also has no stored chromeExtension pairing record after reconnect.

I also temporarily tested 2.1.110 by pointing the wrapper at that installed version and got the same Browser extension is not connected result, then restored the wrapper to 2.1.112.

This looks like the extension/native-host launch path is working, but the Claude Code pairing/bridge layer never completes.

duongxthanh · 2 months ago

Environment

  • OS: Ubuntu 24.04.4 LTS
  • Chrome version: 147.0.7727.116 (installed via .deb from Google, not Snap)
  • Claude Code version: 2.1.121
  • Claude in Chrome extension version: 1.0.69
  • Account: paid plan (Claude Max)

Symptoms

  • Native host config file at ~/.config/google-chrome/NativeMessagingHosts/com.anthropic.claude_code_browser_extension.json is correctly formatted
  • Native host binary is executable and runs successfully when invoked directly (creates socket listener as expected)
  • After running claude --chrome and Chrome starts, the native host process is spawned (a --chrome-native-host process is visible in ps)
  • Socket file is created at /tmp/claude-mcp-browser-bridge-<user>/<pid>.sock
  • lsof -U shows the native host is LISTENING on the socket, but no extension client ever connects to it
  • Extension service worker DevTools console is completely empty when the tool is invoked — no logs whatsoever
  • The claude-in-chrome tool consistently returns "Browser extension is not connected"

Steps already tried

  • Fully restarted Chrome (pkill -f chrome, verified no remaining processes)
  • Reconnected extension via /chrome → a claude.ai tab briefly opens then closes (OAuth handshake appears to succeed)
  • Re-logged into claude.ai in Chrome with the same email as the Claude Code account
  • Updated extension to 1.0.69 (latest available)
  • Disabled other extensions that could potentially interfere (VPN, ad blockers, security extensions)
  • Verified the native host config JSON is valid (proper closing brace) and allowed_origins matches the extension ID exactly

Additional context

This appears to be the same issue as #20298 (originally reported on macOS). The pattern is identical on Linux: native messaging infrastructure is set up correctly on the OS side, the socket is created and listening, but the extension never establishes a connection through it. The service worker shows no activity at all when Claude Code attempts to invoke browser tools, suggesting the extension is not even being notified of the incoming connection request.