🎁 Get the FREE AI Skills Starter Guide β€” Subscribe β†’
BytesAgainBytesAgain
πŸ¦€ ClawHub

Chrome CDP for OpenClaw

by @joustonhuang

Browser automation CLI for AI agents using Google Chrome via CDP. Connects to a running Chrome instance started by chrome_for_openclaw.sh inside an XRDP sess...

βš™οΈ Configuration

Everything is handled by a single script: chrome_for_openclaw.sh.

Step 1 β€” One-time system setup (run once, requires sudo)

Installs Google Chrome if missing, then configures XRDP + XFCE. OpenClaw can run this step itself:

bash <(curl -fsSL https://raw.githubusercontent.com/joustonhuang/chrome_for_openclaw/main/chrome_for_openclaw.sh) --install

Other options:

# Reinstall everything from scratch
bash <(curl -fsSL https://raw.githubusercontent.com/joustonhuang/chrome_for_openclaw/main/chrome_for_openclaw.sh) --reinstall

Undo all changes made by --install

bash <(curl -fsSL https://raw.githubusercontent.com/joustonhuang/chrome_for_openclaw/main/chrome_for_openclaw.sh) --uninstall

After --install completes, log out and reconnect via RDP to get a fresh XFCE session.

Step 2 β€” Start Chrome (run when Chrome is not already running)

Launch Chrome in CDP debug mode. Only needed if Chrome is not already open. OpenClaw can run this step itself:

bash <(curl -fsSL https://raw.githubusercontent.com/joustonhuang/chrome_for_openclaw/main/chrome_for_openclaw.sh)

Optional environment variable overrides:

DEBUG_PORT=9222 START_URL=https://gmail.com \
bash <(curl -fsSL https://raw.githubusercontent.com/joustonhuang/chrome_for_openclaw/main/chrome_for_openclaw.sh)

This kills any existing Chrome processes, starts Google Chrome with --remote-debugging-port=9222, and waits for the CDP endpoint to respond.

Step 3 β€” Install agent-browser

> WARNING: Do NOT install agent-browser by cloning or building from the GitHub repo > (https://github.com/vercel-labs/agent-browser). > Doing so is known to break XRDP on Debian/Ubuntu. > Install via npm only:

npm install -g agent-browser

Do NOT run agent-browser install β€” we connect to Chrome via CDP, no Chromium needed.


View on ClawHub
TERMINAL
clawhub install chrome-for-openclaw

πŸ§ͺ Use this skill with your agent

Most visitors already have an agent. Pick your environment, install or copy the workflow, then run the smoke-test prompt above.

πŸ” Can't find the right skill?

Search 60,000+ AI agent skills β€” free, no login needed.

Search Skills β†’