This file is for AI agents (Claude Code, Codex, Cursor, Windsurf, etc.) that need to install and use browser-agent-cli on behalf of a user.
git clone https://github.com/nolan-vale/browser-agent-cli.git
cd browser-agent-cli && bash install.sh
npm install -g chrome-devtools-mcpRequires: macOS, Google Chrome Beta at /Applications/Google Chrome Beta.app.
| Command | What it does |
|---|---|
chrome-beta-agent [url] |
Launch Chrome Beta with agent profile + CDP on port 9222. If already running, opens url in a new tab. |
chrome-beta-agent-stop |
Gracefully shut down the agent browser. |
chrome-devtools <cmd> |
Control the browser via CDP (separate package: chrome-devtools-mcp). |
# 1. Launch
chrome-beta-agent https://target.com
# 2. Snapshot page (get element UIDs)
chrome-devtools take_snapshot
# 3. Interact
chrome-devtools fill "uid=1_3" "input text"
chrome-devtools click "uid=1_5"
chrome-devtools navigate_page --url "https://target.com/next"
# 4. Observe
chrome-devtools take_screenshot
chrome-devtools list_console_messages --types error
chrome-devtools list_network_requests
# 5. Stop
chrome-beta-agent-stophttp://127.0.0.1:9222
Health check:
curl -s http://127.0.0.1:9222/json/version | python3 -m json.toolIf CDP is unhealthy but Chrome Beta is running:
chrome-beta-agent-stop
chrome-devtools stop 2>/dev/null || true
chrome-beta-agent https://target.com
chrome-devtools start --browserUrl http://127.0.0.1:9222| Variable | Default | Description |
|---|---|---|
CHROME_AGENT_PORT |
9222 |
CDP port |
CHROME_AGENT_PROFILE |
~/.chrome-beta-agent-research |
Agent browser profile |
Always ask the user before:
- Submitting any form
- Sending messages, emails, or notifications
- Changing account or profile settings
- Deleting or uploading data
- Accepting legal terms or billing actions
Always stop and ask the user to act manually when:
- Login, CAPTCHA, MFA, passkey, SMS or email verification is required
README.md— overview, install, usageAGENTS.md— this file, for AI agentsbin/chrome-beta-agent— launcher scriptbin/chrome-beta-agent-stop— stop scriptskills/SKILL.md— Claude Code / Codex skillllms.txt— machine-readable summary
- GitHub: https://github.com/nolan-vale/browser-agent-cli
- chrome-devtools CLI (control layer): https://www.npmjs.com/package/chrome-devtools-mcp
- Chrome DevTools Protocol reference: https://chromedevtools.github.io/devtools-protocol/