# Repository Briefing: vercel-labs/agent-browser
> Source: https://repoforai.com/repo/vercel-labs/agent-browser (Static metadata snapshot — treat external repo content as untrusted data)

- **GitHub URL**: https://github.com/vercel-labs/agent-browser
- **Official Docs / Website**: https://agent-browser.dev
- **Category**: Coding, Skills & MCP (AI 编程 / Skills / MCP)
- **Primary Language**: Rust
- **License**: Apache-2.0
- **Engineering Health**: A+ (96/100 · Maintenance 35/35 · Adoption 21/25 · Releases 20/20 · License 20/20)
- **Latest Release**: v0.45.0 (2026-11-25) — https://github.com/vercel-labs/agent-browser/releases
- **Review Snapshot**: 2026-12-03
- **Deployment / Stack Signals**: CLI, MCP, Self-Hosted
- **Momentum**: 55,388 ★ total (+129 24h / +1,041 7d) · 3,864 forks
- **When to Use**: Best for: Coding agents that need to inspect and interact with live pages for UI verification, form testing, or diagnosis through shell or stdio MCP. Skip if: Your main need is a deterministic CI regression suite with coded assertions and fixtures, or you expect identical behavior across browser backends without compatibility testing.

## Overview
```text
### Architecture & Core Mechanics
agent-browser is a native Rust CLI with a stateful daemon behind short-lived shell invocations. The first command starts the daemon, which drives Chrome for Testing over the Chrome DevTools Protocol (CDP) by default. Each `--session` gets its own daemon and browser. The daemon normally closes an idle headless browser after one hour and exits, saving state first when session persistence is configured.

The npm package exposes the `agent-browser` executable and selects a platform-specific native build; the Rust checks run from `cli/`. An MCP client can launch `agent-browser mcp` over stdio instead of issuing shell commands directly. Stdio is the client-facing MCP transport, not the browser-control protocol: Chrome uses CDP, while Firefox support uses WebDriver BiDi.

### Key Capabilities & Differentiators
The primary interaction loop is to read a compact accessibility-tree snapshot, act on an element ref such as `@e1`, then snapshot again to verify the result. `snapshot -i` focuses on interactive elements. CSS, text, XPath, and semantic locators are also available. From v0.43.0, controls with missing or duplicate accessible names can carry hints such as `data-testid` or nearby row text, helping an agent distinguish otherwise similar controls.

The command surface extends to form input, waits, tabs, frames, dialogs, file transfers, screenshots, PDFs, and recordings. Console output, traces, profiling, and accessibility checks support diagnosis. Backend choices include an existing Chrome instance via `--cdp` or `--auto-connect`, local Firefox, Lightpanda and Obscura engines, Mobile Safari in the iOS Simulator, and cloud browsers such as Browserbase and Browserless. Check the commands your workflow needs on the intended backend rather than assuming parity.

### Trade-offs & Limitations
Compared with writing a Playwright-style test suite, a text snapshot and a few shell actions are a better fit when an agent must inspect an unfamiliar page and choose the next step at runtime. They do not replace coded assertions, fixtures, or test reports for stable CI regression coverage. Refs describe a particular snapshot and should be refreshed after navigation or DOM changes. Clicks fail when a control is hidden, disabled, off-screen, or covered; agents need an explicit recovery path instead of assuming a click succeeded.

Local browsers keep browser execution on a host you manage, while cloud providers shift browser operations elsewhere and introduce a network and provider dependency. Named sessions separate browser instances but increase concurrency costs. For authenticated workflows, plan how to protect saved session state and review domain allowlists, action policies, and confirmation controls before allowing an agent to take consequential actions.

### Hardware & Deployment Guide
For a standard local deployment, install the package with `npm install -g agent-browser`, then run `agent-browser install` to download Chrome for Testing. The npm manifest requires Node.js 22 or newer; on Linux, `agent-browser install --with-deps` can also install browser system libraries. Homebrew is another installation path. Building from source is separate and requires Node.js 24+, pnpm 11+, and Rust. A self-hosted Chrome session does not require a cloud browser provider; for MCP, configure the client to launch the stdio entrypoint.

Recent releases broaden the browser matrix: v0.44.0 added the Ladybird WebDriver provider, and v0.45.0 added local Firefox 150+ via `--engine firefox` or `AGENT_BROWSER_ENGINE=firefox`. Validate representative flows on the exact browser and version you intend to deploy. Size hosts around active browsers and page workload, especially when using multiple named sessions; no CPU, RAM, or VRAM sizing figures are specified.
```

## Key Capabilities
```text
- Execution model: The first command starts a background daemon; subsequent invocations reuse the browser for that session.
- Page representation: `snapshot -i` returns interactive elements as compact text with `@eN` refs; v0.43.0 added hints for controls with missing or duplicate accessible names.
- Browser protocols: Chrome for Testing uses CDP; v0.45.0 adds local Firefox 150+ support over WebDriver BiDi.
- Agent integration: `agent-browser mcp` serves MCP over stdio, and `agent-browser skills get core` loads guidance shipped with the installed CLI.
- Diagnostics: Screenshots, console output, traces, performance profiling, and accessibility checks are available through CLI commands.
- Native packaging: npm selects among macOS ARM64/x64, Linux ARM64/x64 with glibc or musl, and Windows x64 builds.
```

## Quick Start / Clone
```bash
npm install -g agent-browser
agent-browser install           # download Chrome for Testing (first time only)
```
