Lifo
MIT Linux-like OS written in TypeScript (kernel, filesystem, bash-like shell, processes and a Node.js layer) that boots inside a browser tab or Node.js process to run agent-generated apps and shell tools. A TypeScript reimplementation of a Unix userland for running agent-generated apps in a browser tab or Node.js process; its isolation is JavaScript-level, not a security boundary, so untrusted code needs a worker on a separate origin or a real sandbox.
Overview
Lifo is "a small Linux-like operating system written in TypeScript": a kernel, a POSIX-like virtual filesystem, a bash-like shell with 60+ commands, processes, ports and a Node.js compatibility layer, with no VM or emulator underneath. The same @lifo-sh/core package runs in a browser tab, in a Node.js process and from the lifo-sh CLI, and a box moves between them as a snapshot. Real npm, Vite, Express and Expo run in it, Postgres comes through PGlite, git through isomorphic-git, and python3 is CPython on WebAssembly. It cannot run native Linux binaries or native npm addons, and long computations share one thread with the page. The website pitches it as "Your agent builds it. Lifo runs it." and the pricing page lists "AI agent sandboxes"; the docs describe giving a model one bash tool backed by box.commands.run() and an in-tab agent package that runs WebLLM.
Isolation is the main caveat, and the vendor states it plainly: programs in a box are kept apart from each other, but their JavaScript runs in the same realm as the page or Node.js process that created the box, so it can reach the page's DOM, cookies and storage or the real process, filesystem and network. The docs say "a box is not a security boundary" and recommend WorkerSandbox, ideally served from a different origin inside a sandboxed iframe, for code you do not trust, or a cloud sandbox when you need real isolation. The runtime is MIT; Lifo Cloud, whose servers are closed source, has published pricing, but the docs label cloud boxes a preview that is not yet available on lifo.sh. The project is pre-1.0 (0.10.x) and is built by the team behind RapidNative, which the website names as its production user.
Notable
- @lifo-sh/core and lifo-sh 0.10.36 published to npm on 17 November 2026; 565 GitHub stars at verification.
- Vendor benchmark: ~27 ms cold start in a tab and ~0.3 MB gzipped runtime, against ~6.6 s measured for WebContainers in the same browser.
- Docs: cloud boxes are in development and lifo cloud reports the cloud "isn't available yet", although pricing is published.
Lifo specifications
| Attribute | Details |
|---|---|
| Isolation | Language-level: a Unix-like system and Node.js APIs reimplemented in TypeScript, running in the same JavaScript realm as the page or Node.js process that created the box. Boxes are kept apart from each other but not from their host; the docs say "a box is not a security boundary". WorkerSandbox moves a box into a Web Worker, optionally on a separate origin, to rely on the browser's isolation |
| Deployment | Open-source project · Self-hostable |
| Open source | Yes (MIT) |
| SDKs and interfaces | JavaScript/TypeScript, CLI |
| Cold start (vendor claim) | Docs (vendor measurement with the repo's bench/ in headless Chromium): about 27 ms to a box with node and npm in a browser tab (26 ms to load, under 1 ms to boot) and about 0.5 ms in Node.js |
| Max session length | Not documented |
| Persistence | Files live in memory; in a browser, persist: true saves the filesystem to IndexedDB (one store per origin) and restores it on the next visit, otherwise every box starts clean and a tab's box ends when the tab closes. Snapshots are .tar.gz files of every file plus the working directory and environment, exported and imported from the browser, Node.js or the lifo-sh CLI |
| GPU | Not documented for programs in a box; the optional lifo-pkg-agent runs a WebLLM model on the visitor's GPU through WebGPU |
| Networking | No raw sockets: programs make HTTP(S) and WebSocket requests through the host's fetch and WebSocket, under the browser's CORS rules. Servers in a box are reachable from the page, an iframe preview served by a service worker, or a public URL via lifo tunnel, not from other apps on the machine. Cloud boxes (preview) get a public URL and outbound TCP |
| Pricing | Free under MIT in the browser, Node.js and the terminal; browser execution is never metered. Lifo Cloud (cloud boxes are labelled a preview in the docs): Hobby $0 with $5 of usage a month; Pro $20/month including $20 of usage; Enterprise custom. Rates: Lite box $0.005 per awake hour; Full box (coming soon) $0.08, $0.16 or $0.32 per hour for S, M or L; headless browser $0.05 per browser hour; tools such as ffmpeg $0.10 per CPU hour; storage $0.15 per GB-month; data out $0.06 per GB |
| Free tier | Free and unmetered in the browser or Node.js; Lifo Cloud Hobby includes $5 of usage a month with no card |
| Compliance | Not documented |
| Regions | Not documented |
| Company headquarters | Not documented |
Facts from Lifo’s public documentation, verified November 18, 2026. Performance numbers are vendor claims.
Strengths and trade-offs
Strengths
- You want agent-generated web apps to run in the user's own tab with no per-session server cost.
- You need a disposable shell, filesystem, node and npm for an agent tool inside a Node.js process.
- You want the same box in the browser, Node.js and the terminal, moved between them as a snapshot.
- You want an MIT runtime with no license fees or session caps.
Trade-offs
- Not a security boundary: code in a box can reach the page or Node.js process that runs it unless you add a Web Worker and a separate origin.
- No native Linux binaries or native npm addons; Node.js is a compatibility layer and the shell is bash-like, not bash.
- Processes share one JavaScript thread, so long computations block other programs and the page.
- Lifo Cloud is priced but labelled a preview and not yet available; pre-1.0 releases.
Good fit for: Running agent-generated web apps, previews and a bash tool for agents in the user's own browser tab or a Node.js process, where the code is trusted or the browser provides the isolation.
How Lifo compares
| Sandbox | Company HQ | Isolation | Open source | Self-host / BYOC | Cold start (vendor) | Max session | Snapshots / pause | GPU | SDKs |
|---|---|---|---|---|---|---|---|---|---|
| Lifo | Not documented | In-process JS runtime | Yes | Yes / No | ~27 ms in a tab (claim) | Not documented | Yes / Not documented | Not documented | JavaScript/TypeScript, CLI |
| WebContainers | United States | Browser tab (WebAssembly) | No | Not documented / Not documented | ms (claimed) | Not documented | Not documented / Not documented | No | JavaScript/TypeScript |
| just-bash | United States | In-process interpreter | Yes | Yes / No | Not documented | Not documented | Not documented / No | No | JavaScript/TypeScript |
| Pyodide | Not documented | CPython in Wasm | Yes | Yes / No | Not documented | Not documented | Not documented / Not documented | Not documented | JavaScript/TypeScript, Python |
| Wasmer | United States | Wasm sandbox | Yes | Yes / Not documented | Not documented | Not documented | Not documented / Not documented | Not documented | CLI, JavaScript/TypeScript, Python, Rust, Swift |
| E2B | United States | Firecracker microVM | Yes | Yes / Yes | Not documented | 1 h / 24 h (Pro) | Yes / Yes | No | Python, JavaScript/TypeScript |
Head-to-head: Lifo vs WebContainers
Frequently asked questions
What is Lifo?
How does Lifo isolate code?
Is Lifo open source?
How much does Lifo cost?
Does Lifo support snapshots or pause and resume?
What are the alternatives to Lifo?
Sources
- lifo.sh
- lifo.sh/pricing
- lifo.sh/docs
- lifo.sh/docs/understand/why
- lifo.sh/docs/understand/security
- lifo.sh/docs/understand/limitations
- lifo.sh/docs/understand/performance
- lifo.sh/docs/understand/tab-and-cloud
- lifo.sh/docs/build/files
- lifo.sh/docs/build/agents
- lifo.sh/docs/agents
- lifo.sh/docs/cloud/boxes
- lifo.sh/docs/reference/cli
- lifo.sh/license
- github.com/lifo-sh/lifo
- registry.npmjs.org/@lifo-sh/core
Check before you rely on it. Products change quickly, and this page reflects public documentation as of November 18, 2026. Confirm anything that matters in the provider’s own documentation.
Cite this page
Agent Sandboxes. (2026). Lifo. agentsandboxes.org. Last reviewed November 18, 2026. https://agentsandboxes.org/sandboxes/lifo/