Opencode-chromeSAFE
A Chrome extension that gives OpenCode browser control, similar to Claude or Codex in Chrome.
Overview
From the repository's own README, as read at the audited commit. Badges and raw HTML are left out.
[](https://www.npmjs.com/package/opencode-chrome) [](https://github.com/G10hdz/opencode-chrome/actions/workflows/ci.yml) [](LICENSE)
opencode-chrome lets opencode use your real Chrome: the one already logged into Gmail, your dashboards, your staging site. Ask in the terminal, watch it happen in your browser. An unofficial, community-built bridge in the spirit of Claude in Chrome / Codex in Chrome.
Unofficial. Not affiliated with or endorsed by the opencode project. BYOK: your model keys stay in your opencode config. This bridge collects nothing and talks only to localhost.
What it looks like
you ▸ open github.com/notifications and tell me which repos have unread activity you ▸ click the extension icon to attach that tab opencode ▸ snapshot (reads the list as a text tree) → acme/api (2), acme/web (1), infra/deploy (5) you ▸ go to the staging checkout and screenshot it opencode ▸ navigate staging.example.com/checkout screenshot → returns the PNG
It works because it drives your browser session, so anything you can see while logged in, the agent can see too.
How it works
A tiny local bridge (npx opencode-chrome, an MCP server plus a WebSocket on 127.0.0.1:19223) and an MV3 extension that connects to it and drives only the tabs you attach from the toolbar, using the Chrome DevTools Protocol. An attachment is limited to the tab's current origin. No backend, no accounts, no analytics.
Requirements
- Node 18 or newer
- Google Chrome (or Chromium) 116 or newer
- opencode (or any MCP client that launches a local stdio server)
##
fe1e245287fcOBSERVED · 2026-10-09Connect
Built from this server's own package name, version and transport as found in its source — not copied from anyone's documentation, so it cannot drift against a page we do not control. Replace the environment placeholders with a token scoped to the least it needs.
claude mcp add opencode-chrome --env OPENCODE_CHROME_TOKEN=${OPENCODE_CHROME_TOKEN} -- npx -y [email protected]{
"mcpServers": {
"opencode-chrome": {
"command": "npx",
"args": [
"-y",
"[email protected]"
],
"env": {
"OPENCODE_CHROME_TOKEN": "${OPENCODE_CHROME_TOKEN}"
}
}
}
}Exposed tools (19)
16 read · 3 write · 0 destructive.
| Tool | Risk | Description |
|---|---|---|
activate_tab | read | Focus the tab with the given id. |
browser_status | read | Report bridge connection and attached tabs. |
click | read | Click the element captured with the given ref in the latest snapshot. |
close_tab | read | Close the tab with the given id. |
drag | read | Drag the element with ref |
fill | write | Set the value of an input, textarea or contenteditable in one shot. Uses the native property setter so React/Vue controlled fields keep it, then verifies by reading the value back. Prefer over type when no autocomplete is involved. |
get_network_body | read | Fetch the response body of a requestId seen in list_network. Text bodies over ~200KB are truncated; binary comes back base64Encoded. |
hover | write | Move the pointer over the element with the given ref (trusted mouseMoved over CDP). Useful for menus and tooltips. |
list_network | read | List recent network requests on the tab (ring buffer of ~100): method, url, status, type, size. Optional filter matches substring of url. |
list_tabs | read | List open tabs with id, title and url. |
navigate | read | Navigate to a URL in the tab and wait for the load to finish. |
new_tab | read | Open a new active tab, optionally at a URL. |
screenshot | read | Capture a PNG screenshot of the tab, returned as base64. |
scroll | read | Scroll the page. With ref, scrolls that element into view; with dx/dy, scrolls the window by that many pixels (default dy 600 down). Returns the new position and at_bottom. |
select | read | Pick an <option> on a <select> by label or value, then dispatch input/change. On failure the error lists the available options. |
snapshot | read | Accessibility tree of the page as text, with [ref] markers on interactive elements. |
type | read | Type text into the element with the given ref; a trailing newline sends Enter. |
upload | write | Set local file paths on a <input type=file> via DOM.setFileInputFiles. files are absolute paths on the machine running Chrome. |
wait_for | read | Poll the page innerText until the given text appears or timeout (ms) elapses. |
Trust audit
SAFEgrade B · trust 89/100 Nothing in the source contradicts what it says it does. Grade A is reserved for packages that have also passed the behavioural sandbox.
| Layer | What it checks | Result |
|---|---|---|
| L0 | Provenance & inventory | PASS |
| L1 | Static analysis of the code | PASS |
| L2 | Instruction surface (what it tells the agent) | PASS |
| L3 | Class-specific surface | PASS |
| L4 | Behavioural (sandbox) | SKIPPED |
What the source does
- Filesystem
- none-observed
- Network
- declared (5 observation(s))
- Shell
- declared (1 observation(s))
- Dependencies
- not all pinned
- Secrets in source
- none-found
Findings (1)
@modelcontextprotocol/sdk, ws, zod
Gates applied: no_behavioural_pass.
fe1e245287fcfull audit observations/trust-audit/mcp-server/g10hdz__opencode-chrome.json · Report an issue / request a re-scanAudit history
Every audit this server has had. A grade with a past is a grade somebody is still checking.
| Date | Source | Verdict | Grade | Score | Change |
|---|---|---|---|---|---|
| 2026-10-09 | fe1e245287fc | SAFE | B | 89 | first audit |
Questions
What is the Opencode-chrome MCP server?
A Chrome extension that gives OpenCode browser control, similar to Claude or Codex in Chrome.
What tools does Opencode-chrome expose?
19 in total: 16 read-only, 3 that write, and 0 that can delete or overwrite. Every one is listed on this page with its risk.
Is Opencode-chrome safe to connect to an agent?
The audit found nothing in the source that contradicts what it says it does, and graded it B (89/100). Grade A is held back for packages that have also passed a sandboxed behavioural run, which is why a clean server reads B.
What credentials does Opencode-chrome need?
It reads OPENCODE_CHROME_TOKEN from the environment. Give it a token scoped to the least it needs — an agent that can be talked into calling a tool can be talked into calling it with your credentials.
How does Opencode-chrome run?
It speaks stdio, so it runs as a local process your client starts. It is published on npm as opencode-chrome at 0.1.2.
How current is this page?
The grade is for one exact copy of the source (fe1e245287fc), read on 2026-10-09. The repository is watched and re-audited when it changes.