Browser Harness
π Description
browser-use/browser-harness β minimal editable CDP harness. One websocket to Chrome, nothing between. The agent writes whatβs missing during execution and the harness improves itself every run.
Same org as Browser Use and Video Use. Where Browser Use is a full framework, Browser Harness goes the opposite direction: a thin shell where the agent writes its own helpers. Embodies the βbitter lesson of agent harnessesβ β stop over-engineering, let the agent fill in gaps as it works.
The thesis won (2026-07-01)
Browser Use CLI 3.0 is now officially powered by Browser Harness. The parent framework dropped its fixed action menu (
click/type) in favor of this harnessβs model β the agent executes arbitrary Python in the browser and self-heals in one coding loop. So Browser Harness is no longer just the minimal sibling; it is the engine behind Browser Useβs flagship CLI. As of pipbrowser-use0.13.4, the package pinsbrowser-harness==0.1.5andbrowser-use-sdk==3.4.2.
π§© Features
- ~1k lines across 4 core files
install.mdβ first-time install and browser bootstrapSKILL.mdβ day-to-day usagesrc/browser_harness/β protected coreagent-workspace/agent_helpers.pyβ helper code the agent editsagent-workspace/domain-skills/β reusable per-site playbooks the agent builds (LinkedIn, Amazon, GitHubβ¦)- Set
BH_DOMAIN_SKILLS=1to enable surfacing of community-contributed per-domain skills - Works with Claude Code, Codex, any agent with shell access
- Connects via
chrome://inspect/#remote-debugging(Chrome 144+ allow popup)
π¨ Self-healing pattern
agent: wants to upload a file
agent-workspace/agent_helpers.py β helper missing
agent writes it β + custom helper
β file uploaded
Skills are written by the harness, not by you. When the agent figures something non-obvious out, it files the skill itself. Donβt hand-author skill files β agent-generated ones reflect what actually works in the browser.
π οΈ Install & bring-up (verified 2026-07-10)
Distribution has converged: the harness now ships inside the browser-use pip package β uv tool install browser-use (pkg v0.13.3) gives you the CLI browser-use, and browser-use --doctor self-identifies as browser-harness. The browser-use CLI is this harness. browser-use --version reports the internal 0.1.4, not the pip version.
Day-to-day: browser-use <<'PY' ... PY heredocs, helpers pre-imported (new_tab, page_info, js, click_at_xy, fill_input, wait_for_loadβ¦). First navigation must be new_tab(url). No LLM key needed in this mode β the agent writes the Python; keys are only for the framework Agent(...) loop or the hosted cloud agent.
Full real-world Windows bring-up (no Chrome β isolated Edge over CDP, BU_CDP_WS, launcher, skill install, gotchas): Running Browser Use on Windows via Edge CDP.
Reasoning for
For browser tasks where you need complete freedom β no opinionated framework boxing you in. Lets a competent coding agent build a per-site automation library on the fly. Pair with Browser Use Cloud for stealth/proxies when needed.
Alternatives considered
- Browser Use β fuller framework, opinionated agent loop
- Playwright with custom selectors β no learning, no self-improvement
- Stagehand / Skyvern β agentic browser frameworks with more structure
π Links
- Repo: https://github.com/browser-use/browser-harness
- Setup prompt: paste install request into Claude Code or Codex, agent handles the rest
π Further reading
π Related notes
- Browser Use β sibling, full framework
- Video Use β sibling, video editing under same philosophy
- Claude Code β primary host agent
- Awesome Claude Code β broader CC ecosystem
- Running Browser Use on Windows via Edge CDP β verified Windows bring-up how-to
Template: tool