Fly.io Machines vs GitHub Codespaces

Fly.io Machines are fast microVMs you boot from your own image to host apps near users, and they run until you stop them. GitHub Codespaces are ready dev containers opened from a repository in VS Code, and each one stops after 12 hours at most.

The companies and products

Fly.io Machines

Fly.io is an app hosting platform, and Machines are the microVMs underneath it that you can also start and stop through a REST API.

A Fly Machine boots your Docker image as a Firecracker microVM on Fly's own servers, in one of 17 regions. You pick a shared or performance CPU preset, attach at most one Volume for data that must last, and Fly Proxy can stop, suspend and wake Machines as traffic comes and goes. It is built for teams that host web apps and services worldwide; it is not a sandbox product, so this page compares the parts that overlap with agent work.

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 bochka: a dev environment for people working on a GitHub repository, not a sandbox API for agents. Each codespace is a Docker container built from the repo's dev container config, running 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. “92nd cheapest of 367” means 91 of the other 366 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 workloadFly.io Machines: price rankGitHub Codespaces: price rankbochka: price rank
Software factory
100 at once · 4 vCPU / 8 GB · 2,200 sessions of 8 h a month
Neither fits fully: Fly needs a Volume for files that must last and offers no /dev/kvm, while Codespaces stops every 12 hours; bochka fits with Docker, /dev/kvm and a kept disk.
92nd of 367, with limits
$836 a month
274th of 367, with limits
$4,618 a month
3rd cheapest of 367
$634 a month
Always-on AI employees
50 machines 24/7 · 2 vCPU / 4 GB
Fly Machines run until stopped, which suits a long-lived assistant better than Codespaces and its 12-hour cap, though Fly keeps only what sits on the one Volume.
125th of 366, with limits
$816 a month
309th of 366, with limits
$6,970 a month
5th cheapest of 366
$657 a month
Code interpreter bursts
100 at once · 1 vCPU / 2 GB · 200,000 sessions of 1 min a month
Fly fits short bursts best of the three on paper, with per-second billing and no plan fee, while each codespace builds a dev container on a new VM first.
75th of 345, with limits
$94 a month
288th of 345, with limits
$619 a month
186th of 345, 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
Fly can host one Machine per user through its API, while Codespaces are made for GitHub users on a repository and GitHub does not publish how many can run at once.
69th of 361, with limits
$600 a month
281st of 361, with limits
$1,964 a month
Cheapest of 361
$209 a month
RL rollouts
1,000 at once · 2 vCPU / 4 GB · 1,000,000 sessions of 3 min a month
48th of 360, with limits
$2,838 a month
282nd of 360, with limits
$9,489 a month
34th of 360, with limits
$2,000 a month
Agent evals
250 at once · 4 vCPU / 8 GB · 15,000 sessions of 20 min a month
117th of 364, with limits
$457 a month
295th of 364, with limits
$1,519 a month
10th cheapest of 364
$200 a month
CI runners
40 at once · 8 vCPU / 16 GB · 6,000 sessions of 12 min a month
Busy CI jobs drain a shared Fly vCPU's burst balance, and Codespaces has no fork or snapshot API, so each run starts from a repo or prebuild.
152nd of 377, with limits
$288 a month
314th of 377, with limits
$909 a month
4th cheapest of 377
$86 a month
24/7 dev boxes
1 machine 24/7 · 4 vCPU / 8 GB
Codespaces gives a polished VS Code box per repo but stops after 12 hours; Fly runs 24/7 but you build the image; bochka is a full VM that keeps running.
118th of 368, with limits
$53 a month
130th of 368, with limits
$270 a month
18th cheapest of 368
$26 a month
Computer-use agents
50 at once · 4 vCPU / 8 GB · 20,000 sessions of 15 min a month
Neither ships a graphical desktop, so computer-use agents need one built by hand on both, while bochka streams a 60fps desktop with Chromium.
95th of 369, with limits
$173 a month
267th of 369, with limits
$1,367 a month
6th cheapest of 369
$200 a month
Browser-use agents
50 at once · 2 vCPU / 4 GB · 30,000 sessions of 10 min a month
160th of 367, with limits
$90 a month
275th of 367, with limits
$678 a month
7th cheapest of 367
$200 a month
Scraping & bots (startup scale)
50 at once · 1 vCPU / 2 GB · 100,000 sessions of 3 min a month
161st of 346, with limits
$67 a month
310th of 346, with limits
$922 a month
6th cheapest of 346
$90 a month
Mass scraping & bots (undetectable)
1,000 at once · 1 vCPU / 2 GB · 3,000,000 sessions of 2 min a month
Fly is the strongest of the three here, since it can spread scrapers across 17 regions and bill only the seconds they run.
44th of 338, with limits
$1,232 a month
280th of 338, with limits
$18,637 a month
71st of 338, with limits
$1,800 a month
Parallel red teaming
200 at once · 2 vCPU / 4 GB · 5,000 sessions of 30 min a month
118th of 360, with limits
$63 a month
267th of 360, with limits
$445 a month
2nd cheapest of 360
$200 a month
GPU eval jobs
10 at once · 8 vCPU / 32 GB · 500 sessions of 30 min a month
Can't run itCan't run itCan't run it
macOS agents
5 at once · 4 vCPU / 8 GB · 1,000 sessions of 20 min a month
Can't run itCan't run itCan't run it

Key features

FeatureFly.io MachinesGitHub Codespacesbochka
Kind of productApp hosting platform; you boot your own image as a microVMCloud dev environment: a dev container per GitHub repositoryAgent sandbox: a full VM per agent, ready to use
IsolationFirecracker microVM with its own kernelA Docker container on its own newly built VMFull VM with its own kernel on dedicated AMD Ryzen 9 9950X (Zen 5) hosts
How long it runsRuns until you or Fly Proxy stop it; no documented maximumStops after 30 idle minutes by default and after 12 hours at most, even while in useRuns until you stop it; no session cap on paid plans
Docker, systemd and nested virtualizationRoot and Docker you install yourself; no systemd; /dev/kvm not offeredDocker and sudo inside the dev container; /dev/kvm not documentedDocker, root, systemd and /dev/kvm on every machine
Files after a stopRoot file system is ephemeral; lasting data goes on one Volume, billed for its full size around the clockSaved files are kept and storage is billed; stopped codespaces are deleted after 30 days by defaultThe whole disk is kept, with snapshots every minute and on stop; a stopped sandbox costs nothing
Pause with memorySuspend keeps memory for Machines up to 2GBNo memory state is kept; processes end at each stopResume reboots from disk (no memory snapshots)
Fork and copiesClone copies a Machine's config; a cloned Volume starts emptyNo copy or snapshot endpoint; new codespaces start from a repo, branch or prebuildFork a running sandbox, disk included; named snapshots as templates
Starting pointAny Docker image you buildDev container config in the repo, with prebuilds built by GitHub ActionsNamed snapshots (templates), shareable by code; no Dockerfile builds
Desktop and computer useNone built in; you add a desktop and browser to your imageVS Code, JupyterLab and a terminal; no graphical desktop60fps desktop and Chromium, computer use and browser control, embeddable stream
Coding agentsNone built in; you install and run agents yourselfGitHub Copilot as a VS Code extension; other agents you install yourselfClaude Code, Codex, OpenCode and more preinstalled, with a prompt, steer and events API
Keeping keys out of the sandboxSecrets arrive as environment variables; an open-source tokenizer proxy you deploy yourselfSecrets are copied into the codespace as environment variablesAI credentials proxy for model providers and any HTTPS API; switch a credential to another account when credits run out
Reaching the machinePublic HTTPS and TCP through Fly Proxy, Anycast IPs, custom domains, private networkA URL per forwarded port and SSH tunnels; no public IPHTTPS URLs for up to 50 ports, token-protected; raw TCP; dedicated IPv6 or IPv4
Outbound rulesNetwork policies allow chosen ports and protocols and deny the restOpen internet; GitHub says there is no way to restrict itOpen internet on every plan; no provider-side allowlist
Regions17 regions on six continentsUS East, US West, Europe West and Southeast AsiaEU only: Germany, Finland, France
Every feature Battleships tracks (43)
FeatureFly.io MachinesGitHub Codespacesbochka
Full VM (own kernel)YesYesYes
Docker insideYesYesYes
Nested virtualizationNoNoYes
RootYesYesYes
SystemdNoNot publishedYes
Desktop GUINoNoYes
BrowserNoNoYes
Computer-use APINoNoYes
SSHYesYesYes
Persistent diskYesYesYes
Pause/resumeYesYesYes
Automatic snapshotsYesNoYes
Fork/cloneYesNoYes
Live fork (no pause)YesNoYes
Memory forkNoNoNo
Custom image (Docker or snapshot)YesYesYes
≥24 h sessionsYesNoYes
Idle auto-stopYesYesNo
Wake on requestYesNoNo
HTTPS preview URLsYesYesYes
Raw TCP inboundYesNoYes
Public IPv4YesNoNo
Egress allowlistYesNoNo
Secret proxyNoNoYes
Secret proxy for any APINoNoYes
Preinstalled agentsNoNoYes
Agent harness APINoNoYes
MCP serverYesNoNo
GPUNoNoNo
WindowsNoNoNo
Arm64NoNoNo
Self-hostingNoNoNo
BYOCNoNoNo
Open sourceYesNoNo
Scoped API keysNot publishedNot publishedYes
Spend limitsNoYesYes
Usage per sandbox (API)NoNoYes
Audit logsNot publishedYesNo
SSONoYesNo
SOC 2YesYesNo
HIPAAYesNoNo
EU data residencyYesYesYes
Zero data retentionNot publishedNot publishedYes

Performance

Fly.io MachinesNot measured
GitHub CodespacesNot measured
bochka26.69 runs/s

There is no comparable measurement for either one: neither Fly.io Machines nor GitHub Codespaces was in the public StarSling run where bochka did 26.69 Node.js build-and-test runs per second at 4 vCPU / 8 GB. Fly's shared vCPUs guarantee only 6.25% of each core with a burst balance, so its results would depend on whether you pick shared or performance CPUs.

Node.js build-and-test loop at 4 vCPU / 8 GB, higher is better. Measured with the open hpc-sandbox-benchmarks suite. Fly.io Machines and GitHub Codespaces have no published run in this suite yet, so there is no like-for-like number to compare.

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.

ScenarioFly.io Machines, a monthGitHub Codespaces, a monthbochka, 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
$15 · Pay As You Go · 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
$36 · Pay As You Go · 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
$487 · Pay As You Go · 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
$110 · Pay As You Go · 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
$232 · Pay As You Go · with limits$1,889 · Personal account: GitHub Free · with limits$2,000 · $2000/mo · with limits

Fly.io Machines: Fly bills each Machine per second while it runs, by CPU preset and memory, with no plan fee; Volumes are billed for their full size all month. The figures here use shared vCPUs bought in 1-year reservation blocks, Fly's lowest rate.

GitHub Codespaces: Codespaces bills $0.09 per core-hour while a codespace is active, plus $0.07 per GB-month of storage while it exists. A 4 vCPU / 8 GB job is priced on the 4-core 16 GB machine, and personal accounts get a free monthly quota.

GitHub Codespaces: You pick a monthly plan from $20, and all of it becomes usage credit spent per second on running sandboxes. A stopped sandbox costs nothing and keeps its disk.

Limits in those scenarios

Fly shows as a compromise in every scenario because its lowest figures need a 1-year reservation and use shared vCPUs that are throttled above 6.25% of each core, so long builds and tests slow down. Codespaces stops every codespace after 12 hours, so it does not fit the always-on agent, and GitHub does not publish how many can run at once, so 300 user sandboxes and 1,000 short jobs are not confirmed. On bochka the 1,000-job burst is limited by starts per minute and per day, so it gets queued even on the $2,000 plan.

ScenarioFly.io MachinesGitHub Codespacesbochka
One coding agent, workdays
  • different kind of product: app platform
  • 1-year commitment
  • burstable CPU: 6.25% of each vCPU guaranteed, throttled above that
None that biteNone that bite
One agent that never stops
  • different kind of product: app platform
  • 1-year commitment
  • burstable CPU: 6.25% of each vCPU guaranteed, throttled above that
  • Personal account: GitHub Free: sessions capped at 12 h
None that bite
50 agents in parallel
  • different kind of product: app platform
  • 1-year commitment
  • burstable CPU: 6.25% of each vCPU guaranteed, throttled above that
  • how many machines can run at once: limit not published, probably fine at 50 (the typical published limit is 50)
None that bite
Sandboxes for your users
  • different kind of product: app platform
  • 1-year commitment
  • burstable CPU: 6.25% of each vCPU guaranteed, throttled above that
  • not confirmed: how many machines can run at once (you need 300; the typical published limit is 50)
None that bite
1,000 short jobs at once
  • different kind of product: app platform
  • 1-year commitment
  • burstable CPU: 6.25% of each vCPU guaranteed, throttled above that
  • not confirmed: how many machines can run at once (you need 1,000; the typical published limit is 50)
  • max 2,400 starts/day (needs ~6,667)
  • max 600 starts/hour (needs ~1,000)
  • bursts above 90 starts/min are queued (a burst of 333 takes ~4 min to start)

Which one should you use?

Use Fly.io Machines when

you host web apps or services that must run near users around the world, sleep between requests and wake on traffic.

  • No time limit. Useful for services and long jobs: a Fly Machine runs until you stop it, while a codespace stops after 12 hours.
  • 17 regions and wake on request. Useful for apps near users worldwide: Fly runs in 17 regions and Fly Proxy wakes a sleeping Machine when traffic arrives.
  • Public endpoints and egress rules. Useful if you host a product: Fly gives public HTTPS and TCP, custom domains and port-level outbound rules.

Use GitHub Codespaces when

your developers want a ready VS Code environment for a GitHub repository, opened from a branch or pull request.

  • Built into GitHub. Useful if your team lives on GitHub: open a ready codespace from any repo, branch or pull request.
  • A ready editor. Useful for people, not just code: VS Code in the browser or on your machine, with dev containers and prebuilds set up.
  • Free hours for personal accounts. Useful for occasional personal work: a GitHub Free account includes 120 core-hours and 15 GB-month each month.

Where bochka fits

Fly.io Machines are built for hosting apps and GitHub Codespaces for developers working in a repository, so teams using either for agents end up building the sandbox around them. If what you are really running is agents that install, build, test and browse for hours, bochka gives each one a full VM with the disk, desktop and agent controls already in place.

A disk that keeps everything, with no time limit

A Fly Machine loses anything outside its one Volume on restart, and a codespace stops at 12 hours with its processes ended. bochka runs until you stop it, saves the disk every minute and on stop, and a stopped machine costs nothing.

/dev/kvm, systemd and a desktop

Neither Fly nor Codespaces offers /dev/kvm or a graphical desktop, so emulators, nested VMs and computer-use agents need workarounds or do not run. Every bochka machine has Docker, systemd, /dev/kvm and a 60fps desktop with Chromium.

Agents driven from outside, keys kept out

On both you install agents yourself, write the code that prompts and watches them, and pass keys in as environment variables that agent code can read. bochka preinstalls coding agents with a prompt, steer and events API, and its credentials proxy keeps real keys outside.

Use bochka when your agents do real work for hours or days: full VMs with /dev/kvm, Docker and a desktop, a disk that survives every stop, forks of running machines, and coding agents with keys kept outside. Compare it one to one: bochka vs Fly.io Machines and bochka vs GitHub Codespaces.

Questions people ask

Is Fly.io Machines cheaper than GitHub Codespaces?

In every scenario we priced, yes, using Fly's lowest rate of shared vCPUs on a 1-year reservation. One agent running all month is $36 on Fly against $270 on Codespaces, and 50 agents in parallel are $487 against $3,019. bochka comes to $26 and $317 for the same two, with full cores and no reservation.

Which is faster, Fly.io Machines or GitHub Codespaces?

Neither has a comparable public measurement. Fly's shared vCPUs guarantee 6.25% of each core and get throttled under steady load, while its performance vCPUs get the full core. bochka did 26.69 Node.js build-and-test runs per second at 4 vCPU / 8 GB in StarSling's benchmark.

Can I run an AI agent 24/7 on either one?

On Fly yes, since a Machine runs until you stop it, though only its Volume keeps files across restarts. A codespace stops after 12 hours at most, even while in use, so 24/7 work needs a restart script. A bochka sandbox runs until you stop it and keeps its whole disk.

Can Fly.io Machines and GitHub Codespaces run Docker?

Both can: on Fly you install Docker inside the microVM yourself, and Codespaces runs Docker inside the dev container. Neither offers /dev/kvm, so Android emulators and nested VMs are not available. bochka has Docker, systemd and /dev/kvm on every machine.

Where do they run?

Fly runs Machines in 17 regions on six continents, and Codespaces in US East, US West, Europe West and Southeast Asia. bochka runs only in the EU, in Germany, Finland and France, with EU data residency.

Try bochka

Install the CLI, then run bochka new.

Product preview

More comparisons

Bochka product preview · Pricing, benchmarks and commands are illustrative. Sandbox provisioning is not connected.