Railway vs GitHub Codespaces

Railway is an app platform that added sandbox VMs you create from code and run commands in. Railway destroys a sandbox after an idle timeout, unless you take a checkpoint. GitHub Codespaces is a dev environment for people: a Linux dev container opened from a repository in VS Code or the browser. A codespace stops after 12 hours at most.

The companies and products

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.

GitHub Codespaces

GitHub Codespaces is GitHub's cloud development environment: a ready-to-code Linux machine for a repository, opened in the browser, VS Code or the GitHub CLI.

Codespaces is a different kind of product from boat: a dev environment for people who work on a GitHub repository, not a sandbox API for agents. Each codespace is a Docker container built from the repo's dev container config. It runs on its own newly built VM on Azure, with 2 to 32 cores. It is built for developers and teams who want every contributor to start from the same setup, with prebuilds, port forwarding and GitHub billing.

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. “28th cheapest of 365” means 27 of the other 364 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 workloadRailway: price rankGitHub Codespaces: price rankboat: price rank
Software factory
100 at once · 4 vCPU / 8 GB · 2,200 sessions of 8 h a month
Railway ranks 13th with your own setup: keep work in checkpoints or set the idle timeout to 0. A codespace stops at 12 hours, so long loops restart. boat saves the disk every minute and ranks 8th.
28th cheapest of 365
$1,481 a month
290th of 365, with limits
$4,618 a month
5th cheapest of 365
$634 a month
Always-on AI employees
50 machines 24/7 · 2 vCPU / 4 GB
Railway (30th) keeps an assistant running with the idle timeout set to 0, and memory bills the whole time. Every codespace stops after 12 hours at most, so it needs a restart script. boat ranks 6th once auto-stop is off.
21st cheapest of 361
$3,977 a month
320th of 361, with limits
$6,970 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
Railway fits short code runs better (43rd): it bills for CPU used and destroys the sandbox when done. Each codespace builds a dev container on a new VM, which prebuilds speed up.
42nd cheapest of 336
$413 a month
283rd of 336, with limits
$619 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
Railway caps sandboxes per environment (100 on Pro), and GitHub does not publish how many codespaces can run at once, so 300 user sandboxes are a compromise on both. boat ranks 3rd.
46th of 349, with limits
$290 a month
276th of 349, with limits
$1,964 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
84th of 349, with limits
$4,450 a month
276th of 349, with limits
$9,489 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
Railway can fork a running sandbox and boot many from one checkpoint. Codespaces has no copy or snapshot API, so every run starts again from the repository or a prebuild. boat ranks 12th.
113th of 359, with limits
$364 a month
295th of 359, with limits
$1,519 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
Codespaces runs Docker inside the dev container through a dev container feature. Railway does not document Docker, so you install and verify it yourself. boat documents Docker and /dev/kvm and ranks 2nd.
116th cheapest of 374
$1,210 a month
317th of 374, with limits
$909 a month
2nd cheapest of 374
$86 a month
24/7 dev boxes
1 machine 24/7 · 4 vCPU / 8 GB
Codespaces is a polished VS Code box per repo but stops at 12 hours. Railway (71st) has SSH, and its Cloud Agents keep a disk but are in Priority Boarding. boat ranks 19th.
69th cheapest of 371
$89 a month
144th of 371, with limits
$270 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
Railway ranks 15th with your own setup: add Xvfb and noVNC. A codespace can add a noVNC desktop through the desktop-lite feature, with no computer-use API. boat includes a 60 fps desktop and ranks 10th.
47th cheapest of 367
$407 a month
297th of 367, with limits
$1,367 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
53rd of 356, with limits
$93 a month
306th of 356, with limits
$678 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
65th cheapest of 343
$570 a month
324th of 343, with limits
$922 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
111th of 327, with limits
$2,988 a month
279th of 327, with limits
$18,637 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
71st of 351, with limits
$574 a month
284th of 351, with limits
$445 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 requirementNot ranked: misses a requirementNot 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 requirementNot ranked: misses a requirementNot ranked: misses a requirement

Key features

FeatureRailwayGitHub Codespacesboat
Kind of productApp platform with sandbox VMs you create from a CLI or TypeScript SDKCloud dev environment per GitHub repository, for people in VS Code or the browserSandbox you drive from code: full VMs for agents, with an API and SDK
IsolationSandboxes are isolated Linux VMs; app services are containersA Docker container on its own newly built VMEvery sandbox is a full VM with its own kernel, on a host dedicated to boat; vCPUs are shared
How long it runsUntil destroyed; the idle timeout (30 minutes by default) destroys it, or set it to 0 for neverStops after 30 idle minutes by default (up to 240) and after 12 hours at most, even while in useAuto-stop defaults to 1 hour; set up to 30 days, or turn it off on a paid plan for no cap
Files after it stopsDestroyed with the sandbox; checkpoints you take survive and boot new onesKept and billed as storage; stopped codespaces are deleted after 30 days by defaultDisk saved every minute and at stop, kept at least 14 days with no compute charge; a saved snapshot has no expiry
Docker and nested virtualizationRoot shell on Ubuntu; Docker and /dev/kvm are not documented: you install and verify them yourselfDocker inside through a dev container feature, with sudo; /dev/kvm is not documentedDocker, root, systemd and /dev/kvm on every machine
Fork and snapshotsFork a running sandbox's filesystem; named checkpoints boot new onesNo copy or snapshot endpoint; new codespaces start from a repo, branch or prebuildFork from the last 1-minute snapshot; saved snapshots as templates
Starting setupTemplates built from ordered steps (packages, env, commands) and cachedDev container config in the repo, with prebuilds built by GitHub ActionsSaved snapshots (templates), shareable by code; no custom Docker or OCI image
Coding agentsClaude Code, Codex, OpenCode and Pi preinstalled, run through execGitHub Copilot as a VS Code extension; other agents you install yourselfSeven harnesses installed, including Claude Code, Codex and OpenCode, with a prompt, steer and events API
Keeping keys out of the sandboxSecrets go in as environment variables or are saved in a checkpointSecrets are copied into the codespace as environment variablesOptional paid credentials proxy ($1 per day on, plus $1 per 1,000 requests) for supported model providers; other secrets still enter
Desktop and computer useNo desktop included; you can add Xvfb and noVNC with the template builder and publish the portVS Code, JupyterLab and a terminal; a noVNC desktop through the desktop-lite dev container feature, which you configureBuilt-in desktop and Chrome stream at 1920x1080, 60 fps, with computer-use tools
Reaching the sandboxUp to 10 public HTTPS domains, set at creation, with no built-in auth; SSHA URL per forwarded port, private, organization or public; SSH; no public IPUp to 50 HTTPS URLs, token-gated by default; SSH; public IPv6 for raw ports. No dedicated IPv4.
Apps and databases nearbyPostgres, Redis and services in the same project, on a private network the sandbox can joinNone hosted; you run them inside the codespaceNone hosted; you run them inside a sandbox
Machines at oncePer environment: 50 on Hobby, 100 on Pro; Enterprise can ask for moreLimits exist but GitHub does not publish them100 to 2,000 by plan; starts limited per minute, hour and day (12 / 60 / 200 on $20)
RegionsUS West, US East, Amsterdam and SingaporeUS East, US West, Europe West and Southeast AsiaGermany, Finland and France; no US or Asia region, and you cannot pick one
Every feature Battleships tracks (43)
FeatureRailwayGitHub Codespacesboat
Full VM (own kernel)YesYesYes
Docker insideNot publishedYesYes
Nested virtualizationNot publishedNot publishedYes
RootYesYesYes
SystemdNot publishedNot publishedYes
Desktop GUIWith your own setupWith your own setupYes
BrowserYesNo documented wayYes
Computer-use APINo documented wayNo documented wayYes
SSHYesYesYes
Persistent diskYesYesYes
Pause/resumeYesYesYes
Automatic snapshotsNo documented wayNo documented wayYes
Fork/cloneYesNo documented wayYes
Live fork (no pause)YesNo documented wayYes
Memory forkNo documented wayNo documented wayNo documented way
Custom image (Docker or snapshot)YesYesYes
≥24 h sessionsYesNo documented wayYes
Idle auto-stopYesYesNo documented way
Wake on requestNo documented wayNo documented wayNo documented way
HTTPS preview URLsYesYesYes
Raw TCP inboundNo documented wayNo documented wayYes
Public IPv4No documented wayNo documented wayNo documented way
Egress allowlistNo documented wayNo documented wayNo documented way
Secret proxyNo documented wayNo documented wayYes
Secret proxy for any APINo documented wayNo documented wayYes
Preinstalled agentsYesNo documented wayYes
Agent harness APIYesNo documented wayYes
MCP serverYesNo documented wayNo documented way
GPUNo documented wayNo documented wayNo documented way
WindowsNo documented wayNo documented wayNo documented way
Arm64No documented wayNo documented wayNo documented way
Self-hostingNo documented wayNo documented wayNo documented way
BYOCYesNo documented wayNo documented way
Open sourceNo documented wayNo documented wayNo documented way
Scoped API keysNot publishedNot publishedYes
Spend limitsYesYesYes
Usage per sandbox (API)No documented wayNo documented wayYes
Audit logsYesYesNo documented way
SSOYesYesNo documented way
SOC 2YesYesNo documented way
HIPAAYesNo documented wayNo documented way
EU data residencyYesYesNo documented way
Zero data retentionNot publishedNot publishedYes

Performance

RailwayNot measured
GitHub CodespacesNot measured
boat28.06 runs/s

Neither Railway nor GitHub Codespaces is in the public benchmarks we use, so we cannot say which is faster. In StarSling's run of 3 October 2026 (run 37073680030), boat did 28.06 runs/s on the V8 Web Tooling Benchmark at 4 vCPU / 8 GB, second of 15. Every boat sandbox in that 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.

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 and GitHub Codespaces are 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.

ScenarioRailway, a monthGitHub Codespaces, a monthboat, 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
$16 · Hobby · with limits$51 · Personal account: GitHub Free$20 · $20/mo
One agent that never stops
4 vCPU / 8 GB, 50 GB disk, running 24/7 all month
$70 · Hobby · with limits$270 · Personal account: GitHub Free · 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
$739 · Hobby · with limits$3,019 · Personal account: GitHub Free$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
$223 · Pro · with limits$850 · Personal account: GitHub Free · 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
$781 · Pro · with limits$1,889 · Personal account: GitHub Free · with limits$8,800 · $2000/mo · with limits

Railway: Railway bills sandboxes per second at about $50 per vCPU-month on CPU actually 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. Railway publishes no price for sandbox disk, so our bills leave disk out.

GitHub Codespaces: Codespaces bills $0.09 per core-hour for the whole time a codespace is active, used or not, plus $0.07 per GB-month of storage while it exists, stopped too. There is no 4-core machine with 8 GB, so 4 vCPU / 8 GB jobs are priced on the 4-core 16 GB machine. Personal accounts get a free monthly quota; organizations do not.

GitHub Codespaces: Plans cost $20, $100, $500 or $2,000 a month, and the whole plan price comes back as VM time for that month. A running sandbox bills per second at full rate, busy or idle: $0.036 an hour for 4 vCPU / 8 GB. A stopped sandbox has no compute charge, but saved snapshots above the included count and the AI credentials proxy still charge. Extra starts cost $0.03 to $0.07 each. A card is required, also for the 7-day trial.

Limits in those scenarios

Railway shows as not a clean fit in every scenario because it is an app platform first and does not price sandbox disk. It caps sandboxes per environment, 100 on Pro, so 300 user sandboxes or 1,000 jobs at once need several environments. Codespaces stops every machine at 12 hours, so its always-on price assumes a restart script, and GitHub does not publish how many can run at once. boat's $2,000 plan charges for starts above 90 a minute and refuses them above 270, so boat does not fit the 1,000-job burst. If a boat machine fails, you lose what was written after the last good snapshot.

ScenarioRailwayGitHub Codespacesboat
One coding agent, workdays
  • different kind of product: app platform
  • disk beyond 0 GiB: price unknown
None for this scenarioNone for this scenario
One agent that never stops
  • different kind of product: app platform
  • disk beyond 0 GiB: price unknown
  • Personal account: GitHub Free: sessions capped at 12 h
None for this scenario
50 agents in parallel
  • not confirmed: Docker inside
  • different kind of product: app platform
  • disk beyond 0 GiB: price unknown
  • how many machines can run at once: limit not published, probably fine at 50 (the typical published limit is 50)
None for this scenario
Sandboxes for your users
  • Pro: max 100 concurrent
  • different kind of product: app platform
  • disk beyond 0 GiB: price unknown
  • not confirmed: how many machines can run at once (you need 300; the typical published limit is 50)
None for this scenario
1,000 short jobs at once
  • Pro: max 100 concurrent
  • different kind of product: app platform
  • disk beyond 0 GiB: price unknown
  • not confirmed: how many machines can run at once (you need 1,000; the typical published limit is 50)
  • 2,400 starts/day included, paid above that (needs ~6,667)
  • 600 starts/hour included, paid above that (needs ~1,000)
  • starts above 90/min are paid, and starts above 270/min fail with 429

Which one should you use?

Use Railway when

your app already lives on Railway and you want sandboxes created from code on the same private network, billed on CPU used.

  • Sandboxes next to your apps. Useful if your app already runs on Railway: a sandbox can join the private network of your Postgres and services.
  • Built for code that creates machines. Useful for agent platforms: create, fork and destroy sandboxes from an SDK, with coding agents already in the image.
  • Short jobs billed on CPU used. Useful for many quick runs: Railway bills sandbox CPU on what is used and destroys the machine when done.

Use GitHub Codespaces when

your developers want a ready VS Code environment for a GitHub repository, opened from a branch or pull request, with compliance reports available today.

  • Built into GitHub. Useful if your team lives on GitHub: open a ready VS Code setup from any repo, branch or pull request.
  • Compliance reports today. Useful if you need audit reports now: GitHub Enterprise Cloud lists several.
  • Free hours for personal accounts. Useful for occasional personal work: a GitHub Free account includes 120 core-hours and 15 GB-month of storage each month.

Where boat fits

If you run coding agents that work for hours, both choices need extra work. Railway destroys idle sandboxes unless you take a checkpoint, and Codespaces stops every machine at 12 hours. boat gives each agent a full VM that runs until you stop it once auto-stop is off, saves its disk every minute, and comes with Docker, /dev/kvm, a desktop and agents you drive by API. boat runs only in the EU and limits starts by plan.

Machines that keep running and keep their work

A Railway sandbox is destroyed after 30 idle minutes unless you set the timeout to 0, and then memory bills until you destroy it. A codespace stops at 12 hours, ending its processes. boat runs until you stop it once auto-stop is off, and saves the disk every minute. Memory is not saved.

A full VM with Docker, /dev/kvm and a desktop

Railway does not document Docker, and neither documents /dev/kvm. Both can add a desktop that you set up yourself. An agent that boots an Android emulator or tests a site in a real browser gets all three on boat, documented.

Agents driven from outside

On Railway you run agents through exec and parse output; on Codespaces you script them over SSH. Both put API keys in environment variables any code can read. boat has a prompt, steer and events API and an optional paid credentials proxy.

Use boat when your agents work for hours or days: full VMs that save their disk every minute, with Docker, /dev/kvm, a desktop, and coding agents you drive by API. boat runs only in the EU. Compare it one to one: boat vs Railway and boat vs GitHub Codespaces.

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 Railway cheaper than GitHub Codespaces?

In the scenarios we priced, yes, though Railway's numbers leave out disk, which it does not price. One agent on workdays is $16 on Railway against $51 on Codespaces, one agent running all month $70 against $270, and 50 agents in parallel $739 against $3,019. On boat those are $20, $26 and $317. Below about $20 of use a month, the free Codespaces quota on a personal account costs less than boat.

Which is faster, Railway or GitHub Codespaces?

We cannot say: neither is in the public benchmarks we use. In StarSling's run of 3 October 2026, boat did 28.06 runs/s at 4 vCPU / 8 GB on a Ryzen 9 9950X host.

Can Railway or Codespaces run Docker?

Docker works inside a codespace through dev container features, with sudo. Railway's sandbox docs give you a root shell on Ubuntu but do not mention Docker, so you install and verify it yourself. boat documents Docker, systemd and /dev/kvm on every machine.

Can I keep an AI agent running 24/7 on either?

On Railway, if you set the idle timeout to 0, and memory then bills the whole time. A codespace stops after 12 hours at most, so you need a script that restarts it. A boat sandbox stops after 1 hour by default; on a paid plan you turn auto-stop off and it runs until you stop it.

Do Railway or Codespaces come with coding agents?

Railway's sandbox image includes Claude Code, Codex, OpenCode and Pi, which you run through exec. Codespaces offers GitHub Copilot as an editor extension, and other agents you install yourself. boat installs seven coding agents and lets you prompt, steer and watch them through an API.

Where do they run?

Railway runs in California, Virginia, Amsterdam and Singapore. Codespaces runs in US East, US West, Europe West and Southeast Asia. boat sandboxes run in Germany, Finland and France, and boat can store snapshot copies outside the EU.

Try boat

Install the CLI, then run boat new.

7-day free trial

More comparisons