Bug: Claude in Chrome extension fails to connect due to CSP errors

Resolved 💬 4 comments Opened Jan 29, 2026 by gaabrielmartins Closed Mar 1, 2026

Bug: Claude in Chrome extension fails to connect due to CSP errors

Environment

  • OS: Windows 11
  • Browser: Microsoft Edge (Chromium-based)
  • Extension version: 1.0.41
  • Claude Code version: (run claude --version to get this)

Problem

The Claude in Chrome extension fails to connect to Claude Code CLI. The tabs_context_mcp tool always returns "Browser extension is not connected."

Errors in Extension

From edge://extensions/?errors=fcoeoabgfenejglbffodgkkbkcdhcgfn:

Executing inline script violates the following Content Security Policy directive 'script-src 'self''. Either the 'unsafe-inline' keyword, a hash ('sha256-kFwyFWA0myfqRcE5y2d5UX8g0o2QFHSmCz1gWSW0xpk='), or a nonce ('nonce-...') is required to enable inline execution. The action has been blocked.

Context: sidepanel.html

Error: A listener indicated an asynchronous response by returning true, but the message channel closed before a response was received

What was verified

  1. Native host manifest exists at correct path
  2. Registry entries exist for both Chrome and Edge
  3. Extension ID matches manifest (fcoeoabgfenejglbffodgkkbkcdhcgfn)
  4. Native host batch file exists and executes correctly
  5. claude.exe exists at the expected path
  6. Extension has "Communicate with native applications" permission
  7. Tried with both Chrome and Edge - same issue
  8. Reinstalled extension multiple times
  9. Ran claude --chrome and used "Reconnect extension"

Root Cause Analysis

The CSP errors indicate that inline scripts in sidepanel.html are being blocked, preventing the extension from initializing properly. This breaks the native messaging connection.

Expected Behavior

The extension should connect to Claude Code CLI and allow browser automation.

Actual Behavior

Connection always fails with "Browser extension is not connected."

View original on GitHub ↗

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