GitHub Codespaces vs OpenAI Containers

GitHub Codespaces gives a developer a Linux dev container with Docker and sudo for a GitHub repository, kept between sessions but stopped after 12 hours at most. OpenAI Containers are short-lived boxes inside OpenAI's API where the model runs Python or shell commands without sudo, and they are deleted after 20 minutes without use.

The companies and products

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 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.

OpenAI Containers

OpenAI Containers are the sandboxes OpenAI runs for its own model tools: Code Interpreter, Hosted Shell and the Agents API's hosted sandbox.

This is a different kind of product from boat: a tool inside OpenAI's model API, not a machine you rent. You create a container through the API or let a Responses call make one, and the model runs Python or shell commands in it on a fixed Debian 12 image without sudo, until it expires after 20 minutes without use. It is built for apps that already call OpenAI models and want them to run code, read files and make charts without running any servers.

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. “274th cheapest of 367” means 273 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 workloadGitHub Codespaces: price rankOpenAI Containers: price rankboat: price rank
Software factory
100 at once · 4 vCPU / 8 GB · 2,200 sessions of 8 h a month
Codespaces gives a coding agent Docker and a disk that stays but stops it after 12 hours; an OpenAI container has no sudo, no Docker and loses its files when it expires, while boat gives a full VM that keeps running.
274th of 367, with limits
$4,618 a month
356th of 367, with limits
$17,371 a month
3rd cheapest of 367
$634 a month
Always-on AI employees
50 machines 24/7 · 2 vCPU / 4 GB
Neither fits an assistant that lives on its machine all month: a codespace stops after 12 hours, and an OpenAI container must be touched every 20 minutes or it is deleted.
309th of 366, with limits
$6,970 a month
341st of 366, with limits
$13,140 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
This is what OpenAI Containers are built for, since the model runs its code in the same API call; a codespace builds a dev container on a new VM first.
288th of 345, with limits
$619 a month
194th of 345, with limits
$6,000 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
A codespace belongs to a GitHub user on a repository and an OpenAI container has no inbound access, so neither is a clean way to hand machines to your own users; boat gives each one a preview URL and SSH.
281st of 361, with limits
$1,964 a month
361st of 361, with limits
$3,780 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
282nd of 360, with limits
$9,489 a month
191st of 360, with limits
$30,000 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
295th of 364, with limits
$1,519 a month
360th of 364, with limits
$5,760 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
Codespaces has Docker and open internet but no fork or snapshot API; OpenAI documents no Docker or root, and its Code Interpreter containers start with no internet.
314th of 377, with limits
$909 a month
345th of 377, with limits
$1,728 a month
4th cheapest of 377
$86 a month
24/7 dev boxes
1 machine 24/7 · 4 vCPU / 8 GB
Codespaces is the better dev box of the two, a polished VS Code environment per repo, though it stops after 12 hours at most; OpenAI containers have no SSH and no disk that stays.
130th of 368, with limits
$270 a month
362nd of 368, with limits
$1,051 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
A codespace has an editor and a terminal but no graphical desktop; OpenAI has a hosted browser in the Agents API beta, and boat streams a 60fps desktop you can embed.
267th of 369, with limits
$1,367 a month
351st of 369, with limits
$5,280 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
275th of 367, with limits
$678 a month
328th of 367, with limits
$1,440 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
310th of 346, with limits
$922 a month
328th of 346, with limits
$1,755 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
280th of 338, with limits
$18,637 a month
311th of 338, with limits
$35,100 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
boat can fork one prepared machine into many while it runs; on Codespaces every copy starts again from the repository, and OpenAI has no fork.
267th of 360, with limits
$445 a month
308th of 360, with limits
$870 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

FeatureGitHub CodespacesOpenAI Containersboat
What it isA cloud dev environment for a GitHub repository, opened in VS Code, the browser or the CLIA sandbox tool the model uses inside OpenAI's APIA cloud VM you create, keep, stop and reach from outside, driven from code
IsolationA Docker container on its own newly built VM, with its own virtual networkA fully sandboxed virtual machine; hypervisor not namedFull VM with its own kernel on dedicated AMD Ryzen 9 9950X hosts
Root, Docker and nested virtualizationDocker and sudo inside the dev container; /dev/kvm not documentedCommands do not run with sudo; no Docker or /dev/kvm documentedRoot, systemd, Docker and /dev/kvm on every machine
How long it runsStops after 30 idle minutes by default (up to 240) and after 12 hours at most, even while in useExpires after 20 minutes without use; Agents API sandboxes after an hour without activityRuns until you stop it; no session cap on paid plans
Files after a stopFiles are kept and storage is billed; stopped codespaces are deleted after 30 days by defaultData is discarded when the container expires and cannot be recoveredDisk saved every minute and on stop; a stopped sandbox keeps its disk and costs nothing
Fork and snapshotsNo copy or snapshot endpoint; new codespaces start from a repo, branch, pull request or prebuildNo fork; templates save configuration, not a running workspaceFork a running sandbox with its disk; named snapshots as templates
Starting imageDev container config in the repository, with prebuilds built by GitHub ActionsFixed Debian 12 image; you upload files or skills into each containerNamed snapshots of a set-up machine, shareable by code; no Dockerfile builds
Machine size2, 4, 8, 16 or 32 cores, with 4 GB of memory per core1, 4, 16 or 64 GB of memory; vCPU not published4 vCPU / 8 GB by default, up to 16 vCPU / 32 GB
Reaching it from outsideA URL per forwarded port and SSH through the GitHub CLI; no public IPNone; you reach the container only through the APISSH, HTTPS URLs for up to 50 ports with tokens, raw TCP
Outbound internetOpen internet; GitHub says there is no way to restrict itCode Interpreter and Hosted Shell: off until an admin sets an org domain allowlist; Agents API sandboxes open by defaultOpen internet on every plan; no provider-side allowlist
Keeping API keys out of the sandboxSecrets are copied into the codespace as environment variablesdomain_secrets: a sidecar adds the real header for approved domains, the model sees a placeholderCredentials proxy for model providers and any HTTPS API; switch a credential to another account when credits run out
Coding agentsGitHub Copilot as a VS Code extension; other agents you install and run yourselfAgents API (beta) drives a managed Codex harness from outside, with steering and eventsClaude Code, Codex, OpenCode and more preinstalled, with a prompt, steer and events API
Desktop and computer useVS Code, JupyterLab and a terminal; no graphical desktopHosted browser for the Agents API computer_use tool60fps desktop and Chromium, computer use, embeddable stream
RegionsUS East, US West, Europe West and Southeast AsiaUS or EU processing for Code Interpreter; Agents API data residency in the US onlyEU only: Germany, Finland, France
Every feature Battleships tracks (43)
FeatureGitHub CodespacesOpenAI Containersboat
Full VM (own kernel)YesYesYes
Docker insideYesNoYes
Nested virtualizationNoNoYes
RootYesNoYes
SystemdNot publishedNot publishedYes
Desktop GUINoYesYes
BrowserNoYesYes
Computer-use APINoYesYes
SSHYesNoYes
Persistent diskYesNoYes
Pause/resumeYesNoYes
Automatic snapshotsNoNoYes
Fork/cloneNoNoYes
Live fork (no pause)NoNoYes
Memory forkNoNoNo
Custom image (Docker or snapshot)YesNoYes
≥24 h sessionsNoYesYes
Idle auto-stopYesYesNo
Wake on requestNoNoNo
HTTPS preview URLsYesNoYes
Raw TCP inboundNoNoYes
Public IPv4NoNoNo
Egress allowlistNoYesNo
Secret proxyNoYesYes
Secret proxy for any APINoYesYes
Preinstalled agentsNoNoYes
Agent harness APINoYesYes
MCP serverNoNoNo
GPUNoNoNo
WindowsNoNoNo
Arm64NoNoNo
Self-hostingNoYesNo
BYOCNoNoNo
Open sourceNoNoNo
Scoped API keysNot publishedNot publishedYes
Spend limitsYesNot publishedYes
Usage per sandbox (API)NoNoYes
Audit logsYesNot publishedNo
SSOYesYesNo
SOC 2YesYesNo
HIPAANoYesNo
EU data residencyYesYesYes
Zero data retentionNot publishedNot publishedYes

Performance

GitHub CodespacesNot measured
OpenAI ContainersNot measured
boat26.69 runs/s

There is no comparable measurement for either: GitHub Codespaces and OpenAI Containers were not in the public CPU benchmark runs we use, and OpenAI does not publish how many vCPU each container size gets. boat did 26.69 Node.js build-and-test runs per second at 4 vCPU / 8 GB in StarSling's run of 2026-09-29, on dedicated AMD Ryzen 9 9950X hosts.

Node.js build-and-test loop at 4 vCPU / 8 GB, higher is better. Measured with the open hpc-sandbox-benchmarks suite. GitHub Codespaces and OpenAI Containers 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.

ScenarioGitHub Codespaces, a monthOpenAI Containers, 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
$51 · Personal account: GitHub Free$228 · API pay as you go · with limits$20 · $20/mo
One agent that never stops
4 vCPU / 8 GB, 50 GB disk, running 24/7 all month
$270 · Personal account: GitHub Free · with limits$1,051 · API pay as you go · 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
$3,019 · Personal account: GitHub Free$11,405 · API pay as you go · 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
$850 · Personal account: GitHub Free · with limits$1,620 · API pay as you go · 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
$1,889 · Personal account: GitHub Free · with limits$6,000 · API pay as you go · with limits$2,000 · $2000/mo · with limits

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, 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 and organizations do not.

OpenAI Containers: OpenAI bills each container session by the minute for the memory size you pick, with a 5-minute minimum, and model tokens are billed separately on top. There is no plan fee; the scenarios use the 16 GB size for 8 GB needs and the 4 GB size for 4 GB needs, since vCPU is not published.

OpenAI Containers: 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

A codespace stops after 12 hours at most, so it does not fit the always-on scenario without a restart script, and GitHub does not publish how many can run at once, so 300 user sandboxes and 1,000 short jobs are not confirmed. OpenAI Containers fit none of the five scenarios as written: no disk that stays, no Docker, no internet until an admin sets an allowlist, and no published vCPU or concurrency limit. On boat the 1,000-job burst is limited by starts per minute, so the $2,000 plan queues those starts.

ScenarioGitHub CodespacesOpenAI Containersboat
One coding agent, workdaysNone that bite
  • no open internet: sandboxes reach only an allowlist (domains your org admin adds to the allow list)
  • missing persistent disk
  • machine size not published
  • different kind of product: code interpreter
None that bite
One agent that never stops
  • Personal account: GitHub Free: sessions capped at 12 h
  • no open internet: sandboxes reach only an allowlist (domains your org admin adds to the allow list)
  • missing persistent disk
  • machine size not published
  • different kind of product: code interpreter
None that bite
50 agents in parallel
  • how many machines can run at once: limit not published, probably fine at 50 (the typical published limit is 50)
  • no open internet: sandboxes reach only an allowlist (domains your org admin adds to the allow list)
  • missing persistent disk, Docker inside
  • machine size not published
  • different kind of product: code interpreter
None that bite
Sandboxes for your users
  • not confirmed: how many machines can run at once (you need 300; the typical published limit is 50)
  • no open internet: sandboxes reach only an allowlist (domains your org admin adds to the allow list)
  • machine size not published
  • different kind of product: code interpreter
  • 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
  • not confirmed: how many machines can run at once (you need 1,000; the typical published limit is 50)
  • no open internet: sandboxes reach only an allowlist (domains your org admin adds to the allow list)
  • machine size not published
  • different kind of product: code interpreter
  • 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 GitHub Codespaces when

your developers want a ready VS Code environment for a GitHub repository, with Docker and files that stay between sessions, in the US, EU or Asia.

  • Built into GitHub. Useful if your team lives on GitHub: open a ready dev container from any repo, branch or pull request.
  • A real workspace that keeps your files. Useful for developers: a codespace has sudo, Docker and a disk that stays between sessions, which OpenAI containers do not.
  • 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.

Use OpenAI Containers when

your app already calls OpenAI models and the model only needs to run short pieces of Python or shell on files you give it.

  • Built into the model call. Useful if your app already calls OpenAI models: one tool line in a request gives the model a place to run code.
  • Locked-down network by default. Useful if code must only reach chosen hosts: Code Interpreter and Hosted Shell have no outbound access until an admin allows domains.
  • Keys the model never sees. Useful when code calls approved APIs: a sidecar adds the real secret header, and the model only sees a placeholder.

Where boat fits

If what you are really running is agents that work for hours or days, neither is built for it: Codespaces is a dev box for people that stops at 12 hours, and OpenAI Containers are a code tool that forgets everything after 20 idle minutes. boat gives each agent a full VM you drive from code, that keeps running, keeps its disk and can be reached from outside.

Machines that keep running and keep their work

A codespace stops at 12 hours even while in use, so you need a restart script and its processes end. An OpenAI container loses its clone and installs after 20 idle minutes. boat runs until you stop it and saves its disk every minute.

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

OpenAI commands run without sudo or Docker, and Codespaces documents no /dev/kvm or graphical desktop. Emulators, microVMs and computer-use agents have nowhere to run. Every boat machine has root, Docker, systemd, /dev/kvm and a 60fps desktop.

Agents you drive from outside, keys kept out

On Codespaces you start and watch each agent over SSH yourself, with API keys in environment variables any code can read; OpenAI only drives its own Codex harness. boat preinstalls Claude Code, Codex and others, with a credentials proxy for any HTTPS API.

Use boat when your code starts and drives agents that work for hours or days: full VMs with root, Docker and /dev/kvm, a desktop and open ports, built-in coding agents with keys kept outside, and machines that keep their work and fork while running. Compare it one to one: boat vs GitHub Codespaces and boat vs OpenAI Containers.

Questions people ask

Is GitHub Codespaces cheaper than OpenAI Containers?

In every scenario we priced, yes: one coding agent on workdays is $51 a month on Codespaces against $228 on OpenAI, and 50 agents in parallel come to $3,019 against $11,405. OpenAI also bills model tokens on top. On boat the same workday agent is $20 a month and the 50 agents $317.

Which is faster, Codespaces or OpenAI Containers?

Neither has a comparable CPU measurement: both were missing from the public benchmark runs we use, and OpenAI does not publish vCPU per container size. boat did 26.69 Node.js build-and-test runs per second at 4 vCPU / 8 GB.

Can GitHub Codespaces or OpenAI Containers run Docker?

Docker works inside a codespace through dev container features, and you have sudo. OpenAI's docs say hosted shell commands do not run with sudo, and no Docker support is documented. Every boat machine has root, Docker, systemd and /dev/kvm.

How long can each one run?

A codespace stops after 30 idle minutes by default and after 12 hours at most, even while in use, but keeps its files. An OpenAI container expires after 20 minutes without use, and its data is discarded. A boat sandbox has no session cap on paid plans and keeps its disk when it stops.

Can I open a web app running inside either one?

In a codespace, yes: each forwarded port gets a URL that can be private, organization-wide or public. OpenAI containers have no ports, URLs or SSH; you reach them only through the API. boat gives each sandbox HTTPS URLs for up to 50 ports, raw TCP and SSH.

Is boat SOC 2 compliant?

SOC 2 is in progress. We're open about where we stand: live status at status.ascii.dev and our data retention policy at docs.boat.dev/data-retention.

Try boat

Install the CLI, then run boat new.

7-day free trial

More comparisons