claude-code icon indicating copy to clipboard operation
claude-code copied to clipboard

Remote Control: no way to enable Claude in Chrome for spawned sessions

Open ykdojo opened this issue 4 months ago • 8 comments

Claude Code 2.1.201 (CLI, macOS), extension installed and working in terminal sessions.

Sessions spawned from the Claude app / claude.ai/code via claude remote-control never get the claude-in-chrome tools:

  • The "Enabled by default" setting from /chrome isn't inherited, even by a server started after it was set.
  • claude remote-control --chrome fails with Error: Unknown argument: --chrome.

Request: accept --chrome on claude remote-control, or have spawned sessions inherit the "Enabled by default" setting.

ykdojo avatar Jul 06 '26 04:07 ykdojo

+1, hit this on Windows 11 (CC 2.1.212, Brave). Adding diagnostics that may help scope it:

  • RC-spawned sessions never receive the mcp__claude-in-chrome__* tools — verified with a clean test: RC server restarted with the browser open and the extension connected (a desktop session's list_connected_browsers confirmed the connection), fresh RC session spawned 2 minutes later, ToolSearch returned zero claude-in-chrome tools.
  • claude --chrome exists on the interactive CLI, but claude rc --help exposes no chrome flag, and claudeInChromeDefaultEnabled: true does not apply to RC spawns.
  • Headless children DO get the bridge: claude -p "<task>" --chrome successfully drives the logged-in browser — but the first browser action hits the "Claude in Chrome requires permission." gate, which cannot be satisfied non-interactively (--allowedTools "mcp__claude-in-chrome", settings allow rules, and --permission-mode bypassPermissions all fail to clear it). Only a PermissionRequest/PreToolUse hook returning permissionDecision: "allow" clears it headlessly.

Workaround we use: RC sessions shell out to a wrapper that runs claude -p --chrome with a settings file containing that hook. Works, but native support (a --chrome passthrough on claude rc, or an allow-rule surface for the chrome permission gate) would be much better.

🤖 Generated with Claude Code

treklight avatar Jul 20 '26 05:07 treklight

+1, independently reproduced on Windows 11 Pro (10.0.26200), Claude Code 2.1.225 (CLI, not desktop).

While trying to reproduce #74931 (the account-level "active worker" eviction) in plain CLI sessions rather than the desktop app, I ran into this gate as a separate blocker. Method: launched a fully independent claude -p ... --chrome process (its own PID/session ID, not a subagent of an existing session) to act as a genuinely new headless session — twice, once from a scratch directory and once from the target project directory with --permission-mode auto to match an already-frictionless interactive session running in that same directory.

Both times:

  • list_connected_browsers (read-only) succeeded immediately, no prompt.
  • The first state-mutating call, tabs_context_mcp, was hard-blocked: "Claude in Chrome requires permission." / decision_reason_type: "other".
  • Neither --allowedTools naming the exact tool, nor --permission-mode auto, cleared it — consistent with @treklight's report above that --allowedTools, settings allow rules, and --permission-mode bypassPermissions all fail to clear this specific gate.

So the second (never-before-connected) session never touched the bridge at all in my test — which also means it's a distinct mechanism from #74931, not a duplicate: #74931 is about an already-connected interactive session getting evicted by a newer one; this is a hard consent wall that stops a fresh headless session from ever connecting in the first place. Both need fixing before scheduled/unattended browser automation is reliable.

🤖 Generated with Claude Code

mickey-mikey avatar Aug 08 '26 04:08 mickey-mikey

+1, still reproducible on Windows 11 Pro (10.0.26220), Claude Code 2.1.263, Chrome 152, Claude Desktop with Remote Control on. Extension installed and working in plain terminal sessions.

Concrete case today (2026-09-06): from a Remote Control session I asked Claude to post a feature request to a Discourse forum I am already logged into in Chrome. The session had zero mcp__claude-in-chrome__* tools in its registry, so it could not drive the logged-in tab. Every fallback is closed too:

  • Chrome 136+ ignores --remote-debugging-port on the default profile, so puppeteer cannot attach to the real logged-in browser.
  • Importing the browser's cookies into a fresh automation profile is (correctly) refused by the auto-mode permission classifier.

Net effect: "post this on my behalf to a site I am logged into" is impossible from any spawned session, even though the same request works in a claude --chrome terminal. Request stands as filed: accept --chrome on claude remote-control, or let spawned sessions inherit the /chrome "Enabled by default" setting.

xxparrotxx avatar Sep 06 '26 22:09 xxparrotxx

+1, reproduced on macOS 27.0 (Apple silicon), Claude Code 2.1.270 (claude remote-control server under a LaunchAgent), desktop app 2.2553.1.

The gap is wider than Chrome. A session started from the Claude iOS app against the remote-control server is missing everything the desktop app supplies:

  • no mcp__claude-in-chrome__* tools
  • no computer-use tools
  • no built-in browser pane tools
  • no desktop session-management tools
  • the phone can't set the model either: the spawned session always takes the model default from ~/.claude/settings.json, whatever the mobile picker shows

A session started in the desktop app on the same Mac, with the same user settings and the same cwd ($HOME), has all of these. If Remote Control is then switched on for that session, it keeps them when driven from the phone. So the missing tools depend on which process started the session, not on the Mac or the config.

Things that didn't help:

  • claude --chrome --remote-control <name> in a pty (screen -dmS): the session registers and can be picked from the phone, but turns driven from the phone run as entrypoint: sdk-cli with no Chrome tools.
  • CLAUDE_CODE_ENABLE_CFC=true in the server's environment (confirmed via ps eww): no change for turns driven from the phone, although it does enable Chrome for a plain claude -p.
  • claudeInChromeDefaultEnabled: true: not applied.

Workaround in use: the session driven from the phone shells out to claude -p --chrome --permission-mode auto "<task>". It works against the logged-in Chrome, but every browser step starts a fresh context.

For comparison, Codex's remote sessions on the same Mac have the same tools as its local ones, so from the user's side this reads as Claude Code's remote sessions being second-class.

Request (as above): a --chrome passthrough on claude remote-control, or spawned sessions inheriting the same tool set a desktop-app session gets.

campbellsmurphy avatar Sep 19 '26 12:09 campbellsmurphy

I ended up building this with Claude Code as a workaround for this issue and #74667.

ykdojo avatar Sep 25 '26 03:09 ykdojo

+1, same issue, plus a related Remote Control failure.

Setup

  • claude.ai Projects (cloud threads), macOS, Chrome with the official Claude in Chrome extension
  • Claude in Chrome works fine in a regular claude.ai chat (tested 2026-10-31)

Problem 1: Chrome tools unavailable in Project threads

  • Threads in a Project have no access to Claude in Chrome tools.
  • Use case: reading webmail in my logged-in local browser from a Project thread.
  • Workaround today: run the prompt in a regular chat and paste the output back into the thread.

Problem 2: Remote Control to my Mac fails to start

  • Starting a thread with Remote Control on my Mac (approved on the device) fails with:

    could not start Claude Code in that folder

  • Reproduced repeatedly on 2026-10-30 (17:05–18:26 CET) and 2026-10-31 (06:35 CET).
  • Folder access to the same Mac works.

Request

  • Native Claude in Chrome support for Project threads, or for Remote Control sessions started from a Project, with the same permission prompts and site permissions as the extension.
  • I'd rather not install third-party bridges with debugger access on a work browser.

DGAIstudios avatar Oct 31 '26 05:10 DGAIstudios

Same problem here, still happening.

Setup: Windows 11 Pro, Claude Code 2.1.306, desktop app with "remoteControlAtStartup" enabled (supervised remote-control server).

What happens: when I start or continue a session from the iOS app via Remote Control, that session has no Claude in Chrome tools and no computer-use tools. ToolSearch finds none of them. The same machine, with the same account and the same project, has both available when the session is started locally on the desktop. So the capability exists on the machine; it is just not loaded for sessions spawned through Remote Control.

Impact: I use Remote Control precisely when I am away from the computer. Any task that needs the browser (filling a form, a registration, reading a logged-in page) fails, and the session can only tell me to go to the computer, which defeats the purpose of Remote Control.

Requests:

  1. Load Claude in Chrome and computer use in Remote Control sessions when the host machine has them, or at least offer a setting or permission prompt to enable them.
  2. If that is intentionally blocked, say so clearly in the session and in the docs, so the agent and the user know the limit up front instead of finding out mid-task.

Related: #87340, #99609.

willaman99 avatar Nov 23 '26 13:11 willaman99

Same on Claude Code 2.1.332, macOS 26.7.2 arm64, with "Enabled by default" on (claudeInChromeDefaultEnabled: true).

Bridge-spawned sessions are started as claude --print --sdk-url ... --mcp-config=<bridge mcp.json>, and that mcp.json lists only claude-code-remote, so the claude-in-chrome tools never load. ToolSearch for them returns nothing.

Workaround: from inside the spawned session, claude --chrome -p "<task>" < /dev/null starts a local child that does get the tools and reaches the running Chrome (tabs_context_mcp answers). So the extension and native host are fine. Only the spawn leaves Chrome out.

tdsupersuit avatar Nov 27 '26 14:11 tdsupersuit