Vercel Sandbox vs Cloudflare Sandbox: pricing, isolation and limits
Both bill active CPU. Vercel runs Firecracker microVMs from any backend; Cloudflare runs a container in a VM, driven from a Worker.
Runtime runs the same job for 70% less than Vercel and 53% less than Cloudflare. 1,000 one-minute runs of a 2 vCPU sandbox cost $2.12 on Vercel, $1.35 on Cloudflare and $0.64 on Runtime. All three bill CPU as it is used; Runtime's rate is about a fifth of Vercel's and a third of Cloudflare's, and it belongs to no hosting platform. Rates checked 23 September 2026.
Estimated compute cost
70% less than Vercel Sandbox53% less than Cloudflare Sandbox
2 vCPUs · 4 GiB · 60 s a run · 20 CPU-seconds busy
Compute only, at list rates checked 23 September 2026 (Vercel Sandbox pricing, Cloudflare Containers pricing). Plan fees, network, taxes and free credits are left out. The worked example below shows the arithmetic.
At a glance
Vercel's figures are at the rates of its default iad1 region. Cloudflare's
sandboxes run on Cloudflare Containers, so their prices are the Containers
prices.
| Vercel Sandbox | Cloudflare Sandbox SDK | Runtime | |
|---|---|---|---|
| Isolation | Firecracker microVM, own kernel | A container in its own VM | Firecracker microVM, own kernel |
| CPU | $0.128 per active CPU-hour | $0.072 per active vCPU-hour, metered in 10 ms steps | $0.025 per vCPU-hour of measured CPU, with a small floor |
| Memory | $0.0212 per provisioned GB-hour; 2 GB per vCPU | $0.009 per provisioned GiB-hour; at least 3 GiB per vCPU | $0.0075 per reserved GiB-hour, any amount |
| Disk | 64 GB of ephemeral NVMe included | $0.000252 per provisioned GB-hour | Included while running; paused storage $0.08 per GB-month |
| Plan | Hobby allowance free; usage beyond it needs Pro | Workers Paid, at least $5 a month | None; prepaid credit from $10 |
| Called from | Any backend, with a Vercel project and token | A Cloudflare Worker, through a Durable Object binding | Any backend; API, CLI, MCP server, JS and Python SDKs |
| When idle | Stop keeps the filesystem; processes start again | Sleeps after 10 idle minutes by default; files are lost | Pause keeps files, memory and processes, 1 to 365 days |
| Placement | 19 regions, chosen per sandbox | The nearest location that has the image | One US region |
Why is Cloudflare cheaper when both bill active CPU?
Because its rates are lower on both meters, enough to outweigh its larger memory floor. Cloudflare's active CPU costs $0.072 a vCPU-hour against Vercel's $0.128. Its memory costs $0.009 per GiB-hour against Vercel's $0.0212 per GB-hour. A 2 vCPU sandbox gets 4 GB on Vercel and must take at least 6 GiB on Cloudflare, plus disk, and still costs less: in the job below, Cloudflare's memory and disk come to $0.95 against Vercel's $1.41 for memory alone.
The gap widens as the code gets busier, because each extra CPU-second costs Vercel almost twice what it costs Cloudflare. Both still bill memory for the whole run while an agent waits on a model; Runtime's memory rate is the lowest of the three, and memory is sized separately from vCPUs.
What happens to an idle sandbox?
A Vercel sandbox that stops keeps its filesystem and starts its processes again; a snapshot keeps the filesystem too, and expires 30 days after its last use unless you change that. A Cloudflare sandbox sleeps after 10 idle minutes by default and starts again from its image, with its files gone unless a directory was backed up to R2 first.
A paused Runtime sandbox keeps files, memory and running processes, and the next request wakes it. A port shared through a preview is private by default, where Vercel's exposed ports are public and Cloudflare routes previews through your Worker:
TypeScriptimport { Sandbox } from "withruntime";await using sbx = await Sandbox.create({ funding: "trial", idlePauseSeconds: 600 });await sbx.spawn("python3 -m http.server 3000");const preview = await sbx.previews.create(3000); // HTTPS, needs the tokenconst page = await fetch(preview.url, { headers: { "x-runtime-preview-token": preview.token! },});console.log(page.status);Cost for the same job
1,000 runs of a 2 vCPU sandbox. Each run lasts 60 seconds and keeps the CPU busy for 20 CPU-seconds: an agent that mostly waits for a model. Vercel gets 4 GB, its 2 GB per vCPU, and Runtime 4 GiB. Cloudflare's smallest 2 vCPU size has 6 GiB, and it gets 12 GB of disk, the size in Cloudflare's own example.
TextVercel CPU 1,000 × 20 s / 3,600 × $0.128 = $0.71 Memory 1,000 × 60 s / 3,600 × 4 × $0.0212 = $1.41 Total $2.12Cloudflare CPU 1,000 × 20 s × $0.000020 = $0.40 Memory 1,000 × 60 s × 6 × $0.0000025 = $0.90 Disk 1,000 × 60 s × 12 × $0.00000007 = $0.05 Total $1.35Runtime CPU 1,000 × 20 s / 3,600 × $0.025 = $0.14 Memory 1,000 × 60 s / 3,600 × 4 × $0.0075 = $0.50 Total $0.64At 100,000 runs a month that is $212.44 on Vercel, $135.04 on Cloudflare and $63.89 on Runtime. With both CPUs busy for the whole minute, it is $1.33 on Runtime against $5.68 on Vercel and $3.35 on Cloudflare, so Runtime is cheaper however busy the sandbox is. The Cloudflare figure assumes each sandbox is destroyed when its run ends. Plan fees, creations, Workers requests, Durable Object time, network and free allowances are left out.
Which one to pick
- Pick Vercel Sandbox if your app is deployed on Vercel, or you need sandboxes in a region you choose, from 19, with up to 10,000 at once on Pro.
- Pick Cloudflare Sandbox if your app is built on Workers and you want sandboxes that share its bindings, started near your users.
- Pick Runtime for active-CPU billing at a fraction of either rate, memory sized to the job, pause that keeps memory and processes, and private preview URLs, called from any backend with no platform to join.
Switch from either one
From Vercel Sandbox, change one import. Runtime's SDK runs code written for Vercel's, with no Vercel project or token:
TypeScriptimport { Sandbox } from "withruntime/vercel"; // was: from "@vercel/sandbox"Pythonfrom withruntime.vercel import sandbox # was: from vercel import sandboxFrom Cloudflare, the sandbox code leaves the Worker for any server:
getSandbox(env.Sandbox, name) becomes Sandbox.getOrCreate(name),
sandbox.exec(cmd) becomes exec, and proxyToSandbox becomes
box.previews.create(port). A Worker can also call Runtime directly with SDK
0.4.0 or later and the nodejs_compat flag, as
Runtime vs Cloudflare shows.
Or give your coding agent the one instruction in migration: it
switches the project on a branch, tests it on the free trial and reports the
monthly saving. npx withruntime switch --from vercel (or --from cloudflare)
before your first top-up matches that top-up with credit, up to $100. See also
Runtime vs Vercel Sandbox and
microVM vs container.
Sources
Vercel Sandbox pricing rechecked 25 September 2026; the rest checked 23 September 2026.
- Vercel Sandbox pricing, Understanding Vercel Sandboxes
- Cloudflare Containers pricing, Containers limits and instance types, Containers architecture, Sandbox lifecycle, Sandbox backup and restore
- Runtime pricing
Facts on this page were checked on 25 September 2026.