Agent browser

From itgoyo/hermes-skills · View interactive version

Agent browser is an AI agent skill from the GitHub repository itgoyo/hermes-skills. Browser automation CLI for AI agents using agent-browser (Vercel Labs). Fast native Rust CLI with accessibility-tree based element selection. Use when you need headless browser control from the terminal — navigate, click, fill forms, screenshot, batch commands, AI chat mode.

How to use this skill

Skill file

agent-browser

Browser automation CLI for AI agents by Vercel Labs.

Repo: https://github.com/vercel-labs/agent-browser

Installation

npm (recommended, already installed globally)

npm install -g agent-browser
agent-browser install   # download Chrome for Testing (first time only)

Homebrew (macOS)

brew install agent-browser
agent-browser install

Cargo (Rust)

cargo install agent-browser
agent-browser install

Update

agent-browser upgrade

Chrome is stored at: ~/.agent-browser/browsers/chrome-<version>/

Quick Start

agent-browser open example.com
agent-browser snapshot          # accessibility tree with @eN refs
agent-browser click @e2         # click element by ref
agent-browser fill @e3 "text"   # clear + fill input by ref
agent-browser screenshot page.png
agent-browser close

Core Commands

agent-browser open <url>              # navigate (aliases: goto, navigate)
agent-browser snapshot                # accessibility tree with refs (best for AI)
agent-browser snapshot -i             # interactive snapshot (live)
agent-browser click <sel>             # click element
agent-browser fill <sel> <text>       # clear and fill
agent-browser type <sel> <text>       # type into element
agent-browser press <key>             # press key (Enter, Tab, Control+a)
agent-browser scroll <dir> [px]       # scroll up/down/left/right
agent-browser screenshot [path]       # screenshot (--full for full page)
agent-browser screenshot --annotate   # annotated with numbered labels
agent-browser eval <js>               # run JavaScript
agent-browser wait <selector>         # wait for element
agent-browser wait --text "text"      # wait for text
agent-browser wait <ms>               # wait milliseconds
agent-browser close                   # close browser

Get Info

agent-browser get text <sel>
agent-browser get html <sel>
agent-browser get value <sel>
agent-browser get title
agent-browser get url

Semantic Locators (find)

agent-browser find role button click --name "Submit"
agent-browser find text "Sign In" click
agent-browser find label "Email" fill "test@test.com"
agent-browser find nth 2 "a" text

Batch Execution

# argument mode
agent-browser batch "open https://example.com" "snapshot -i" "screenshot"

# stdin JSON mode
echo '[["open","https://example.com"],["snapshot"],["screenshot","out.png"]]' | agent-browser batch --json

AI Chat Mode

agent-browser chat "Go to example.com and take a screenshot"  # single-shot
agent-browser chat                                              # interactive REPL

Notes & Pitfalls

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.