coderClaw

Chrome extension (browser relay)

The CoderClaw Chrome extension lets the agent control your existing Chrome tabs (your normal Chrome window) instead of launching a separate coderclaw-managed Chrome profile.

Attach/detach happens via a single Chrome toolbar button.

What it is (concept)

There are three parts:

CoderClaw then controls the attached tab through the normal browser tool surface (selecting the right profile).

Install / load (unpacked)

  1. Install the extension to a stable local path:
coderclaw browser extension install
  1. Print the installed extension directory path:
coderclaw browser extension path
  1. Chrome → chrome://extensions
  1. Pin the extension.

Updates (no build step)

The extension ships inside the CoderClaw release (npm package) as static files. There is no separate “build” step.

After upgrading CoderClaw:

Use it (no extra config)

CoderClaw ships with a built-in browser profile named chrome that targets the extension relay on the default port.

Use it:

If you want a different name or a different relay port, create your own profile:

coderclaw browser create-profile \
  --name my-chrome \
  --driver extension \
  --cdp-url http://127.0.0.1:18792 \
  --color "#00AA00"

Attach / detach (toolbar button)

Which tab does it control?

Badge + common errors

If you see !:

Remote Gateway (use a node host)

Local Gateway (same machine as Chrome) — usually no extra steps

If the Gateway runs on the same machine as Chrome, it starts the browser control service on loopback and auto-starts the relay server. The extension talks to the local relay; the CLI/tool calls go to the Gateway.

Remote Gateway (Gateway runs elsewhere) — run a node host

If your Gateway runs on another machine, start a node host on the machine that runs Chrome. The Gateway will proxy browser actions to that node; the extension + relay stay local to the browser machine.

If multiple nodes are connected, pin one with gateway.nodes.browser.node or set gateway.nodes.browser.mode.

Sandboxing (tool containers)

If your agent session is sandboxed (agents.defaults.sandbox.mode != "off"), the browser tool can be restricted:

Options:

{
  agents: {
    defaults: {
      sandbox: {
        browser: {
          allowHostControl: true,
        },
      },
    },
  },
}

Then ensure the tool isn’t denied by tool policy, and (if needed) call browser with target="host".

Debugging: coderclaw sandbox explain

Remote access tips

How “extension path” works

coderclaw browser extension path prints the installed on-disk directory containing the extension files.

The CLI intentionally does not print a node_modules path. Always run coderclaw browser extension install first to copy the extension to a stable location under your CoderClaw state directory.

If you move or delete that install directory, Chrome will mark the extension as broken until you reload it from a valid path.

Security implications (read this)

This is powerful and risky. Treat it like giving the model “hands on your browser”.

Recommendations:

Related: