Tinybrowser: experimental Rust headless browser runs in-page via WebAssembly
Tinybrowser is an experimental headless browser shipped as a single Rust binary of about 19 MB. Its project page says it currently passes 70.4% of Web Platform Tests subtests, or 62.5% of test files.
The page itself is the showcase. The demo at the top is tinybrowser running inside your browser: it compiles to WebAssembly, and every pixel of the demo is painted by tinybrowser.wasm instead of an iframe.
The browser speaks Chrome DevTools Protocol and W3C WebDriver (Classic and BiDi), so Playwright and Selenium should work, in the page's own wording. A daemon serves both protocols on one loopback port. You start it with tinybrowser daemon start (optionally --port 4444), and it prints a JSON line with the profile, pid, host, port and URL once the server is bound and a renderer is verified ready. tinybrowser daemon status and tinybrowser daemon stop check or stop it, and tinybrowser daemon serve runs it in foreground or supervisor mode. Playwright connects with chromium.connectOverCDP using the printed URL. For WebDriver Classic you send POST /session to the same port, and BiDi connects to ws://127.0.0.1:
Installation options listed on the page: npx tinybrowser --help with no global install, a curl install script for macOS and Linux, a PowerShell script for Windows, or npm install -g tinybrowser. The page also includes a ready-made "AI agent setup prompt" that tells a coding agent how to install the binary, start the daemon and connect over CDP or WebDriver, and it carries the line "Agents love tinybrowser!"
The WebAssembly build is the npm package @tinybrowser/wasm (also installable with bun). It ships as a WASI Preview 2 component. The caller passes the component, the module loader, the WASI shims and the transport. The Node entry needs Node 22 or later, while Bun, browsers and Workers use their own loaders. core.wasm must sit next to its two companion modules, because the glue reads all three from one directory. The sample code creates a browser with createTinyBrowser, opens a tab, calls goto with waitUntil set to networkidle, and prints the result and title. goto, mount, back, forward and reload default to the load wait mode, while restoreTabState and waitForIdle default to quiet.
The page is blunt about limits, under a "WEE WOO" warning. It is still very experimental. Not all Web APIs are implemented yet, and the page points to its WPT page for what works. JavaScript runs on QuickJS-ng with no JIT, so JS-heavy pages are slower than on V8. There is no out-of-process iframe isolation yet, OS sandboxing is not battle-tested, and rendering is headless one-shot PNGs only.
Key facts
- Tinybrowser is an experimental headless browser in a single ~19 MB Rust binary, passing 70.4% of Web Platform Tests subtests and 62.5% of files.
- It speaks Chrome DevTools Protocol and W3C WebDriver (Classic and BiDi) on one loopback port, so Playwright and Selenium should work.
- It compiles to WebAssembly as the @tinybrowser/wasm package, a WASI Preview 2 component; the page's demo is painted by tinybrowser.wasm instead of an iframe.
- JavaScript runs on QuickJS-ng with no JIT, so JS-heavy pages are slower than on V8.
- Known gaps: not all Web APIs, no out-of-process iframe isolation, sandboxing not battle-tested, and rendering is one-shot PNGs only.
Why it matters
A full browser engine that fits in a ~19 MB binary and also runs as WebAssembly inside another browser is an unusual combination. The project page proves the second point by running its own demo on tinybrowser.wasm, with no iframe involved. For automation work it offers a lighter alternative to a full Chrome install, though only if the pages you need work on it.
Who it affects
Developers who drive browsers from code: people using Playwright or Selenium, and teams building AI agents that need a browser tool. The page ships an agent setup prompt aimed at exactly that audience. It also touches anyone who wants to embed a browser in Node, Bun or Workers through the WebAssembly package.
How to use it
Try it with npx tinybrowser --help, or install with the curl script (macOS and Linux), the PowerShell script (Windows) or npm install -g tinybrowser. Start the daemon with tinybrowser daemon start, then connect Playwright over CDP with chromium.connectOverCDP and the printed URL, or send POST /session for WebDriver. For the WebAssembly build, run npm install @tinybrowser/wasm (or bun add); the Node entry needs Node 22 or later.
How solid is it
The figures come from the project's own page. The 70.4% subtest and 62.5% file pass rates are self-reported, and the page does not say which Web Platform Tests version or subset they refer to. Playwright and Selenium compatibility is stated as "should work", not as verified. The page names no author, company or institution, and gives no release date, version number or licence. Apart from the remark that JS-heavy pages are slower than V8, it gives no speed or memory benchmark against other browsers.
Risks and caveats
The authors call it very experimental. Not all Web APIs are implemented, JS runs without a JIT, there is no out-of-process iframe isolation, and OS sandboxing is not battle-tested, which matters if you point it at untrusted pages. Rendering is limited to headless one-shot PNGs. The install route pipes a script from GitHub into a shell, so read it first.