What is the best alternative to Modal Sandboxes?
It depends on whether you need GPUs next to your sandboxes. For agents that mostly wait on a model and need no GPU, Runtime is the cheapest: $0.64 for the job below, against $3.97 on Modal. It also needs no request to size, and each sandbox has its own Linux kernel. If GPUs matter, stay on Modal or pick Daytona, which sells GPU sandboxes too. Pick Cloudflare Sandbox if your app runs on Workers. Pick Northflank when both CPUs run flat out.
Why do teams move sandboxes off Modal?
Modal is a platform for functions, GPUs and jobs, and its sandboxes follow the same rules. For agent code that mostly waits, those rules cost money:
- The request is the bill. Modal charges whichever is higher: the CPU and memory requested, or the amount used. A sandbox cannot use more than it requested, so in practice you pay for the request for the whole run. Runtime has no request to size. It measures use, with a floor of a twentieth of a vCPU.
- Rates are per physical core. $0.1419 per core-hour buys 2 vCPUs, about $0.071 per vCPU-hour, nearly three times Runtime's $0.025. Memory is $0.0240 per GiB-hour against $0.0075.
- gVisor, not a separate kernel. Modal's sandboxes run under gVisor, a user-space kernel that intercepts system calls. Runtime's sandboxes run in Firecracker microVMs, each with its own Linux kernel behind hardware virtualization.
- An App comes first. Called from outside Modal, a sandbox needs a Modal
App to belong to.
Sandbox.create()on Runtime needs nothing set up. - Networking and sign-in sit on higher plans. On 25 October 2026, Modal listed custom domains and a static IP proxy with Team, and single sign-on with audit logs on Enterprise. Runtime has no plan tiers. Paid accounts get custom domains and dedicated outbound addresses, and single sign-on and the audit log are free.
- Plans shape the account. Modal's pricing page, read on 26 October 2026, gives Starter 3 seats and 100 containers at the same time. Team costs $250 a month. Runtime has no plan: credit from $10, and 100 sandboxes at the same time on a paid account.
Which alternatives are cheapest?
Sixteen providers, one workload: 1,000 runs at 60 seconds each, on 2 vCPU and 4 GiB. The code keeps the CPU busy for only 20 CPU-seconds per run. On Modal, that is one physical core, requested for the full minute, which puts it fourteenth. Pricing shows every row's sum. None of them counts plan fees, storage, network, credits or negotiated terms.
| # | Provider | Isolation | CPU billed on | 1,000 runs |
|---|---|---|---|---|
| 1 | Runtime Cloud | Firecracker microVM, own kernel | Measured CPU, with a small floor | $0.64 |
| 2 | Northflank | microVMs for CPU work, gVisor for GPU work | Allocated vCPUs | $1.11 |
| 3 | Cloudflare Sandbox (2 vCPU, 6 GiB, 12 GB disk) | A container in its own VM | Active CPU | $1.35 |
| 4 | Prime Sandboxes (5 GiB disk) | microVM, own guest kernel | Allocated vCPUs while running | $1.52 |
| 5 | Fly Machines, performance-2x with 4 GB |
Firecracker microVM | The machine's size while started | $1.53 |
| 6 | Morph, 2 MCUs | Full virtual machines | The machine's size in MCUs | $1.67 |
| 7 | Vercel Sandbox, iad1 (4 GB) |
Firecracker microVM, own kernel | Active CPU | $2.12 |
| 8 | Freestyle (32 GiB disk) | Full Linux virtual machines | Allocated vCPUs | $2.25 |
| 9 | Fly Sprites (4 GB in use) | Firecracker microVM | Measured CPU | $2.40 |
| 10 | CodeSandbox SDK, a Nano VM | Firecracker microVM | The VM's size, by the minute rounded up | $2.48 |
| 11 | E2B | Firecracker microVM, own kernel | Allocated vCPUs | $2.76 |
| 12 | Daytona | Containers by default; VM class separate | Allocated vCPUs | $2.76 |
| 13 | Blaxel (4 GB) | Lightweight virtual machines | Included with memory, active time | $3.45 |
| 14 | Modal Sandboxes (1 physical core), the one you are replacing | gVisor, a user-space kernel | Requested or used, whichever is higher | $3.97 |
| 15 | AWS Lambda MicroVMs, Arm | Firecracker microVM | Baseline vCPUs while running | $4.20 |
| 16 | Runloop, a MEDIUM devbox |
microVM, with a container inside | Allocated CPUs while running | $5.33 |
Cost for the same job
Runtime and Modal, with E2B (an allocation-billed microVM) and Vercel (an active-CPU microVM) for reference:
- CPU
- 1,000 × 20 s / 3,600 × $0.025
- $0.14
- Memory
- 1,000 × 60 s / 3,600 × 4 × $0.0075
- $0.50
- CPU
- 1,000 × 60 s × 1 core × $0.00003942
- $2.37
- Memory
- 1,000 × 60 s × 4 × $0.00000667
- $1.60
- CPU
- 1,000 × 60 s / 3,600 × 2 × $0.0504
- $1.68
- Memory
- 1,000 × 60 s / 3,600 × 4 × $0.0162
- $1.08
- CPU
- 1,000 × 20 s / 3,600 × $0.128
- $0.71
- Memory
- 1,000 × 60 s / 3,600 × 4 × $0.0212
- $1.41
When the load rises so both CPUs are busy for the whole minute, the four totals become $1.33 on Runtime, $3.97 on Modal, $2.76 on E2B, and $5.68 on Vercel. Modal's line does not change, because the request was already billed in full. A smaller request lowers it, but it also caps what the sandbox can use. At 100,000 runs a month, the waiting version costs $63.89 on Runtime and $396.60 on Modal.
What a Modal user gains from each alternative
1. Northflank: allocation at the lowest list price
Northflank bills what a sandbox holds, as Modal effectively does, but at $0.01667 per vCPU-hour and $0.00833 per GB-hour. It is cheaper than Runtime only when both CPUs run flat out, $1.11 to $1.33. GPU work runs under gVisor, as on Modal. It can deploy into your own AWS, GCP or Azure account.
2. Cloudflare Sandbox: active CPU, but only from a Worker
Charges start when the CPU works, at $0.072 per vCPU-hour. That suits waiting agents better than Modal's request billing. Memory is at least 3 GiB per vCPU. You call it from a Worker on the Workers Paid plan. Public-beta filesystem snapshots keep saved files. Memory and processes restart after a stop.
3. Fly Machines: the whole VM for under half Modal's price
A performance-2x with 4 GB costs $0.0916704 an hour in iad, busy or idle,
or $1.53 for this job. Fly.io runs them in 17 regions. A volume is needed for
files to outlast a Machine.
4. Morph: branching full machines
Morph charges $0.05 per MCU-hour and needs 2 MCUs here. Its Infinibranch takes a running machine, memory and all, and branches it into hundreds of copies.
5. Vercel Sandbox: a microVM that bills active CPU
$0.128 per active CPU-hour and $0.0212 per GB-hour in iad1. For this waiting
job it costs $2.12, under Modal. With the CPUs busy it climbs to $5.68, above.
It covers 19 regions and 10,000 concurrent sandboxes on Pro.
6. CodeSandbox SDK: fixed sizes, minute billing
A Nano VM with 2 cores and 4 GB is $0.1486 an hour in credits, rounded up to the minute. The free Build plan runs 10 VMs at the same time, and Scale raises that for $170 a month.
7. E2B: microVMs billed by allocation
$0.0504 per allocated vCPU-hour and $0.0162 per GiB-hour, so the job costs $2.76 whether the code works or waits. Hobby sessions last an hour. Pro, at $150 a month, allows 24. The runtime is open source under Apache-2.0.
8. Daytona: GPUs outside Modal
If GPUs are what holds you to Modal, Daytona sells GPU sandboxes too, plus Windows machines and regions in the US and the EU. Its rates match E2B's, and its default sandbox is a container.
9. Blaxel: pay for active memory only
$0.0000115 per GB-second while a sandbox is active, with cores set by memory. Standby begins by itself when connections close, and a sandbox wakes in about 25 ms.
10. Fly Sprites: measured CPU from Fly.io
$0.0385 per measured CPU-hour and $0.021875 per GB-hour of memory in use, which makes $2.40 for the job. A Sprite puts itself to sleep and keeps a 100 GB disk.
11. Runloop: the one dearer than Modal here
$0.108 per CPU-hour, $0.0252 per GB-hour and a disk charge make $5.33. The reason to pick it is evaluation work: it evaluates models on your own workload and generates RL rollouts on its devboxes.
Runtime Cloud
For sandbox work, Runtime costs 84% less than Modal and gives each sandbox a kernel of its own. The reference job, 1,000 one-minute runs of a 2 vCPU, 4 GiB sandbox, costs $0.64 on Runtime and $3.97 on Modal. Runtime comes first in the table above. Over 100,000 runs a month, the gap is $333. Modal bills the CPU a sandbox asked for even while it idles. Runtime bills the CPU it spent. Rates checked 25 October 2026.
Each sandbox is a Firecracker microVM, billed $0.025 per vCPU-hour of CPU actually used and $0.0075 per reserved GiB-hour. There is no App to create. One call returns a running sandbox. Pausing keeps memory and processes while you have credit, or for 1 to 365 days you set. Forks start 1 to 100 running copies from one sandbox.
You can try it without setting anything up. Run npx withruntime login and
start free. The migration guide and the next section show
what changes in Modal code.
How to switch from Modal
Modal's calls have direct counterparts. modal.Sandbox.create(app=...) becomes
Sandbox.create(), sb.exec(*args) becomes exec, Sandbox.from_name becomes
Sandbox.getOrCreate(name), and idle_timeout becomes idlePauseSeconds. The
App lookup goes away.
Modal:
Pythonimport modalapp = modal.App.lookup("my-app", create_if_missing=True)sb = modal.Sandbox.create(app=app)process = sb.exec("python3", "-c", "print(sum([125, 250, 375]))")print(process.stdout.read())sb.terminate()Runtime:
Pythonfrom withruntime import Sandboxwith Sandbox.create() as box: box.files.write("/workspace/invoice.py", "print(sum([125, 250, 375]))\n") print(box.exec("python3 /workspace/invoice.py", check=True).stdout)Rather not port it by hand? Give a coding agent the instruction in migration. It rewrites the Modal calls on a branch, proves them without credit, and tells you the monthly saving. Credit you add within 30 days of signing up is matched, up to $1,000 in total. Related reading: E2B vs Modal, Daytona vs Modal, Modal vs Vercel Sandbox and Firecracker vs gVisor.
Sources
Cloudflare sandbox lifetime, snapshot behavior checked 25 October 2026. Rival rates were checked 25 October 2026. Modal's pricing page was read again on 26 October 2026 for its plans and limits.
Runtime pricing and the Modal comparison
Facts on this page were checked on 26 October 2026.