OpenCode Browse is the browser automation layer that lets AI coding agents drive a real Chrome window through an extension and an MCP server. Its developer, Dax Raad, rewrote it in Rust for $60 in model credits, and the memory numbers moved further than the project expected.
If you run coding agents on a laptop or a shared build box, this is the detail worth understanding: the thing that usually limits you is not tokens, it is how much memory each agent burns while it has a browser open.
The numbers, side by side
| Measure | Node version | Rust version |
|---|---|---|
| Binary size | 53–64 MB | 4.3 MB |
| Memory per Browse connector | ~190 MB | ~5.6 MB after a few calls |
| Relay memory | 353 MB after six days | 6 MB idle, 6.6 MB after calls |
The per-connector drop is roughly 97%. Put ten agents in parallel and the difference is about 1.9 GB versus 56 MB.
What OpenCode Browse actually is
Browse connects an AI coding agent to the browser you already use, rather than spinning up a headless browser per task. The agent talks to a local relay; the relay talks to a Chromium extension; the extension acts on tabs the agent is allowed to touch. That architecture is why memory matters twice: once per connector, once for the relay that stays up all day.
The old implementation used Playwright for automation and Patchright to reduce automation detection. The rewrite keeps the extension and replaces the Node CLI and relay with Rust, implementing only the behaviour Browse needed rather than carrying two general-purpose libraries.
How the Rust version works
- WebSockets between the Rust relay and the Chromium extension.
- Chrome DevTools Protocol for browser operations, agent sessions, recordings and network captures.
- Embedded QuickJS to execute agent-supplied JavaScript without a Node runtime on the box.
- Access controls kept: relay authentication, extension pairing, origin restrictions, and agents limited to tabs they opened themselves or that you explicitly share.
How to use it
- Install OpenCode and add the Browse Chromium extension to the browser you actually use.
- Start the Browse relay and pair the extension with it; the pairing is what authorises the extension to accept commands.
- Let the agent open its own tabs. It cannot reach tabs you have open unless you share them, which is the main safety boundary in the design.
- Keep the relay bound to your machine and leave origin restrictions in place. The extension is the attack surface, not the CLI.
- Run a couple of real tasks before trusting it with anything authenticated, and watch the connector count. Memory scales per connector, so the ceiling arrives quietly.
Two features did not survive the rewrite: time zone and locale emulation were dropped, and the download tool is gone because Chrome blocks it for extensions. A known issue also carried over from the Node version: a busy-looping eval still cannot be stopped through the extension.
Why do the Rust rewrite at all?
Because the tax on agent work is residency, not throughput. A coding agent that opens a browser, reads a page and closes it is fine. Twenty of them across a working day, each holding a Node runtime and a Playwright dependency tree, is 4 GB of ambition. A 4.3 MB binary that idles at 6 MB changes what you can run on a normal laptop, and it makes the tool cheap enough to leave running between tasks.
There is a second reason: the rewrite removed dependencies the project did not control. That is a real gain in supply-chain terms, and it is also the source of the new obligation.
What the $60 does not cover
Raad used Claude Opus as the main coding model and DeepSeek as a subagent, and says the rewrite only cost $60. That figure excludes his own time reviewing, testing and fixing the result, which is the part that decides whether a rewrite survives contact with production.
It also excludes maintenance. Playwright and Patchright ship browser compatibility work, authentication changes and security fixes. Replacing them means the Browse team now owns that work directly. The pull request shows two rounds of regression testing with about ten agents against real Chrome, and a score of 85% on Stealth Bench v2 versus 90.5% for Browser Use Cloud, with no Node baseline published for comparison.
That is the honest trade: a 97% memory reduction and a much smaller dependency surface, in exchange for owning the browser edge cases yourself.
Frequently asked questions
Is the Rust version faster? The published claim is about memory and binary size, not speed. Do not assume a latency win from a language change alone; measure your own workload.
Can I copy this play for my own tool? Yes, if the hot path is narrow. Browse only needed a slice of Playwright, which is why a focused rewrite was tractable. If your tool uses the whole library, a rewrite is a product decision, not a weekend.
What breaks first after a rewrite like this? Browser updates. Chrome changes extension behaviour and CDP details on its own schedule, and nobody upstream is patching your code for you.
What to take from it
- Measure memory per unit of work, not total. Per-connector numbers tell you how many agents fit; totals hide the cost.
- Rewrite the slice you use. Replacing three functions of a 60 MB dependency is a different project from replacing the dependency.
- Budget the maintenance, not the tokens. The $60 is the cheap part. Owning browser compatibility is the expensive part.
- Keep the safety boundaries. Pairing, origin restrictions and tab-level permissions survived the rewrite for good reason.
Sources: The New Stack, “Dax Raad rebuilt his browser tool in Rust for $60. Then memory use fell 97%” by Amanda Caswell (16 November 2026), and the merged OpenCode Browse pull request referenced in that report.



0 Comments