claude-code - 💡(How to fix) Fix Claude in Chrome: 'Invalid token or user mismatch' on Desktop app bridge connection [2 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#45472Fetched 2026-04-09 08:04:38
View on GitHub
Comments
2
Participants
2
Timeline
7
Reactions
0
Timeline (top)
labeled ×5commented ×2

Error Message

[Claude in Chrome] Connecting to bridge: wss://bridge.claudeusercontent.com/chrome/{userId}
[Claude in Chrome] WebSocket connected, sending connect message
[Claude in Chrome] Bridge error: Invalid token or user mismatch
[Claude in Chrome] Bridge connection closed (code: 1008, duration: 0ms)

This repeats on every retry attempt. The OAuth token scope is user:inference user:office.

Root Cause

Related issues

  • #38068 — OAuth scope mismatch
  • #34990 — Business domain triggers org scope restrictions
  • #32011 — Two root causes for bridge auth failure
  • #27055 — Server-side stale state

Code Example

[Claude in Chrome] Connecting to bridge: wss://bridge.claudeusercontent.com/chrome/{userId}
[Claude in Chrome] WebSocket connected, sending connect message
[Claude in Chrome] Bridge error: Invalid token or user mismatch
[Claude in Chrome] Bridge connection closed (code: 1008, duration: 0ms)
RAW_BUFFERClick to expand / collapse

Environment

  • Claude Desktop app v1.1062.0 (macOS, Darwin 25.4.0)
  • Claude Code v2.1.92 (subprocess within Desktop app)
  • Chrome extension ID: fcoeoabgfenejglbffodgkkbkcdhcgfn
  • macOS, personal workspace account

Problem

Claude in Chrome extension cannot connect from the Desktop app. The bridge repeatedly fails with "Invalid token or user mismatch" (WebSocket close code 1008).

What works

  • chromeExtensionEnabled: true is set in claude_desktop_config.json — bridge initializes
  • Native host binary runs correctly, socket created at /tmp/claude-mcp-browser-bridge-cyberjack/{pid}.sock
  • Socket is connectable (verified with node net.createConnection)
  • OAuth token is fresh (cache cleared, re-signed in to both Desktop and Chrome extension)
  • Chrome extension is installed, enabled, and signed in

Logs

[Claude in Chrome] Connecting to bridge: wss://bridge.claudeusercontent.com/chrome/{userId}
[Claude in Chrome] WebSocket connected, sending connect message
[Claude in Chrome] Bridge error: Invalid token or user mismatch
[Claude in Chrome] Bridge connection closed (code: 1008, duration: 0ms)

This repeats on every retry attempt. The OAuth token scope is user:inference user:office.

What was tried

  1. Cleared OAuth token cache in config.json — fresh token obtained, same error
  2. Signed out and back in to Claude.app — same error
  3. Signed out and back in to Chrome extension — same error
  4. Set tengu_copper_bridge: false in .claude.json — overwritten back to true on startup by GrowthBook
  5. Restarted Chrome, Claude.app, and toggled extension multiple times
  6. Verified native host config points to correct binary

Likely cause

Based on GitHub issues #38068, #34990, and #32011 — the bridge server may require user:sessions:claude_code scope which is not included in the Desktop app's OAuth token request (only user:inference user:office). This may be related to org-level scope restrictions.

Related issues

  • #38068 — OAuth scope mismatch
  • #34990 — Business domain triggers org scope restrictions
  • #32011 — Two root causes for bridge auth failure
  • #27055 — Server-side stale state

extent analysis

TL;DR

The most likely fix is to update the OAuth token scope in the Desktop app to include user:sessions:claude_code to match the required scope for the bridge server.

Guidance

  • Verify that the user:sessions:claude_code scope is not already included in the Desktop app's OAuth token request by checking the token's scopes in the config.json file.
  • Update the OAuth token request in the Desktop app to include the user:sessions:claude_code scope, if possible, to ensure compatibility with the bridge server's requirements.
  • Check the related GitHub issues (#38068, #34990, #32011) for more information on OAuth scope mismatches and org-level scope restrictions that may be contributing to the issue.
  • Consider testing the connection with a different user or account to determine if the issue is specific to the current user or account.

Example

No code snippet is provided as the issue does not explicitly mention a specific code change.

Notes

The fix may require updates to the Desktop app's configuration or code to include the required OAuth scope. Additionally, org-level scope restrictions may need to be adjusted to allow the user:sessions:claude_code scope.

Recommendation

Apply workaround: Update the OAuth token scope in the Desktop app to include user:sessions:claude_code, as this is the most likely cause of the issue based on the provided information and related GitHub issues.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING