Lifo vs CodeSandbox SDK

Together AI acquired CodeSandbox in December 2024, and the CodeSandbox SDK is now deprecated in favor of Together Sandbox: virtual machines on Together's infrastructure, billed per vCPU-hour and GiB-hour. Lifo runs code, dev servers and previews in the user's browser tab, so sessions cost nothing. Here is how they compare for previews and agent sandboxes.

Checked against CodeSandbox SDK's own docs and pricing on 29 November 2026·Sources

At a glance

What CodeSandbox SDK is

The CodeSandbox SDK created cloud sandboxes programmatically. After Together AI acquired CodeSandbox, its successor is Together Sandbox (the together-sandbox SDK), which "runs your code in isolated runtime environments": each sandbox is a virtual machine on Together's infrastructure, created from a Docker image or build context. Together's docs mark the CodeSandbox SDK as deprecated.

What Lifo is

A small Linux-like operating system written in TypeScript. It boots in milliseconds inside the user's browser tab or a Node.js process: a filesystem, a bash-like shell, processes, ports and a Node.js runtime, with no VM or emulator underneath. Open source under MIT, with Lifo Cloud for apps that must keep running.

Lifo and CodeSandbox SDK side by side

Lifo compared with CodeSandbox SDK
Where code runsThe user's browser tab (in the page or a Web Worker), or your Node.js process. Lifo Cloud, in preview, keeps a box running on Lifo's servers.A virtual machine on Together AI's infrastructure. The legacy CodeSandbox SDK ran Firecracker VMs.
IsolationBoxes are kept apart from each other, not from the page or process that runs them. Untrusted code needs a Web Worker on a separate origin. Security docsA VM per sandbox.
What runsA Node.js compatibility layer with npm, Vite, Express, Expo previews, git, a bash-like shell, Python (Pyodide), Postgres (PGlite) and a Supabase-compatible backend. No Linux binaries or native addons.Anything in a public Docker image or a Docker build context, from 0.1 to 16 CPU cores with 1 to 8 GB per core. Dev Containers and Docker Compose aren't interpreted in the new SDK.
Cold startAbout 27 ms in a browser tab, under 1 ms in Node.js (measured with the repo's bench/).Together states 2.7 s cold starts (p95), 500 ms snapshot resumes (p95) and VM cloning in under 1 second. Add the network round trip.
Cost model$0 in the browser: the user's device does the work. Lifo Cloud bills by usage: a Lite box is $0.005 an hour while awake.$0.0446 per vCPU-hour and $0.0149 per GiB-hour of RAM. Together's pricing page lists no free credit for sandboxes.
Open sourceYes. @lifo-sh/core, @lifo-sh/ui and the CLI are MIT licensed. Lifo Cloud's servers are closed source.The together-sandbox SDK is MIT licensed. The VMs are a hosted service.
In your productAn npm package (@lifo-sh/core) plus terminal, file explorer and preview components (@lifo-sh/ui), or an iframe of the playground.Python and TypeScript SDKs and a CLI, called from your backend; sandboxes must be enabled for your organization. Preview URLs are "coming soon" in the new SDK, and all ports are public.
OfflineYes, once loaded, apart from what needs the network (npm installs, git push).No, it's a cloud service.
Session lengthAs long as the tab is open. A Lifo Cloud box sleeps when idle and wakes on the next request.Runs until you terminate it or its TTL (counted from creation) ends. Ephemeral by default; snapshot on termination to keep state. No automatic hibernation in the new SDK.

CodeSandbox SDK's column comes from its official docs and pricing pages, checked on 29 November 2026; prices change, so follow the CodeSandbox SDK pricing page for current numbers.

What changed with the move to Together

Together AI announced its acquisition of CodeSandbox on 12 December 2024. Together's docs now describe the CodeSandbox SDK as deprecated, with together-sandbox as its successor. Its migration guide lists what the new SDK drops: using the SDK from the browser, waking a sandbox on an HTTP request, private previews, live resizing and Dev Containers. Preview URLs are marked as coming soon.

If you used the CodeSandbox SDK for live previews of generated apps, those changes matter. That's the job Lifo does in the browser: the dev server runs in the user's tab and the preview is served from your own origin.

How they run

Together Sandbox starts a virtual machine on Together's infrastructure from a Docker image, with up to 16 CPU cores. Together states 2.7 s cold starts and 500 ms snapshot resumes at p95, and VM clones in under a second. It runs whatever the image contains, including Linux binaries.

Lifo is a Unix-like system written in TypeScript that boots in about 27 ms in the user's browser tab or your Node.js process. It runs Node.js, npm, Vite, Express, Expo and Expo Router previews, git, Python through Pyodide, Postgres through PGlite and a Supabase-compatible backend. It can't run Linux binaries, and it isn't a security boundary.

What it costs

Together lists sandboxes at $0.0446 per vCPU-hour and $0.0149 per GiB-hour of RAM, with no free credit shown. As an illustration, a 2 vCPU, 4 GiB sandbox running for 30 minutes costs about $0.07.

Lifo in the browser costs $0 per session, so previews for every user don't add to your bill. Lifo Cloud, in preview, bills a Lite box at $0.005 an hour while it's awake and nothing while it sleeps.

Security

A VM per sandbox is a strong boundary, and Together positions sandboxes for running untrusted or model-generated code.

A Lifo Sandbox shares the JavaScript realm of the page that runs it. For untrusted code in the browser, use a WorkerSandbox on a separate origin, or send the work to a VM. The security docs show what each setup stops.

Which one to choose

Choose CodeSandbox SDK when

  • You need Linux binaries, custom Docker images or up to 16 cores per sandbox.
  • The code isn't trusted and needs a VM around it.
  • You already use Together AI for models and want sandboxes on the same account.
  • You run reinforcement learning rollouts or agent tool calls on servers.

Choose Lifo when

  • You want live previews of generated web or mobile apps without a VM per user.
  • You want the preview served privately from your own origin, and the SDK to run in the browser.
  • Start time matters: a box is ready in about 27 ms.
  • You want an MIT runtime with no sales process to get started.

Using both. Run previews and agent shells in the tab with Lifo, and use a VM sandbox for the steps that need Linux binaries or isolation.

Questions

What happened to the CodeSandbox SDK?
Together AI acquired CodeSandbox in December 2024. Together's docs now mark the CodeSandbox SDK as deprecated and name the together-sandbox SDK as its successor.
How much does Together Sandbox cost?
Together's pricing page lists sandboxes at $0.0446 per vCPU-hour and $0.0149 per GiB-hour of RAM, checked on 29 November 2026. Check it for current numbers.
Is Lifo a CodeSandbox alternative?
For running and previewing JavaScript apps in the browser, yes: Lifo runs the dev server, a shell, git and a database in the user's tab, and its playground is embeddable. For Linux VMs with any Docker image, Together Sandbox is the closer fit.
Can Lifo run Docker images?
Not in the browser: a Lifo box runs JavaScript and WebAssembly, not Linux binaries. Lifo Cloud is adding Full boxes, real Linux containers for projects with a Dockerfile or native modules; they're marked coming soon on the pricing page.
All comparisons

Sources

Facts about CodeSandbox SDK come only from its own website, docs and pricing pages. If something here is out of date, open an issue and we'll fix it.

See it run in your browser

A shell, Node.js, npm and a dev server, booted in the tab. No account and no server.