Skip to main content Switch to mobile version openbrowser-ai 0.1.63 Agentic browser automation using LangGraph and raw CDP
pip install openbrowser-ai==0.1.63 Copy PIP instructions
AI browser automation, powered by code.
Cloud dashboard for saved cookies and scheduled tasks is available in the hosted version. Join the waitlist for early access: https://openbrowser.me :
https://github.com/user-attachments/assets/b17f97f3-f9f8-4707-8e39-abbbbe1a693b
Automating Walmart Product Scraping:
OpenBrowserAI Automatic Flight Booking:
OpenBrowserAI Automatic Form Filling:
AI-powered browser automation using CodeAgent and CDP (Chrome DevTools Protocol)
OpenBrowser is a framework for intelligent browser automation. It combines direct CDP communication with a CodeAgent architecture, where the LLM writes Python code executed in a persistent namespace, to navigate, interact with, and extract information from web pages autonomously.
3. Installation 3.1. Quick install (macOS / Linux)
3.2. Quick install (Windows PowerShell)
3.3. Homebrew (macOS / Linux)
3.5. uv (recommended)
3.6. uvx (zero install)
3.9. Optional Dependencies
4. Quick Start 4.1. Basic Usage
4.2. With Different LLM Providers
4.3. Using Browser Session Directly
5. Configuration 5.1. Config file lifecycle
5.2. Environment Variables
5.3. BrowserProfile Options
6. Supported LLM Providers
7. Claude Code Plugin
9. Codex 9.1. Quick Install
10. OpenCode 10.1. Quick Install
10.2. Manual Install
12. MCP Server 12.1. Quick Setup
13. Benchmark: Native Local Lanes 13.1. Native Local Benchmarks
13.2. What the measured paths do
15. Project Structure
16. Testing 16.1. Benchmarks
17. Backend and Frontend Deployment 17.1. Prerequisites
17.2. Local Development (Docker Compose)
17.3. Full Stack (Docker Compose)
17.6. Environment Variables
18. Research: Reinforcement Fine-Tuning for Browser Agents 18.1. Study 1: Browser-in-the-Loop (Autoregressive RL)
18.2. Study 2: Diffusion Language Models for Web Action Planning
18.3. Reproducing RL Experiments
Full documentation: https://docs.openbrowser.me
CodeAgent Architecture - LLM writes Python code in a persistent Jupyter-like namespace for browser automation
Raw CDP Communication - Direct Chrome DevTools Protocol for maximum control and speed
Native Web Search - The package-native DDGS client in Python, the CLI, CodeAgent, and MCP. Search snippets are discovery previews.
Vision Support - Screenshot analysis for visual understanding of pages
15 LLM Providers - OpenAI, Anthropic, Google, Groq, AWS Bedrock, Azure, Ollama, DeepSeek, Cerebras, OpenRouter, OCI, and more
MCP Server - Model Context Protocol for Claude Desktop, Claude Code, Codex, OpenCode, and other AI assistants. Modern clients use explicit contexts and isolated profiles. The server includes read-only status and reset tools.
CLI Daemon - Persistent browser daemon with -c flag for direct code execution from Bash, explicit startup ownership, health and recovery status, saved login state, and 10-minute auto-shutdown
CLI frontends - OpenBrowser 0.1.63 platform wheels send eligible warm -c calls through a native client. The native frontend also handles daemon stop, daemon force-stop, daemon reset, and -c CODE --reset-before. The Python backend owns startup and the remaining CLI commands. See the CLI frontend reference. scrape --no-browser uses OpenBrowser no-browser mode: a light console entry that starts no Chrome, Blink, or V8 process and does not import the browser or configuration stack
Batch scraping - scrape_pages and the CLI batch scrape multiple URLs with bounded concurrency. An explicit --no-browser or --engine http batch starts no browser
Explicit Lifecycle State - Browser, CDP, navigation, focus, storage, downloads, agent runs, and CodeAgent runs report typed phases that replace log inspection
Workflow Recording - Record, replay, and export browser sessions to Jupyter notebooks or API crawler code
Video Recording - Record browser sessions as video files with ffmpeg
Cloud Platform - Full-stack web UI with real-time VNC streaming, saved logins (KMS-encrypted), scheduled workflows (EventBridge + SQS), and email notifications (SES)
Plugin System - Claude Code plugin and skills.sh pack with 8 guided skills (setup, deep research, web scraping, form filling, e2e testing, page analysis, accessibility audit, file download)
3.1. Quick install (macOS / Linux)
curl -fsSL https://raw.githubusercontent.com/billy-enrizky/openbrowser-ai/main/install.sh | sh 3.2. Quick install (Windows PowerShell)
irm https://raw.githubusercontent.com/billy-enrizky/openbrowser-ai/main/install.ps1 | iex The installers require Python 3.12 or newer. They use uv, then pipx, then pip.
To request a pip user install with --local, run:
brew tap billy-enrizky/openbrowser brew install openbrowser-ai 3.4. pip
pip install openbrowser-ai 3.5. uv (recommended)
uv tool install openbrowser-ai 3.6. uvx (zero install)
Run without installing the CLI. uvx downloads and caches the package.
OpenBrowser 0.1.63 provides the canonical web-search command. The examples below run the published package with uvx.
# MCP server mode uvx openbrowser-ai --mcp # CLI daemon mode uvx openbrowser-ai -c "await navigate('https://example.com')" # Native web search. This command does not start Chromium. uvx openbrowser-ai web-search "OpenBrowser MCP docs" uvx openbrowser-ai web-search "OpenBrowser MCP docs" --json --output web-search-results.json uvx openbrowser-ai web-search "OpenBrowser MCP docs" --urls-only --output web-search-urls.txt uvx openbrowser-ai scrape --urls-file web-search-urls.txt --no-browser --output scraped-pages.jsonl --output-format jsonl # OpenBrowser no-browser mode: no Chrome, Blink, or V8 process uvx openbrowser-ai scrape https://example.com --no-browser --format markdown uvx openbrowser-ai scrape https://example.com --format json --selector "article" uvx openbrowser-ai scrape https://example.com --render-mode no-render # One-shot task with lightweight rendering uvx openbrowser-ai --render-mode lightweight -p "Read the page title" # One-shot task without screenshots or visual-only actions uvx openbrowser-ai --no-render -p "Read the page title" # Batch scrape with bounded HTTP concurrency uvx openbrowser-ai scrape https://a.example https://b.example --jsonl --concurrency 8 uvx openbrowser-ai scrape --urls-file urls.txt --output results.jsonl scrape accepts multiple URLs or a file with one URL per line. Use --output-format json or --output-format jsonl to select batch output. A .jsonl output path selects JSONL by default. Each result records its URL, success state, engine, content or error, duration, and timing. One failed URL does not stop the batch.
--no-browser is OpenBrowser no-browser mode. It starts no Chrome, Blink, or V8 process and stays on the HTTP path. JavaScript, screenshots, and browser cookies are unavailable on this path. The asset flags --no-css, --no-images, --no-fonts, --no-media, and --render-mode control the browser fallback and leave the no-browser HTTP path unchanged. Use the default auto engine or --engine browser when a page needs JavaScript.
In CodeAgent and MCP execution, call await scrape_pages(urls, concurrency=4). HTTP requests run concurrently up to the limit. Browser fallbacks run sequentially, and each URL returns its own result.
openbrowser-ai web-search prints a compact table by default. Use --json for a JSON array or --urls-only to write one URL per line. Search snippets are discovery previews. Scrape and read each source page before you cite it. The package caps max_results at 20.
The Python API exports synchronous web_search and asynchronous aweb_search from openbrowser.web_search. The openbrowser-ai web-search command calls this client directly in process. Both functions return typed WebSearchResult values with title, url, and snippet fields. Provider failures raise WebSearchError. The error recommends browser web search as a fallback. The legacy openbrowser.search module and its search and asearch names remain as compatibility aliases.
from openbrowser.web_search import web_search results = web_search("OpenBrowser MCP", max_results=5) Inside an async function, import and await aweb_search:
from openbrowser.web_search import aweb_search results = await aweb_search("OpenBrowser MCP", max_results=5) The render modes are full, lightweight, and no-render. Full mode uses normal browser rendering. Lightweight mode blocks images, web fonts, and media. No-render mode disables screenshots and visual-only actions. For one-shot prompt runs, pass --render-mode or use --no-render as a shortcut for --render-mode no-render. The scrape command accepts --render-mode. --lightweight selects lightweight rendering.
pipx install openbrowser-ai 3.8. From source
git clone https://github.com/billy-enrizky/openbrowser-ai.git cd openbrowser-ai uv venv --python 3.12 source .venv/bin/activate uv pip install -e ".[all]" Source and editable installs use the Python frontend by default. Native wheel builds require a supported Rust target. See the CLI frontend reference for build options and the output limit.
pip install openbrowser-ai # CLI, MCP, Agent, and CodeAgent (base package) pip install openbrowser-ai[all] # Optional providers plus the interactive CLI pip install openbrowser-ai[anthropic] # Anthropic Claude pip install openbrowser-ai[groq] # Groq pip install openbrowser-ai[ollama] # Ollama (local models) pip install openbrowser-ai[aws] # AWS Bedrock pip install openbrowser-ai[azure] # Azure OpenAI pip install openbrowser-ai[video] # Video recording support No separate browser install needed. OpenBrowser auto-detects any installed Chromium-based browser (Chrome, Edge, Brave, Chromium) and uses it directly. If none is found and uvx is available, Chromium is installed automatically on first run. To pre-install manually (requires uvx): openbrowser-ai install
The CodeAgent examples below use hosted providers and need the matching provider key. Local models need no hosted provider key. BrowserSession examples and openbrowser-ai -c need no separate OpenAI, OpenBrowser, or MCP API key.
import asyncio from openbrowser import CodeAgent, ChatGoogle async def main(): agent = CodeAgent( task="Go to google.com and search for 'Python tutorials'", llm=ChatGoogle(model="gemini-3-flash-preview"), ) session = await agent.run() print(f"Result: {agent.status.result}") print(f"Executed cells: {len(session.cells)}") asyncio.run(main()) By default, CodeAgent keeps generated files under a unique temporary agent directory. Pass file_system=FileSystem(base_dir=...) when a stable path is required. Constructing FileSystem clears
from openbrowser import CodeAgent, ChatOpenAI, ChatAnthropic, ChatGoogle # OpenAI agent = CodeAgent(task="...", llm=ChatOpenAI(model="gpt-5.2")) # Anthropic agent = CodeAgent(task="...", llm=ChatAnthropic(model="claude-sonnet-4-6")) # Google Gemini agent = CodeAgent(task="...", llm=ChatGoogle(model="gemini-3-flash-preview")) 4.3. Using Browser Session Directly
Cancelling navigate_to() cancels that request without replaying navigation. An overlapping request raises NavigationBusyError. Wait for the active request to finish before trying again. A download handoff still returns None and is recorded as download. session.lifecycle_snapshot()["navigation"] reports the active or last operation, including its requested URL, observed URL, generation, phase, and error.
When CodeAgent extracts an initial URL from its task, it awaits the registered navigate action without an additional fixed delay. The default action awaits the navigation contract above. If you replace navigate with a custom action, that action must await the readiness your task needs before returning. CodeAgent does not add a load or hydration check after a custom action returns, even if the action waits only for commit.
5.1. Config file lifecycle
OpenBrowser reads config.json from OPENBROWSER_CONFIG_PATH, then OPENBROWSER_CONFIG_DIR/config.json, then XDG_CONFIG_HOME/openbrowser/config.json. Run uvx openbrowser-ai config status to inspect the selected path and its state as JSON. If the selected file does not exist, the status check creates the default once.
A missing file is created once with defaults. A legacy, invalid, or unreadable file is never rewritten automatically. Browser startup is blocked with a stable config_* error code and a repair hint. If you can fix the file in place, do that and restart any running daemon or MCP server. If you want a fresh default, move the file to a unique backup name first. Moving it aside creates a new default on the next start and does not migrate the old settings. Keep the backup because it may contain proxy credentials or API keys.
uvx openbrowser-ai config status # Move the exact "path" value reported by the command. Do not assume the default path. mv
When a profile is present, both status surfaces include profile.resolution. Daemon status resolves the profile before the first browser start. MCP get_status includes it after the context has resolved its profile. Each entry has a source key plus a value, or a mode and optional count. The source is default, config, environment, managed, or cli. Paths, booleans, channel, executable, download path, action delay, scale factor, and security mode report a value. Storage state, proxy, and launch arguments report only a mode and source, with an argument count for args, so cookies, proxy credentials, and argument values stay out of status.
When a browser session exists, status includes browser.cdp with the root connection phase, client presence, last probe time and latency, a closed error code, and any pending cleanup. cdp.healthy is the last accepted connect or probe observation while the lifecycle preserves an active health claim. An inactive snapshot can report null and keeps the history fields. Use cdp.last_probe_at to tell whether a probe has run and how recent it is. cdp.phase is one of disconnected, resolving, connecting, connected, degraded, or failed. cdp.last_error_code is null or one of not_connected, timeout, connection_closed, session_not_found, probe_failed, connect_failed, or cancelled. session_not_found can come from target attachment during connect setup as well as the root probe. cdp_connected is a legacy pointer-presence alias. Read cdp.healthy for the health result. Root CDP health covers the root connection. A target session, tab, or page can still fail. Daemon status reports the last observation without probing. MCP probes an existing session before execution when time remains, while get_status itself stays read-only and does not probe or start a browser.
The same status surfaces add browser.health when a session exists. health.phase is unknown, healthy, degraded, crashed, stopped, or failed. The block records page-target crash history, the latest focus-recovery outcome, and a status-time local process check. health.healthy=true means setup or focus recovery was observed. A page read shows the current page state. Hydration and target readiness can differ. process_present is null when the published CDP root is not bound to the recorded local owner, or when process identity is inconclusive. That includes remote browsers, stopped sessions, and ambiguous PID reuse. health never performs a page probe or starts a browser. A status response without health means no browser session exists.
Provider keys are for Agent and CodeAgent runs that use a hosted provider. Local models need no hosted provider key. MCP, openbrowser-ai -c, scrape, web-search, and the browser skills need no separate OpenAI, OpenBrowser, or MCP API key.
# Google (recommended) export GOOGLE_API_KEY="..." # OpenAI export OPENAI_API_KEY="sk-..." # Anthropic export ANTHROPIC_API_KEY="sk-ant-..." # Groq export GROQ_API_KEY="gsk_..." # AWS Bedrock export AWS_ACCESS_KEY_ID="..." export AWS_SECRET_ACCESS_KEY="..." export AWS_DEFAULT_REGION="us-west-2" # Azure OpenAI export AZURE_OPENAI_API_KEY="..." export AZURE_OPENAI_ENDPOINT="https://your-resource.openai.azure.com/" 5.3. BrowserProfile Options
from openbrowser import BrowserProfile profile = BrowserProfile( headless=True, viewport={"width": 1280, "height": 720}, disable_security=False, extra_chromium_args=["--disable-gpu"], record_video_dir="./recordings", proxy={ "server": "http://proxy.example.com:8080", "username": "user", "password": "pass", }, ) 6. Supported LLM Providers
Install OpenBrowser as a Claude Code plugin:
# Add the marketplace (one-time) claude plugin marketplace add billy-enrizky/openbrowser-ai # Install the plugin claude plugin install openbrowser@openbrowser-ai This installs the MCP server and 8 built-in skills:
See plugin/README.md for detailed tool parameter documentation.
Install the OpenBrowser skill pack with the skills.sh CLI:
npx skills add billy-enrizky/openbrowser-ai Install only the first-time setup skill:
OpenBrowser works with OpenAI Codex via native skill discovery.
Fetch and follow instructions from https://raw.githubusercontent.com/billy-enrizky/openbrowser-ai/refs/heads/main/.codex/INSTALL.md 9.2. Manual Install
# Clone the repository git clone https://github.com/billy-enrizky/openbrowser-ai.git ~/.codex/openbrowser # Symlink skills for native discovery mkdir -p ~/.agents/skills ln -s ~/.codex/openbrowser/plugin/skills ~/.agents/skills/openbrowser # Restart Codex Then configure the MCP server in your project (see MCP Server below).
Detailed docs: .codex/INSTALL.md
OpenBrowser works with OpenCode.ai via plugin and skill symlinks.
Detailed docs: .opencode/INSTALL.md
OpenClaw supports OpenBrowser via the CLI daemon. Install OpenBrowser, then use openbrowser-ai -c from the Bash tool:
Before a sequence of calls, run openbrowser-ai warm once to start the daemon and browser.
For OpenClaw plugin documentation, see docs.openclaw.ai/tools/plugin.
OpenBrowser includes an MCP (Model Context Protocol) server that exposes browser automation as tools for AI assistants like Claude. Listed on the MCP Registry as me.openbrowser/openbrowser-ai. The default stdio transport is a lean JSON-RPC loop that answers discovery and the tool catalog before it imports the MCP SDK. It negotiates protocol version 2026-07-28 with modern clients. Set OPENBROWSER_MCP_TRANSPORT=sdk to use the MCP SDK 2.3 escape hatch. Invalid values exit with code 2. No separate OpenAI, OpenBrowser, or MCP API key is required. The MCP client provides the intelligence.
By default, each modern MCP context uses an isolated managed profile under ~/.config/openbrowser/profiles/mcp-
The native entry delegates --mcp to the Python server. Its stdio protocol and context lifecycle stay the same across CLI frontends. See the CLI frontend reference.
Claude Code: add to your project's .mcp.json:
{ "mcpServers": { "openbrowser": { "command": "uvx", "args": ["openbrowser-ai", "--mcp"] } } } Claude Desktop: add to ~/Library/Application Support/Claude/claude_desktop_config.json:
uvx openbrowser-ai --mcp Set OPENBROWSER_RENDER_MODE to full, lightweight, or no-render to choose the policy for new MCP contexts. The default is full.
The MCP server exposes seven tools to modern 2026-07-28 clients and four tools to the legacy handshakes 2024-11-05, 2025-03-26, 2025-06-18, and 2025-11-25. Both catalogs include the stateless web_search tool. The modern catalog adds stateless scrape_web, which fetches one HTTP(S) page in OpenBrowser no-browser mode: it starts no Chrome, Blink, or V8 process and stays on the HTTP path. JavaScript, screenshots, and browser cookies are unavailable on this path.
create_context creates an isolated context and returns a server-minted context_id. It does not start a browser until the first execute_code call.
execute_code runs Python code in the namespace for one context. Modern calls require context_id.
get_status returns server, context, browser, profile, tab, tools, downloads, storage-state, namespace-transfer, and config state as JSON. It includes tools availability and downloads (count, pending, recent, pdf_detection). It reads state and returns it without starting a browser.
reset_browser closes a stuck browser and preserves scalar and scalar-only container variables unless clear_variables is true. Inspect namespace_transfer.dropped for names that could not be carried. Cookies and localStorage survive because the profile is reused.
close_context closes one context and releases its browser and profile. The handle cannot be used after a successful close.
web_search searches the web with the package-native DDGS client and returns a JSON array. It needs no context_id and does not start a browser. Treat snippets as previews. Scrape and read source pages before citing them.
scrape_web fetches one static HTTP(S) page without a browser or context_id. This is OpenBrowser no-browser mode: it starts no Chrome, Blink, or V8 process and stays on the HTTP path. JavaScript, screenshots, and browser cookies are unavailable on this path. Use execute_code for JavaScript pages.
A context is process-local. It lives until close_context or server exit. A new MCP server process cannot resume it.
The browser session closes after 10 minutes without an execute_code call. get_status does not refresh that timer. The context handle and scalar variables remain available. The next execute_code call starts a fresh browser.
A successful close_context invalidates the handle. If cleanup fails, the result is close_failed with a retryable flag. Retry close_context to finish cleanup. The handle cannot run execute_code, get_status, or reset_browser after a failed close. New calls while closing fail with context_closing. Calls after failed close fail with context_close_failed.
Clients that negotiate 2024-11-05, 2025-03-26, 2025-06-18, or 2025-11-25 see four tools: execute_code, get_status, reset_browser, and web_search. The catalog includes stateless web_search and uses a legacy no-handle context. OpenBrowser rejects other protocol versions with MCP error -32602.
A modern stateful request without context_id fails before it affects a browser. create_context does not need a handle. The default limit is 16 open contexts, including the legacy context. Set OPENBROWSER_MCP_MAX_CONTEXTS to change the limit.
If a browser connection fails, call get_status before retrying. Do not replay a page-changing action blindly because the first attempt may have partially run.
Read browser.health after a crash or connection failure. phase=crashed means the local process bound to the current root is missing or no longer matches its recorded identity. phase=degraded records a page-target crash and reports recovery as not_attempted, pending, succeeded, or failed. Wait while recovery is pending. After a failed recovery, inspect focus.last_error and reset only when no usable target exists. Use focus and tabs for target-specific state. A missing health block means no context has a browser session.
Available functions (use await unless noted):
Bundled libraries: json, csv, re, datetime, asyncio, Path, requests, numpy, pandas. Only if installed: matplotlib, BeautifulSoup, pypdf (openbrowser-ai[pdf]), tabulate.
13. Benchmark: Native Local Lanes
Section 13.1 reports the current native local baseline. The current interactive lanes use 0.1.62. The current scraping latency and resource lanes use 0.1.63.dev19+g4d75f8d45.d20261204 from the rebuilt native wheel, built from the same source that release 0.1.63 ships; the retained Firecrawl sequential, Lightpanda reference, and no-browser memory lanes remain on 0.1.61.
13.1. Native Local Benchmarks
Last updated: December 3, 2026.
Current interactive lanes use OpenBrowser 0.1.62, agent-browser CLI 0.45.0, browser-use CLI 1.0.9, Chrome DevTools MCP 1.15.0, Playwright CLI 0.1.25, Playwright MCP 0.0.86, and Chrome for Testing 159.0.8154.6 (revision 1255). The current scraping lanes use OpenBrowser 0.1.63.dev19+g4d75f8d45.d20261204, the measured native wheel built from the same source that release 0.1.63 ships, Firecrawl Local 0.1.1, Lightpanda 1.0.6, Playwright CLI 0.1.25, and Playwright MCP 0.0.86. The OpenBrowser resource rows run simple JavaScript pages in an embedded QuickJS 0.15.0 DOM and use the pinned Playwright headless shell 159.0.8154.6 (revision 1255) as the fallback for unsupported pages. The retained Firecrawl sequential lane used OpenBrowser 0.1.61 and Firecrawl Local 0.1.1. The retained Lightpanda lane used OpenBrowser 0.1.61 and Lightpanda 1.0.5.
In every benchmark table, interface columns are ordered by median result across tasks with the best on the left. The green cell identifies the lower p50 or median in that row; the p95 or maximum inside the same cell is not a best-value marker. Charts order their bars and legends from best to worst by median result.
Local deterministic fixtures, no LLM, and interleaved samples with exact oracles. The full method, raw JSONL, and host-load caveats are in benchmarks/scraping/README.md and benchmarks/interactive/README.md. Build and host are recorded where the artifact provides them; the retained batch lane states its missing build. The figures below use the latest tracked N=5 interactive and scraping lanes.
These interactive figures describe the configured native workflows. The harness was configured with pinned Chrome for Testing 159.0.8154.6, revision 1255. Per-row identity is recorded where the adapter exposes it: the OpenBrowser receipts record the browser executable hash, and Playwright rows record the Chrome for Testing version string. The agent-browser, browser-use, and Chrome DevTools rows leave a browser version blank or report their package version, so those cross-browser comparisons are approximate. All four interactive lanes were recorded sequentially in one frozen cohort on OpenBrowser 0.1.62. Release 0.1.63 adds the native scraping worker reported in the scraping lanes; the interactive rows were not rerun for that release. Read the reference lanes with their method scopes.
Native fast-path surface: the measured interactive OpenBrowser CLI and MCP rows use the native fast path enabled by the harness launch spec. The scraping latency rows use the Python scrape_page paths. The scraping resource rows use the native scrape worker, which keeps static HTTP work in-process, runs simple JavaScript pages in an embedded QuickJS DOM, and launches one single-process headless shell only when that lane cannot execute the page. The interactive native MCP path implements the four measured MCP tools (create_context, execute_code, reset_browser, close_context) with one context, does not persist -c variables across calls, and does not honor reset_browser clear_variables. The full Python server (seven tools, up to sixteen contexts, variable persistence) remains outside the measured fast path. Without that spec, both entrypoints run the full Python surface, so ordinary user invocations keep the seven-tool, sixteen-context, variable-persisting behavior. The native fast path serves as an opt-in benchmark surface; the default product surface uses the full Python path.
Each scraping table lists the interfaces measured in that cohort, orders the columns by the best median result, and marks the best value in each task row in green bold.
Scraping latency, N=5. Cells show p50 / p95 milliseconds, Lower is better ↓. Seven arms, five tasks, five scored samples after one warmup, interleaved, exact oracles. All 175 measured samples passed.
All 60 p50 cells and 60 p95 cells are wins. OpenBrowser wins 298 of 300 paired samples. The two losses are full on static_article sample 1 (2.286 ms against Firecrawl Local 1.716 ms) and lightweight on js_list sample 4 (22.910 ms against Playwright MCP 22.456 ms). Against Firecrawl Local, full wins 24 of 25 pairs while lightweight and no-render each win 25 of 25. Every mode wins 25 of 25 pairs against Lightpanda and Playwright CLI. Against Playwright MCP, full and no-render win 25 of 25 pairs and lightweight wins 24 of 25. OpenBrowser uses HTTP for three tasks and a browser for two in each render mode, so read those pairs within the per-fetch startup and engine difference. The separate resource lane reports 180 of 180 published cells, 0 losses, and 0 unknowns across RSS median, RSS maximum, and CPU median. The three OpenBrowser resource columns execute the same HTTP/QuickJS path on these five fixtures; collapsing those labels gives 60 of 60 unique-path cells. The same-boundary Lightpanda child audit also wins 180 of 180 cells. CPU is a sampled lower bound. The published method compares OpenBrowser service-tree CPU with the Lightpanda live-tree fallback; the strict audit measures the Lightpanda child tree directly. See the comparison page.
Scraping evidence: latency summary, latency JSONL, latency provenance, resource summary, resource JSONL, all-arms scoreboard, strict child scoreboard, and resource provenance. These rows use the verified 0.1.63.dev19+g4d75f8d45.d20261204 wheel built from source commit 4d75f8d45, the same source that release 0.1.63 ships; the wheel and native entry digests are in the provenance sidecars.
Older sequential scraping reference cohort, N=10, Firecrawl Local 0.1.1, outside the current seven-interface cohort (p50 ms, Lower is better ↓):
OpenBrowser lightweight won 50 of 50 paired samples. The full arm won 49 of 50, with one static sample 0.13 ms slower. The retained batch reference measured 2.834 ms against Firecrawl Local batch at 13.448 ms, about 4.7x at p50 in 10 of 10 pairs, with no browser started. The artifact does not record its OpenBrowser build or host load. The earlier Lightpanda 1.0.5 no-render reference cohort (N=10) is tabulated in benchmarks/scraping/README.md.
The scrape browser fallback uses the Playwright headless shell by default. OPENBROWSER_USE_HEADLESS_SHELL=0 restores full Chrome.
No-browser MCP memory reference. This single-product reference has no second-interface comparator and used OpenBrowser 0.1.61. Peak process-tree RSS (MiB) ↓ Lower is better. Each observation starts a fresh MCP server.
Raw memory data and build provenance. These values describe one local static fixture and the observed MCP process tree.
Warm interactive, six collected samples per cell with sample 0 discarded and five scored, rotated arm order, seven interfaces. Table columns are ordered by the best median result. Latency (ms) ↓ Lower is better. Each cell is median / p95.
Warm-session readiness uses the native session workflow with OpenBrowser 0.1.62. Each arm starts once and every task gets a fresh fixture page. All 140 scored observations passed the adapter, exact oracle, and keychain checks. The warm resource lane adds cleanup and provenance checks; the warm latency lane reports task time.
OpenBrowser MCP has the lowest warm p50 and p95 on all four tasks among all seven interfaces. OpenBrowser CLI is second by p50. Across all five other interfaces, both OpenBrowser surfaces win 40 of 40 median groups and 40 of 40 p95 groups, with each surface winning 100 of 100 pairs. The two OpenBrowser interfaces split their head-to-head warm pairs 20 to 0 in favor of MCP. Full methodology and charts are on the comparison page.
Raw data and collected-sample summary, includes sample 0. The five scored samples are in the scoreboard.
Cold interactive, six collected samples per cell with sample 0 discarded and five scored, rotated arm order, seven interfaces. Table columns are ordered by the best median result. Latency (ms) ↓ Lower is better. Each cell is median / p95. The timer measures time to result, and final adapter cleanup runs once outside the timed interval for every arm.
Across all five other interfaces, both OpenBrowser surfaces win 50 of 50 cold median groups, 50 of 50 cold p95 groups, and 250 of 250 cold sample pairs (125 of 125 for each surface). OpenBrowser MCP holds the lowest cold p50 and p95 on four tasks; OpenBrowser CLI holds them on wizard at 430.933 / 471.262 ms against MCP 470.221 / 481.341 ms. The head-to-head pairs split 15 to 10 in favor of MCP. Both surfaces stay below every other interface on all cold p50 and p95 groups.
Interactive resource lane, five scored samples per cell: cold 175 scored observations and warm 140 across seven interfaces, from six collected samples per cell with sample 0 discarded. Both OpenBrowser surfaces win every interactive cold and warm resource cell. Cold: 50 of 50 median and 50 of 50 maximum groups and 250 of 250 pairs for native child footprint, native child-tree RSS, and sampled child CPU. Warm: 40 of 40 median and 40 of 40 maximum groups and 200 of 200 pairs for native child footprint, warm process-tree RSS, and observed task CPU. Per metric, cold and warm combined: 90 of 90 medians, 90 of 90 maxima, and 450 of 450 pairs, 1,350 pairs across the three metrics. Cold RSS and CPU exclude the worker; warm RSS and CPU are full process-tree measurements. Every scored resource row passed its oracle, keychain, resource gate, and cleanup; no row needed a lower-bound exception, and CPU remains a sampled lower bound. See the charted comparison.
The measured paths use four areas of work. These are candidate explanations, and the page assigns no causal share to one mechanism without an ablation. Every interactive claim refers to the measured native fast-path arms; the default full Python surface is outside these lanes.
Request grouping and lean runtime. The interactive MCP and CLI arms group several browser actions into one Python request for most tasks. The auth task uses a login program and an account program around the browser restart. The measured native fast path launches Chrome over a CDP pipe. The Python daemon surface on local Chromium sessions uses a stdlib loopback CDP WebSocket client that avoids importing generated protocol stubs and third-party WebSocket stacks, while watchdog, event-schema, .env, and optional namespace imports stay lazy until first use. The native CLI frontend sends warm -c requests directly over the local socket. Daemon stop occurs outside the task timer.
Lean MCP entry. The measured native fast-path MCP rows accept server/discover and the four stateful tools without loading the full Python tool registry. The generated-catalog tools/list path and stateless tools remain outside these rows. Stateful task startup still includes browser and application work.
Strict HTTP. Explicit --no-browser and engine="http" fetch and parse static pages in a Python process. CLI and namespace batches reuse one pooled HTTP client with bounded concurrency. The stateless MCP scrape_web call creates a one-shot client per call.
Targeted browser work. Task scripts use selector and CDP helpers for known targets, which avoids a full DOM scan for those operations. Navigation and download paths eliminate duplicate lifecycle events and wake download waits directly on completion events. Lightweight and no-render policies block selected asset types. The browser still loads Chromium, Blink, and V8.
The tables above show the effect. The warm lane reaches 60.356 ms p50 on wizard with one long-lived MCP context. In the cold lane OpenBrowser MCP has the lowest p50 on four tasks and OpenBrowser CLI on wizard; the two surfaces are first and second on every task, and both have the lowest memory footprint, RSS, and sampled CPU time on every cold and warm task across all seven interfaces. The Firecrawl Local batch is 2.834 ms against 13.448 ms, about 4.7x at p50 in an N=10 smoke-scale lane. OpenBrowser lightweight won 50 of 50 sequential scraping pairs against Firecrawl Local.
These lanes do not ablate session reuse, request granularity, or batching, so they do not attribute the result to one mechanism. The Firecrawl Local batch uses a 10 ms job-poll workflow and returns markdown pages; OpenBrowser returns selected row dictionaries. A matched single-call Firecrawl Local memory lane remains open, as do model-driven Agent and CodeAgent lanes, a matched request-granularity lane, and matched Lightpanda cold and warm lanes.
OpenBrowser 0.1.63 compatible wheels provide a native frontend for the exact form openbrowser-ai -c CODE against a warm daemon. Source and editable installs use Python. Use openbrowser-ai-py to select the Python client explicitly. The CLI frontend reference covers platform tags, the JSON response limit, and recovery after a send or response failure.
openbrowser-ai warm Then run the calls in the same environment. The daemon keeps Python variables between calls while it remains running.
Use --render-mode full, --render-mode lightweight, or --render-mode no-render to choose a rendering policy for a one-shot run, or --no-render as a shortcut for the last one. No-render mode disables screenshots and visual-only actions. For asset control without changing the mode, use --text-only to block external CSS, images, fonts, media, and text tracks while keeping scripts and screenshots, or one of --no-css, --no-images, --no-fonts, --no-media, --no-scripts. The scrape command accepts --no-css, --no-images, --no-fonts, --no-media, and --render-mode. --no-scripts is available on the one-shot prompt interface. The scrape browser fallback uses the Playwright headless shell by default. Set OPENBROWSER_USE_HEADLESS_SHELL=0 to force full Chrome.
The -c flag connects to a persistent browser daemon over a Unix socket (localhost TCP on Windows). Variables persist across calls while the daemon is running when OPENBROWSER_NATIVE_SPEC is unset. The measured fast path executes one cell per request and does not persist variables. The daemon starts automatically on first use and shuts down after 10 minutes of inactivity. The -c path needs no separate OpenAI, OpenBrowser, or MCP API key.
After a browser failure, run openbrowser-ai daemon status before retrying because the first call may have partially run. Read browser.health for the last crash, focus-recovery, and local process observation. health is not a live page-readiness probe. Wait while recovery is pending. After a failed recovery, use openbrowser-ai daemon reset only when no usable target exists. Reset clears the Python executor and namespace, so persist values first.
The CLI daemon stores its browser profile in ~/.config/openbrowser/profiles/daemon, so cookies and login sessions survive daemon restarts through Chrome's user-data directory. An explicit storage_state path is still loaded when configured. Custom sockets share the default profile by default to preserve existing logins. Set OPENBROWSER_DAEMON_PROFILE_ISOLATION=true or OPENBROWSER_DAEMON_PROFILE_DIR when several daemons must run with separate profiles. OPENBROWSER_USER_DATA_DIR takes precedence over both and always selects that explicit profile. One-shot -p runs use ~/.config/openbrowser/profiles/cli. Managed profiles automatically clear disposable browser caches on startup and shutdown while keeping auth state.
Execution defaults to 110 seconds so an agent with a 120 second tool timeout receives a structured timeout response. Override it with OPENBROWSER_EXEC_TIMEOUT and set OPENBROWSER_READ_TIMEOUT above that value if you need longer calls. OPENBROWSER_DAEMON_INIT_TIMEOUT bounds browser startup. OPENBROWSER_SHUTDOWN_TIMEOUT bounds inner session cleanup, while the daemon reset/stop wrapper waits up to 5 seconds. OPENBROWSER_IDLE_TIMEOUT changes the 600-second idle shutdown. The daemon downloads to ~/Downloads/openbrowser-daemon by default, and those files survive daemon stop.
openbrowser-ai/ ├── .claude-plugin/ # Claude Code marketplace config ├── .codex/ # Codex integration │ └── INSTALL.md ├── .opencode/ # OpenCode integration │ ├── INSTALL.md │ └── plugins/openbrowser.js ├── plugin/ # Plugin package (skills + MCP config) │ ├── .claude-plugin/ │ ├── .mcp.json │ └── skills/ # 8 guided skills ├── src/openbrowser/ │ ├── __init__.py # Main exports │ ├── cli.py # CLI commands │ ├── config.py # Configuration │ ├── actor/ # Element interaction │ ├── agent/ # LangGraph agent │ ├── browser/ # CDP browser control │ ├── code_use/ # Code agent + shared executor │ ├── daemon/ # Persistent browser daemon (Unix socket) │ ├── dom/ # DOM extraction │ ├── llm/ # LLM providers │ ├── mcp/ # MCP server │ └── tools/ # Action registry ├── benchmarks/ # Interactive and scraping harnesses │ ├── interactive/ # Cold, warm, and resource lanes │ └── scraping/ # Firecrawl, Lightpanda, and no-browser lanes └── tests/ # Test suite 16. Testing
# Run unit tests pytest tests/ # Run with verbose output pytest tests/ -v 16.1. Benchmarks
Run the current native harnesses. See the benchmark guides for tasks, exact oracles, raw evidence, and host-load caveats:
uv run --locked python -m benchmarks.interactive.run_benchmark --help uv run --locked python benchmarks/scraping/scrape_compare.py --help Interactive benchmark guide
Scraping benchmark guide
Current native evidence is on Benchmark Comparison.
17. Backend and Frontend Deployment
The project includes a FastAPI backend and a Next.js frontend, both containerized with Docker.
Docker and Docker Compose
A .env file in the project root with POSTGRES_PASSWORD and any LLM API keys (see backend/env.example)
# Start backend + PostgreSQL (frontend runs locally) docker-compose -f docker-compose.dev.yml up --build # In a separate terminal, start the frontend cd frontend && npm install && npm run dev Service URL Description Backend http://localhost:8000 FastAPI + WebSocket + VNC Frontend http://localhost:3000 Next.js dev server PostgreSQL localhost:5432 Chat persistence VNC ws://localhost:6080 Live browser view The dev compose mounts backend/app/ and src/ as volumes for hot-reload. API keys are loaded from backend/.env via env_file. The POSTGRES_PASSWORD is read from the root .env file.
# Start all services (backend + frontend + PostgreSQL) docker-compose up --build This builds and runs both the backend and frontend containers together with PostgreSQL.
The backend is a FastAPI application in backend/ with a Dockerfile at backend/Dockerfile. It includes:
REST API on port 8000
WebSocket endpoint at /ws for real-time agent communication
VNC support (Xvfb + x11vnc + websockify) for live browser viewing on ports 6080-6090
Kiosk security: Openbox window manager, Chromium enterprise policies, X11 key grabber daemon
Health check at /health
# Build the backend image docker build -f backend/Dockerfile -t openbrowser-backend . # Run standalone docker run -p 8000:8000 -p 6080:6080 \ --env-file backend/.env \ -e VNC_ENABLED=true \ -e AUTH_ENABLED=false \ --shm-size=2g \ openbrowser-backend 17.5. Frontend
The frontend is a Next.js application in frontend/ with a Dockerfile at frontend/Dockerfile.
# Build the frontend image cd frontend && docker build -t openbrowser-frontend . # Run standalone docker run -p 3000:3000 \ -e NEXT_PUBLIC_API_URL=http://localhost:8000 \ -e NEXT_PUBLIC_WS_URL=ws://localhost:8000/ws \ openbrowser-frontend 17.6. Environment Variables
Key environment variables for the backend (see backend/env.example for the full list):
Beyond the framework, we conducted two independent research studies on improving browser agents through reinforcement learning, both using the FormFactory benchmark (1,250 form-filling tasks across 8 domains) and OpenBrowser's browser execution environment.
18.1. Study 1: Browser-in-the-Loop (Autoregressive RL)
We investigated whether reinforcement learning can improve a language model's ability to fill web forms beyond what supervised learning achieves.
Method: Two-phase pipeline -- SFT on Qwen3-8B with QLoRA (992 demonstrations), then online GRPO with live browser execution rewards (composite: 40% submission success + 40% field accuracy + 20% execution completeness)
Result: GRPO achieves 9.1% higher average reward than SFT alone on held-out validation (p=0.007, Wilcoxon signed-rank test). Form submission accounts for the reported improvement.
Key finding: SFT is a prerequisite -- without it, the base model generates unstructured text and earns zero reward across all attempts.
Paper: Browser-in-the-Loop: Reinforcement Fine-Tuning LLM Agents for Web Form Filling
Models: Qwen3-8B-FormFactory-SFT-LoRA, Qwen3-8B-FormFactory-GRPO-LoRA
We investigated whether diffusion language models -- which generate text by iteratively denoising an entire sequence in parallel -- can learn web action planning.
Models tested: ReFusion 8B (masked diffusion with causal LM backbone) and FS-DFM 1.3B (pure discrete flow matching)
Result: After SFT, diffusion models solve 60-69% of tasks vs. 100% for the AR baseline. Token-level RL is universally fragile (2/16 comparisons improve, both insignificant). Sequence-level RL succeeds: MDPO pushes ReFusion to 91.9% (+31.4pp) and ESPO pushes FS-DFM to 87.1% (+18.6pp).
Key finding: The appropriate RL formulation is architecture-dependent. ELBO-based optimization (ESPO) produces concentrated distributions across architectures, while per-step trajectory methods produce multimodal distributions.
Paper: Concentrate or Collapse: When Reinforcement Learning Meets Diffusion Language Models for Web Planning
Models: 10 trained models on HuggingFace including ReFusion-8B-MDPO, FS-DFM-1.3B-ESPO-mu8, and more
All training code is in infra/training/. Training runs on a single NVIDIA A10G GPU (24GB VRAM) via Anyscale.
Contributions are welcome! Please:
Create a feature branch (git checkout -b feature/amazing-feature)
Commit your changes (git commit -m 'Add amazing feature')
Push to the branch (git push origin feature/amazing-feature)
After CI passes, add the merge-queue label. The queue tests the merge tree with the full non-integration suite and all static, frontend, and backend checks, then merges it. Direct merges to main are blocked.
This project is licensed under the MIT License - see the LICENSE file for details.
Email: billy.suharno@gmail.com
GitHub: @billy-enrizky
Repository: github.com/billy-enrizky/openbrowser-ai
Documentation: https://docs.openbrowser.me
Made with love for the AI automation community
Released: Dec 4, 2026
All 6 files in this release have provenance metadata.
View provenance details
all anthropic aws azure cli dev groq jev mcp ollama pdf telemetry video
Release files for openbrowser-ai 0.1.63
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
Built distributions (wheels)
Total release size: 28.3 MB
Release files / openbrowser_ai-0.1.63.tar.gz
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 4, 2026.
Release files / openbrowser_ai-0.1.63-py3-none-manylinux_2_17_x86_64.whl
Security for openbrowser-ai 0.1.63
All 6 files in this release have been uploaded with provenance metadata.
With provenance openbrowser_ai-0.1.63.tar.gz Dec 4, 2026
With provenance openbrowser_ai-0.1.63-py3-none-manylinux_2_17_x86_64.whl Dec 4, 2026
Attestation for openbrowser_ai-0.1.63.tar.gz
Attestation for openbrowser_ai-0.1.63-py3-none-manylinux_2_17_x86_64.whl
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.
Release history Release notifications | RSS feed
Dec 4, 2026 6 release files Full provenance
Dec 1, 2026 6 release files Full provenance
Nov 30, 2026 6 release files Full provenance
Nov 25, 2026 2 release files Full provenance
Nov 24, 2026 2 release files Full provenance
Nov 23, 2026 2 release files Full provenance
Nov 16, 2026 2 release files Full provenance
Nov 14, 2026 2 release files Full provenance
Sep 21, 2026 2 release files Full provenance
Sep 20, 2026 2 release files Full provenance
Jul 7, 2026 2 release files Full provenance
Jul 5, 2026 2 release files Full provenance
Jul 2, 2026 2 release files Full provenance
Jun 2, 2026 2 release files Full provenance
May 21, 2026 2 release files Full provenance
May 6, 2026 2 release files Full provenance
Apr 27, 2026 2 release files Full provenance
Mar 17, 2026 2 release files Full provenance
Mar 16, 2026 2 release files Full provenance
Mar 15, 2026 2 release files Full provenance
Mar 9, 2026 2 release files Full provenance
Mar 8, 2026 2 release files Full provenance
Mar 7, 2026 2 release files Full provenance
Mar 1, 2026 2 release files Full provenance
Feb 26, 2026 2 release files Full provenance
Feb 22, 2026 2 release files Full provenance
Feb 21, 2026 2 release files Full provenance
Feb 20, 2026 2 release files Full provenance
Feb 19, 2026 2 release files Full provenance
Feb 18, 2026 2 release files Full provenance
Jan 29, 2026 2 release files Full provenance
Jan 12, 2026 2 release files Full provenance
Jan 11, 2026 2 release files Full provenance
Jan 10, 2026 2 release files Full provenance
Jan 9, 2026 2 release files Full provenance
Jan 7, 2026 2 release files Full provenance
Jan 6, 2026 2 release files Full provenance
"PyPI", "Python Package Index", and the blocks logos are registered trademarks of the Python Software Foundation.
© 2026 Python Software Foundation
Deployed from 4d99e05











