← All open-source news
Open sourceProject

unkernel boots a real Linux kernel, compiled to WebAssembly, in a browser tab in about a second; free, Vercel-sponsored, 342 points on Hacker News

· 2 min read

unkernel compiles Linux 7.3.4 into one WebAssembly module and runs unmodified arm64 Debian and Alpine programs in a browser, in Node.js via npx, or from your own JavaScript. It is free (GPL-2.0 kernel, MIT SDK), sponsored by Vercel, and still early: no IPv6, no inbound connections, slow on heavy CPU work.

unkernel

unkernel is a new open-source project by developer Pooya Parsa (pi0), and its README credits Vercel as sponsor. It takes a real Linux kernel (Linux 7.3.4 plus the project's patches) and compiles it into a single WebAssembly module. The README's line: "A real Linux kernel, compiled to WebAssembly. It boots to a shell in less than a second." It reached 342 points on Hacker News on 28 November, after a first thread on 17 November with 244 points; the repository, created on 12 November, has about 2,800 GitHub stars.

How it differs from older "Linux in the browser" demos: tools like v86 or JSLinux emulate a whole PC, kernel included, which is faithful but slow. unkernel runs the kernel itself as compiled WebAssembly with a real memory manager, so fork, mmap, copy-on-write, threads and signals behave as on hardware. Only user programs are emulated, on an arm64 CPU emulator called kwemu with a JIT for hot code. That means unmodified arm64 Debian and Alpine packages run as they are, with no recompiling. Linux's own ext4, overlayfs, TCP/IP stack, cgroups and namespaces run inside.

The numbers are the author's own: under Node, the kernel reaches /init about 70 ms after starting; fork + exit + wait takes about 57 µs against 73 µs native and 1,178 µs under qemu-system. Sulat reports the browser demo boots Debian in 1.30 s on 4 CPUs, including a 74.2 MiB download. Engineer Farid Zakaria already uses it for trynix.dev, a page that runs Nix packages in the browser, and reports cold starts several times faster than his previous QEMU setup.

How to try it: open unkernel.dev in Chrome or Edge 137+, Firefox 153+ or Safari 27+ (it needs the JSPI WebAssembly feature; about 10 MB download, changes persist in the browser). In a terminal, npx unkernel boots Alpine and npx unkernel --distro debian boots Debian 13; --mount .:/work shares a folder and --forward 8000:80 forwards a port. For apps, npm install unkernel gives a zero-dependency TypeScript SDK. Licence: the kernel is GPL-2.0, the JavaScript SDK and page are MIT, so check the project's third-party notes before bundling it.

Limits: CPU-heavy work is "well behind native" (apk add python3 takes about 3.4 s); there is no IPv6, no UDP beyond DHCP and DNS, and no inbound connections; browser networking goes through a relay with an allow-list; there is no ptrace, so strace and gdb don't work; and a WebAssembly trap ends the session. A Hacker News commenter warned that WebAssembly alone "is not the solution to sandboxing", so don't treat it as a security boundary for untrusted code without your own review.

More news