Vercel Sandbox vs Railway
Vercel Sandbox runs untrusted code in Firecracker microVMs across 19 regions; its persistent sandboxes resume from a snapshot across 24-hour sessions. Railway is an app platform that added sandbox VMs in 2026. They sit next to your apps and databases, and Railway destroys them after an idle timeout unless you take a checkpoint first.
The companies and products
Vercel Sandbox
Vercel is a cloud platform for web apps and agents, and Vercel Sandbox is its product for running untrusted or agent-written code in isolated Linux microVMs.
Each sandbox is a Firecracker microVM with its own kernel, started from a Vercel image, your own OCI image, or a saved snapshot. You drive it with the JavaScript or Python SDK or the sandbox CLI: run commands, move files, open ports, fork sandboxes, mount Drives and set network rules. Sandboxes are persistent by default: each stop saves the filesystem, and the next session resumes from it. Vercel aims it at code interpreters, app builders, test runs, developer environments and agent workspaces. Its docs suggest a VM for 24/7 hosting.
- Default image
- Ubuntu; the universal image adds Node.js 24, Python 3.14, Bun, and Claude Code, Codex, OpenCode and pi preinstalled
- Longest session
- 24 hours on Pro and Enterprise, 45 minutes on Hobby; a persistent sandbox resumes from its last snapshot with no cap on total lifetime
- Biggest sandbox
- 8 vCPU / 16 GB on Pro, 32 vCPU / 64 GB on Enterprise
Railway
Railway is a cloud platform for deploying web apps, servers and databases. It also sells Sandboxes and Cloud Agents.
Railway's main product is app hosting: you deploy services and databases as containers on its own hardware. In 2026 it added Sandboxes: isolated Linux VMs that you create from the CLI or a TypeScript SDK, run commands in and destroy. It also added Cloud Agents: a personal VM for a coding agent that keeps its disk and sleeps or wakes. Cloud Agents are in Priority Boarding, and breaking changes may occur. Railway suits teams that already host on Railway and want sandboxes next to their apps.
Which use cases each one fits
For each use case, Battleships prices every sandbox provider on the same workload and sorts them from the cheapest monthly bill up. “27th cheapest of 336” means 26 of the other 335 providers run that workload, with every feature it needs, for less. “With limits” means the provider runs it but misses something, so it is listed after every full match. Open a use case for its whole ranking and what each provider misses.
| Use case and its workload | Vercel Sandbox: price rank | Railway: price rank | boat: price rank |
|---|---|---|---|
| Software factory 100 at once · 4 vCPU / 8 GB · 2,200 sessions of 8 h a month Railway fits with your own setup: keep work in checkpoints or a Cloud Agent, and install Docker and a desktop yourself. On Vercel you install a browser yourself, and processes start again every 24 hours. | 259th of 365, with limits $3,351 a month | 28th cheapest of 365 $1,481 a month | 5th cheapest of 365 $634 a month |
| Always-on AI employees 50 machines 24/7 · 2 vCPU / 4 GB Railway fits an always-on assistant with the idle timeout set to 0 or a Cloud Agent, and memory bills the whole time. On Vercel a persistent sandbox resumes across 24-hour sessions, and an onResume hook restarts your processes. | 75th of 361, with limits $3,657 a month | 21st cheapest of 361 $3,977 a month | 6th cheapest of 361 $657 a month |
| Code interpreter bursts 100 at once · 1 vCPU / 2 GB · 200,000 sessions of 1 min a month Both fit short code bursts and bill CPU only while it is used. Railway publishes no limit on starts per minute. | 27th cheapest of 336 $216 a month | 42nd cheapest of 336 $413 a month | 189th of 336, with limits $2,000 a month |
| Sandboxes for your users 300 at once · 2 vCPU / 4 GB · 30,000 sessions of 23 min a month Vercel Sandbox fits cleanly, with up to 10,000 sandboxes at once on Pro. Railway allows 100 sandboxes per environment on Pro, so 300 at once means several environments or an Enterprise limit. | 25th cheapest of 349 $1,267 a month | 46th of 349, with limits $290 a month | 3rd cheapest of 349 $209 a month |
| RL rollouts 1,000 at once · 2 vCPU / 4 GB · 1,000,000 sessions of 3 min a month Vercel Sandbox fits many short parallel rollouts thanks to its high concurrency. Railway's per-environment cap makes it a compromise. | 7th cheapest of 349 $15,761 a month | 84th of 349, with limits $4,450 a month | 39th of 349, with limits $2,000 a month |
| Agent evals 250 at once · 4 vCPU / 8 GB · 15,000 sessions of 20 min a month | 81st cheapest of 359 $1,508 a month | 113th of 359, with limits $364 a month | 10th cheapest of 359 $200 a month |
| CI runners 40 at once · 8 vCPU / 16 GB · 6,000 sessions of 12 min a month Both fit CI runners. Vercel documents Docker inside; Railway's sandbox docs do not mention it, so you install and verify it yourself. | 112th cheapest of 374 $1,144 a month | 116th cheapest of 374 $1,210 a month | 2nd cheapest of 374 $86 a month |
| 24/7 dev boxes 1 machine 24/7 · 4 vCPU / 8 GB Railway's Cloud Agents keep a disk and sleep or wake; they are in Priority Boarding. On Vercel the files stay across sessions, but running processes start again every 24 hours. | 283rd of 371, with limits $145 a month | 69th cheapest of 371 $89 a month | 19th cheapest of 371 $26 a month |
| Computer-use agents 50 at once · 4 vCPU / 8 GB · 20,000 sessions of 15 min a month Neither includes a desktop. On Railway you can add Xvfb and noVNC with the template builder and publish the port. On Vercel you install Chromium and agent-browser yourself or connect an external browser. boat includes a 60 fps desktop. | 263rd of 367, with limits $952 a month | 47th cheapest of 367 $407 a month | 7th cheapest of 367 $200 a month |
| Browser-use agents 50 at once · 2 vCPU / 4 GB · 30,000 sessions of 10 min a month | 100th of 356, with limits $486 a month | 53rd of 356, with limits $93 a month | 7th cheapest of 356 $200 a month |
| Scraping & bots (startup scale) 50 at once · 1 vCPU / 2 GB · 100,000 sessions of 3 min a month | 109th cheapest of 343 $468 a month | 65th cheapest of 343 $570 a month | 6th cheapest of 343 $90 a month |
| Mass scraping & bots (undetectable) 1,000 at once · 1 vCPU / 2 GB · 3,000,000 sessions of 2 min a month | 234th of 327, with limits $9,960 a month | 111th of 327, with limits $2,988 a month | 73rd of 327, with limits $1,800 a month |
| Parallel red teaming 200 at once · 2 vCPU / 4 GB · 5,000 sessions of 30 min a month | 31st cheapest of 351 $554 a month | 71st of 351, with limits $574 a month | 3rd cheapest of 351 $200 a month |
| GPU eval jobs 10 at once · 8 vCPU / 32 GB · 500 sessions of 30 min a month | Not ranked: misses a requirement | Not ranked: misses a requirement | Not ranked: misses a requirement |
| macOS agents 5 at once · 4 vCPU / 8 GB · 1,000 sessions of 20 min a month | Not ranked: misses a requirement | Not ranked: misses a requirement | Not ranked: misses a requirement |
Key features
| Feature | Vercel Sandbox | Railway | boat |
|---|---|---|---|
| Isolation | Firecracker microVM with its own kernel | Sandboxes and Cloud Agents are isolated Linux VMs; app services are containers | Full VM with its own kernel, on physical hosts dedicated to boat (AMD Ryzen 7 9700X and Ryzen 9 9950X); vCPUs are shared |
| Longest session | 24 hours per session on Pro and Enterprise, 45 minutes on Hobby; the sandbox then resumes from its snapshot, with no cap on total lifetime | No set maximum; destroyed after the idle timeout (30 minutes by default, 0 for never) | No session cap once auto-stop is off on a paid plan; auto-stop defaults to 1 hour and goes up to 30 days |
| Saving files | Filesystem snapshot at every stop ($0.08/GB-month), kept 30 days after last use by default or set to never; Drives keep mounted storage until you delete them | Named disk checkpoints you take boot new sandboxes; a destroyed sandbox keeps nothing else. Cloud Agents keep their disk across sleep | Disk saved every minute and at each stop; no compute charge while stopped; disk kept at least 14 days, longer with a saved snapshot |
| Fork | Sandbox.fork() starts copies from a sandbox's latest snapshot | Fork a running sandbox's filesystem; checkpoints boot new ones | Fork a running sandbox from its last 1-minute snapshot |
| Docker and nested virtualization | Docker with sudo; no nested virtualization (Firecracker does not expose /dev/kvm) | Root shell on Ubuntu; Docker and /dev/kvm not documented, so you install and verify them yourself | Docker, root, systemd and /dev/kvm on every sandbox |
| Base images | Your own OCI images from a Dockerfile, via Vercel Container Registry | Templates built from ordered steps (apt packages, env, commands) and cached | boat's image or a saved snapshot (template), shareable by code; you cannot boot your own Docker image |
| Desktop, browser, computer use | No built-in desktop or computer-use API; you install Chromium and agent-browser yourself (Vercel guide) or connect an external browser | No desktop included; you can add Xvfb and noVNC with the template builder and publish the port. Chromium is in the Cloud Agent image | 1920x1080, 60 fps desktop and Chrome, computer tools and a browser-control API, embeddable stream |
| Coding agents | Claude Code, Codex, OpenCode and pi preinstalled; you start them as commands | Claude Code, Codex, OpenCode and Pi preinstalled, run through exec; Cloud Agents launch them with railway code and keep sessions you reattach to | Claude Code, Codex, pi, OpenCode, Prime Agent, Kimi Code, Mistral Vibe, with an API to prompt, steer and stream events |
| Keys kept outside the sandbox | Credentials brokering injects headers for any HTTPS domain you allow | Secrets go into the sandbox as environment variables, or are saved in a checkpoint | Optional AI credentials proxy ($1 per day on, plus $1 per 1,000 requests) for model providers and any HTTPS API you add |
| Inbound access | Public URLs for up to 15 ports, no built-in auth; no SSH server, raw TCP or public IP | Up to 10 public HTTPS domains, set only at creation, no built-in auth; SSH and port forwarding | Up to 50 HTTPS URLs, token-gated by default; SSH; raw ports over IPv6 (some sandboxes have no IPv4 of their own); no static IP |
| Egress rules | Allow-all, deny-all or a domain and CIDR allowlist, changeable while running | No published egress allowlist for sandboxes | No provider-side allowlist; firewall inside the VM |
| Apps and databases next to the sandbox | Part of Vercel's web app platform; sandboxes can use your project's login tokens | Postgres, Redis and services in the same project; a sandbox can join their private network | No hosted databases or app services; host your own inside a sandbox |
| Biggest sandbox | 8 vCPU / 16 GB on Pro, 32 vCPU / 64 GB on Enterprise | 8 vCPU / 8 GB on Hobby; on Pro up to 32 vCPU / 32 GB per the docs (24 vCPU / 24 GB per the pricing page) | 8 vCPU / 16 GB on the $20 plan, 16 vCPU / 32 GB from the $100 plan |
| Sandboxes at once | Up to 10,000 on Pro; vCPU allocation starts at 150 a minute and climbs with steady use | 50 per environment on Hobby, 100 on Pro; Enterprise can ask for more; no published start limit | 100 to 2,000 by plan; starts limited per minute, hour and day (12 / 60 / 200 on the $20 plan) |
| Regions | 19 regions across the US, Europe, Asia, South America, Africa and Australia | US West, US East, Amsterdam and Singapore | Germany, Finland and France; you cannot pick a region; no US or Asia region |
Every feature Battleships tracks (43)
| Feature | Vercel Sandbox | Railway | boat |
|---|---|---|---|
| Full VM (own kernel) | Yes | Yes | Yes |
| Docker inside | Yes | Not published | Yes |
| Nested virtualization | No documented way | Not published | Yes |
| Root | Yes | Yes | Yes |
| Systemd | Not published | Not published | Yes |
| Desktop GUI | No documented way | With your own setup | Yes |
| Browser | With your own setup | Yes | Yes |
| Computer-use API | No documented way | No documented way | Yes |
| SSH | No documented way | Yes | Yes |
| Persistent disk | Yes | Yes | Yes |
| Pause/resume | Yes | Yes | Yes |
| Automatic snapshots | Yes | No documented way | Yes |
| Fork/clone | Yes | Yes | Yes |
| Live fork (no pause) | Yes | Yes | Yes |
| Memory fork | No documented way | No documented way | No documented way |
| Custom image (Docker or snapshot) | Yes | Yes | Yes |
| ≥24 h sessions | Yes | Yes | Yes |
| Idle auto-stop | No documented way | Yes | No documented way |
| Wake on request | No documented way | No documented way | No documented way |
| HTTPS preview URLs | Yes | Yes | Yes |
| Raw TCP inbound | No documented way | No documented way | Yes |
| Public IPv4 | No documented way | No documented way | No documented way |
| Egress allowlist | Yes | No documented way | No documented way |
| Secret proxy | Yes | No documented way | Yes |
| Secret proxy for any API | Yes | No documented way | Yes |
| Preinstalled agents | Yes | Yes | Yes |
| Agent harness API | No documented way | Yes | Yes |
| MCP server | Yes | Yes | No documented way |
| GPU | No documented way | No documented way | No documented way |
| Windows | No documented way | No documented way | No documented way |
| Arm64 | No documented way | No documented way | No documented way |
| Self-hosting | No documented way | No documented way | No documented way |
| BYOC | No documented way | Yes | No documented way |
| Open source | No documented way | No documented way | No documented way |
| Scoped API keys | Not published | Not published | Yes |
| Spend limits | Yes | Yes | Yes |
| Usage per sandbox (API) | No documented way | No documented way | Yes |
| Audit logs | Not published | Yes | No documented way |
| SSO | Yes | Yes | No documented way |
| SOC 2 | Yes | Yes | No documented way |
| HIPAA | Yes | Yes | No documented way |
| EU data residency | Yes | Yes | No documented way |
| Zero data retention | Not published | Not published | Yes |
Performance
On the V8 Web Tooling Benchmark at 4 vCPU / 8 GB, boat did 28.06 runs per second and Vercel Sandbox did 12.66 (about 2.2x), in StarSling's run of 3 October 2026 (run 37073680030). Every boat sandbox in this run ran on an AMD Ryzen 9 9950X host; boat also places sandboxes on Ryzen 7 9700X hosts and does not promise a CPU model. Providers ran on different hardware in different regions. Railway is not in the public benchmarks we use, so we cannot say how it compares. This measures CPU speed only, not start time.
V8 Web Tooling Benchmark at a 4 vCPU / 8 GB target, runs per second, higher is better. Source: StarSling's run of 3 October 2026 (run 37073680030), median of 5 sandboxes. Providers ran on different hardware in different regions. StarSling gives a shared rank when the run cannot separate two providers. Every boat sandbox in this run ran on an AMD Ryzen 9 9950X host. boat also places some sandboxes on AMD Ryzen 7 9700X hosts, which this run did not measure. Railway is not in the public benchmarks we use, so we cannot say which is faster.
Pricing in five scenarios
Each bill is priced from the providers' public price lists by the open Battleships engine, with the cheapest plan that runs the scenario. Start limits, per-start fees and plan minimums are in the price, boat's included.
| Scenario | Vercel Sandbox, a month | Railway, a month | boat, a month |
|---|---|---|---|
| One coding agent, workdays 4 vCPU / 8 GB, 50 GB disk, 8 hours a day, 22 days a month, files kept between days | $57 · Pro | $16 · Hobby · with limits | $20 · $20/mo |
| One agent that never stops 4 vCPU / 8 GB, 50 GB disk, running 24/7 all month | $236 · Pro · with limits | $70 · Hobby · with limits | $26 · $20/mo |
| 50 agents in parallel 50 machines of 4 vCPU / 8 GB at once, 8-hour sessions, 1,100 sessions a month, Docker inside | $2,884 · Pro | $739 · Hobby · with limits | $317 · $20/mo × 3 seats |
| Sandboxes for your users 2 vCPU / 4 GB, 30,000 sessions of 10 minutes a month, up to 300 at once | $828 · Pro | $223 · Pro · with limits | $200 · $100/mo × 2 seats |
| 1,000 short jobs at once 2 vCPU / 4 GB, 1,000 at once, 3 minutes each, 200,000 jobs a month | $3,152 · Pro | $781 · Pro · with limits | $8,800 · $2000/mo · with limits |
Vercel Sandbox: Vercel charges for CPU only while your code uses it ($0.128 per vCPU-hour in iad1), and for memory for the whole time the sandbox runs ($0.0212 per GB-hour). It adds $0.60 per million sandboxes created, $0.08 per GB-month of snapshots, and $0.05 per GB-month for Drives plus reads and writes. The $20 Pro credit is shared with your other Vercel usage.
Railway: Railway bills sandboxes per second at about $50 per vCPU-month on CPU used and $50 per GB-month on memory in use, plus $0.05 per GB out. Memory keeps billing while a sandbox waits, until it is destroyed. Plans: Free ($0 with $1 of usage a month), Hobby ($5) and Pro ($20 per workspace). Railway does not publish a price for sandbox disk or checkpoints, so our Railway bills leave disk out.
Railway: boat charges a flat price per size, per second, while the sandbox runs, busy or idle: $0.036 an hour for 4 vCPU / 8 GB. Plans cost $20, $100, $500 or $2,000 a month, and the whole plan price comes back as VM time for that month. A card is required, also for the 7-day trial. A stopped sandbox has no compute charge, but saved snapshots above the plan's count and the optional AI credentials proxy still charge. Starts above the plan's included number cost $0.03 to $0.07 each.
Limits in those scenarios
Railway is marked as not a clean fit in the five scenarios because it is an app platform first and does not publish a sandbox disk price, so its bills count CPU and memory only. Its cap of 100 sandboxes per environment on Pro means 300 sandboxes for your users or 1,000 jobs at once need several environments, and Docker inside is not confirmed for the 50-agent fleet. Vercel fits every scenario except one agent that never stops, where each session ends at 24 hours and processes start again. boat fits every scenario except the 1,000-job burst: the $2,000 plan includes 600 starts an hour, starts above that are paid (about $8,800 a month), and starts above 270 a minute fail with 429.
| Scenario | Vercel Sandbox | Railway | boat |
|---|---|---|---|
| One coding agent, workdays | None for this scenario |
| None for this scenario |
| One agent that never stops |
|
| None for this scenario |
| 50 agents in parallel | None for this scenario |
| None for this scenario |
| Sandboxes for your users | None for this scenario |
| None for this scenario |
| 1,000 short jobs at once | None for this scenario |
|
|
Which one should you use?
Use Vercel Sandbox when
you run many short bursts of untrusted code at high concurrency, need regions outside the US and Europe, or want a firewall you can change from outside.
- Big bursts of short jobs. Useful for code interpreters and RL rollouts: Vercel fits 1,000 short jobs at once, where Railway caps 100 per environment on Pro.
- Regions all over the world. Useful if your users are spread out: Vercel Sandbox runs in 19 regions, from Virginia to Tokyo and Sydney.
- A firewall you control from outside. A running sandbox can be switched to deny-all, or to a list of allowed domains, without a restart.
Use Railway when
your app and databases already live on Railway and you want sandboxes on the same private network, or need machines up to 32 vCPU on a self-serve plan.
- Your apps and databases in one place. Useful if your app already runs on Railway: sandboxes can join the same private network as your Postgres and services.
- One long session. Useful for long tasks: with the idle timeout set to 0, a Railway sandbox runs as one session until you destroy it.
- Bigger machines and small bills. Useful for heavy builds or light use: Railway Pro allows sandboxes up to 32 vCPU / 32 GB, and its Hobby plan costs $5.
Where boat fits
Vercel resumes sandboxes across 24-hour sessions, and Railway destroys idle sandboxes unless you take a checkpoint. If your agents work for hours or days on one machine, with Docker, a desktop and an API to drive them, look at boat. It is not the pick for 1,000 short jobs at once: Vercel fits that, and boat hits its start limits. boat runs only in the EU and has no GPU.
Work survives a pause
Vercel ends each session at 24 hours; the files resume, but running processes start again. Railway destroys a sandbox after 30 idle minutes unless you set the timeout to 0, and then memory bills until you destroy it. boat saves the disk every minute and has no compute charge while stopped. Memory and running programs are not saved on boat either.
A desktop, Docker and KVM, built in
Neither includes a desktop; you install one yourself. Vercel has no nested virtualization, and Railway's sandbox docs do not mention Docker or /dev/kvm. boat has all of them, with root and systemd.
Agents driven from outside
On Vercel Sandbox and Railway Sandboxes you start each agent as a command and parse its output. boat gives you a prompt, steer and events API, and an optional credentials proxy that keeps model keys outside the sandbox.
Use boat when your agents work for hours or days on one machine: a full VM that keeps its disk, with Docker, /dev/kvm, a desktop and an API to drive the agents inside. Check the start limits of your plan first. Compare it one to one: boat vs Vercel Sandbox and boat vs Railway.
boat's own limits
- Plans start at $20 a month. The plan price comes back as VM time for that month. Unused time does not carry over. Source
- Starts (create, fork, resume): the $20 plan includes 12 a minute, 60 an hour and 200 a day. The $2,000 plan includes 90 a minute, 600 an hour and 2,400 a day. Extra starts cost $0.03 to $0.07. A start fails with 429 above 3 times the included starts per minute, or 6 times per hour or per day. Source
- A stopped sandbox has no compute charge. boat keeps its disk for at least 14 days. A saved snapshot keeps it longer; extra saved snapshots and the AI credentials proxy are paid. Source
- Auto-stop defaults to 1 hour. You can turn it off on a paid plan. The trial allows 2 hours at most. Source
- boat saves the disk every minute and at each stop. Memory, running programs and /tmp are not saved: a resume is like a reboot. A machine failure loses writes after the last good snapshot. Source
- Machines run in Germany, Finland and France only. Snapshot copies can be stored outside the EU. Source
- Public IPv6 and outbound IPv4. No dedicated IPv4. The IP changes at each resume. Source
- Hosts are AMD Ryzen 7 9700X and Ryzen 9 9950X. vCPUs are shared. No GPU. You cannot boot your own Docker image. Source
Questions people ask
Is Vercel Sandbox cheaper than Railway?
Railway's bills come out lower in all five of our scenarios: $16 vs $57 for one workday agent, $739 vs $2,884 for 50 agents in parallel, and $781 vs $3,152 for 1,000 short jobs at once. Railway's numbers leave out disk, which it does not price, and its 100-per-environment cap means several of those jobs do not fit cleanly. boat comes to $20 and $317 for the first two; the burst costs about $8,800 on boat because of paid starts.
Which is faster, Vercel Sandbox or Railway?
We cannot say, because Railway is not in the public benchmarks we use. Vercel Sandbox did 12.66 V8 Web Tooling Benchmark runs per second at 4 vCPU / 8 GB in StarSling's run of 3 October 2026, and boat did 28.06 on an AMD Ryzen 9 9950X host.
Can Vercel Sandbox or Railway run Docker?
Vercel's docs say you can run Docker inside a sandbox with sudo, with no nested virtualization. Railway sandboxes give you a root shell on Ubuntu, but the sandbox docs do not mention Docker or /dev/kvm, so you install and verify them yourself. boat has Docker, systemd and /dev/kvm on every sandbox.
Can either run an agent 24/7?
Not as one Vercel session: it stops after 24 hours on Pro, then resumes from its snapshot, and an onResume hook can restart your processes. Railway can, if you set the idle timeout to 0 or use a Cloud Agent, and memory bills the whole time. One agent that never stops comes to $236 on Vercel, $70 on Railway without disk, and $26 on boat with auto-stop off.
Are both real virtual machines?
Yes. Vercel runs each sandbox in a Firecracker microVM with its own kernel, and Railway's docs call each sandbox an isolated virtual machine, while its regular app services are containers. boat runs every sandbox as a full VM too.
Where do they run?
Vercel Sandbox runs in 19 regions, with iad1 in the US as the default. Railway runs in California, Virginia, Amsterdam and Singapore, and new sandboxes start in US West unless you pick a region. boat runs on machines in Germany, Finland and France, and you cannot pick a region.
Try boat
Install the CLI, then run boat new.
7-day free trial
More comparisons
- boat vs Vercel Sandbox
- boat vs Railway
- E2B vs Vercel Sandbox
- Daytona vs Vercel Sandbox
- Modal vs Vercel Sandbox
- Vercel Sandbox vs Cloudflare Sandbox
- Vercel Sandbox vs Blaxel
- Vercel Sandbox vs Runloop
- Vercel Sandbox vs Tensorlake
- Vercel Sandbox vs Morph Cloud
- Vercel Sandbox vs CodeSandbox SDK
- Vercel Sandbox vs Northflank