bunx @different-ai/opencode-browser@latest installchrome://extensions{
"$schema": "https://opencode.ai/config.json",
"plugin": ["@different-ai/opencode-browser"]
}
That’s it — your OpenCode session can now control existing Chrome/Brave/Arc tabs.
Browser automation plugin for OpenCode.
Control your real Chromium browser (Chrome/Brave/Arc/Edge) using your existing profile (logins, cookies, bookmarks). No DevTools Protocol, no security prompts.
https://github.com/user-attachments/assets/1496b3b3-419b-436c-b412-8cda2fed83d6
This version is optimized for reliability and predictable multi-session behavior:
Help me improve this!
bunx @different-ai/opencode-browser@latest install
Supports macOS, Linux, and Windows (Chrome/Edge/Brave/Chromium).
https://github.com/user-attachments/assets/d5767362-fbf3-4023-858b-90f06d9f0b25
The installer will:
~/.opencode-browser/extension/chrome://extensionsopencode.json or opencode.jsonc to load the pluginTo override the extension ID, pass --extension-id <id> or set OPENCODE_BROWSER_EXTENSION_ID.
Note: if you run the installer you'll be prompted to include this automatically. If you said "yes", you can skip this part.
Your opencode.json or opencode.jsonc should contain:
{
"$schema": "https://opencode.ai/config.json",
"plugin": ["@different-ai/opencode-browser"]
}
bunx @different-ai/opencode-browser@latest update
Run plugin tools directly from the package CLI (without starting an OpenCode session):
# list available browser_* tools
npx @different-ai/opencode-browser tools
# run a single tool
npx @different-ai/opencode-browser tool browser_status
npx @different-ai/opencode-browser tool browser_query --args '{"mode":"page_text"}'
# run built-in end-to-end smoke test (click + text selector + container scroll)
npx @different-ai/opencode-browser self-test
This is useful for debugging issue reports (for example inbox/chat UIs) before involving a full OpenCode workflow.
After update, reload the unpacked extension in chrome://extensions before running self-test.
Build a store-ready extension package:
bun run build:cws
Outputs:
artifacts/chrome-web-store/opencode-browser-cws-v<version>.zipartifacts/chrome-web-store/manifest.chrome-web-store.jsonSubmission checklist and guidance:
CHROME_WEB_STORE.mdCHROME_WEB_STORE_REQUEST_TEMPLATE.mdPRIVACY.mdOpenCode Plugin <-> Local Broker (unix socket) <-> Native Host <-> Chrome Extension
This branch adds an alternate backend powered by agent-browser (Playwright). It runs headless and does not reuse your existing Chrome profile.
agent-browser and Chromium:npm install -g agent-browser
agent-browser install
export OPENCODE_BROWSER_BACKEND=agent
Optional overrides:
OPENCODE_BROWSER_AGENT_SESSION (custom session name)OPENCODE_BROWSER_AGENT_SOCKET (unix socket path)OPENCODE_BROWSER_AGENT_AUTOSTART=0 (disable auto-start)OPENCODE_BROWSER_AGENT_DAEMON (explicit daemon path)On the host (e.g., home-server.taild435d7.ts.net), run the TCP gateway:
OPENCODE_BROWSER_AGENT_GATEWAY_PORT=9833 node bin/agent-gateway.cjs
On the client:
export OPENCODE_BROWSER_BACKEND=agent
export OPENCODE_BROWSER_AGENT_HOST=home-server.taild435d7.ts.net
export OPENCODE_BROWSER_AGENT_PORT=9833
browser_open_tab always creates and claims a new tab for the session.OPENCODE_BROWSER_CLAIM_TTL_MS, default 5 minutes).browser_status or browser_list_claims for debugging.Core primitives:
browser_statusbrowser_get_tabsbrowser_list_claimsbrowser_claim_tabbrowser_release_tabbrowser_open_tabbrowser_close_tabbrowser_navigatebrowser_query (modes: text, value, list, exists, page_text; optional timeoutMs/pollMs)browser_click (optional timeoutMs/pollMs)browser_type (optional timeoutMs/pollMs)browser_select (optional timeoutMs/pollMs)browser_scroll (optional timeoutMs/pollMs)browser_waitDownloads:
browser_downloadbrowser_list_downloadsUploads:
browser_set_file_input (extension backend supports small files; use agent backend for larger uploads)Selector helpers (usable in selector):
label:Mailing Address: Cityaria:Principal Address: Cityplaceholder:Search, name:email, role:button, text:Submitcss:label:has(input) to force CSSSelector-based tools wait up to 2000ms by default; set timeoutMs: 0 to disable.
Diagnostics:
browser_snapshotbrowser_screenshotbrowser_versionbrowser_set_active_tab)browser_back, browser_forward, browser_reload)browser_key)browser_download, browser_list_downloads)browser_set_file_input)Extension says native host not available
npx @different-ai/opencode-browser install--extension-id <id>Tab ownership errors
tabId owned by another sessionbrowser_open_tab to create a tab for your session (or omit tabId to use your default)browser_status or browser_list_claims for debuggingnpx @different-ai/opencode-browser uninstall
Then remove the unpacked extension in chrome://extensions and remove the plugin from opencode.json or opencode.jsonc.
PRIVACY.mdopencli-browser
Make websites accessible for AI agents. Navigate, click, type, extract, wait — using Chrome with existing login sessions. No LLM API key needed.
by AgentHub Crawler
browser
Automate browser interactions using agent-browser CLI — navigate, click, fill forms, scrape content, take screenshots, and more.
by AgentHub Crawler
Opencode PTY
A plugin that provides interactive PTY (pseudo-terminal) management, enabling the AI agent to run background processes, send interactive input, and read output on demand.
by AgentHub Crawler
Sign in to leave a comment.
browser-use
Direct browser control via CDP for web interaction: automation, scraping, testing, screenshots, and site/app work.
by AgentHub Crawler