Lightpanda: A Zig-Written Headless Browser That Cuts Memory 16x and Runs 9x Faster Than Chrome
Running hundreds of JavaScript-heavy pages without paying for a full Chrome process per page is now possible with a browser that uses ~16x less memory and runs ~9x faster. But the AGPL-3.0 license and lack of native Windows support mean production adoption hinges on a compatibility check against your exact target sites.
Lightpanda replaces the standard approach of running full Headless Chrome instances for scraping or agent browsing. Written from scratch in Zig, it keeps only the pipeline needed to get page content: HTTP loading via libcurl, HTML parsing via html5ever, a DOM tree, and V8 to execute JavaScript. No rendering, no GPU, no user-facing features.
Official benchmarks on AWS EC2 m5.large show 123MB peak memory for 100 pages versus 2GB for Headless Chrome, and 5 seconds versus 46 seconds. The trade-off is web compatibility: the project publishes daily Web Platform Tests results, but you must verify your own target sites. It supports CDP and WebDriver BiDi, so Puppeteer and Playwright scripts can point at it with minimal changes.
A standout feature is PandaScript: an agent exploration session can be saved as a deterministic JavaScript script and replayed with `lightpanda run` at zero token cost. Four commands cover different needs: `fetch` for one-off scraping, `serve` as a CDP/BiDi server, `mcp` for MCP clients, and `agent` for interactive natural-language browsing. The AGPL-3.0 license, missing native Windows support, and glibc requirements on Linux are the main boundaries.
By dropping the rendering pipeline, Lightpanda trades broad web compatibility for an order-of-magnitude resource saving; the daily public WPT results let users verify what breaks instead of trusting marketing claims.
The PandaScript approach effectively separates the expensive LLM-driven exploration step from a cheap deterministic replay step, which changes how teams think about token spend on repeated browser tasks.
The 16x memory reduction relies on both removing the renderer and Zig's explicit memory management; the same gain would be hard to achieve with a thin wrapper around Chromium.