OpenAI Containers vs Modal VM Sandboxes

OpenAI Containers are a tool inside OpenAI's model API: the model runs Python or shell commands in a container without sudo, and by default the container expires after 20 idle minutes. Modal VM Sandboxes are Linux VMs with their own kernel, root and Docker, which you start from code and which run for up to 24 hours.

The companies and products

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 a Responses call makes one. The model runs Python or shell commands in it on a fixed Debian 12 image without sudo. By default the container expires after 20 minutes without use; the create call can set a different idle time. 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.

Modal VM Sandboxes

Modal is a serverless cloud for AI work, and VM Sandboxes are the version of its sandboxes that run in a virtual machine with their own Linux kernel.

You create a VM Sandbox from Python, TypeScript or Go code with runtime="vm", run commands in it, and terminate it when the job is done. Modal built the runtime on the Rust-based Cloud Hypervisor, so Docker, FUSE, systemd and nested cgroups work, with the same API, images and prices as its gVisor sandboxes. It became generally available on 1 October 2026. It suits teams that want many agent machines next to Modal's inference and training.

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. “357th cheapest of 365” means 356 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 workloadOpenAI Containers: price rankModal VM Sandboxes: price rankboat: price rank
Software factory
100 at once · 4 vCPU / 8 GB · 2,200 sessions of 8 h a month
A coding agent needs root, Docker and a repo that stays. Modal VMs have root and Docker for up to 24 hours, and a filesystem snapshot carries the files to a new VM. Hosted OpenAI containers run without sudo and document no Docker. boat saves the disk at each stop with no code.
357th of 365, with limits
$17,371 a month
27th cheapest of 365
$633 a month
5th cheapest of 365
$634 a month
Always-on AI employees
50 machines 24/7 · 2 vCPU / 4 GB
An agent that lives on its machine all month needs a disk that survives. A Modal VM ends at 24 hours, so you snapshot it and boot a new one each day. An OpenAI container expires when idle and its files go with it. boat runs with no session cap once auto-stop (default 1 hour) is off on a paid plan.
344th of 361, with limits
$13,140 a month
Not ranked: misses a requirement6th cheapest of 361
$657 a month
Code interpreter bursts
100 at once · 1 vCPU / 2 GB · 200,000 sessions of 1 min a month
Short model-written code is what OpenAI Containers are built for: one tool line in an API call. Modal also fits short runs, billed per second, with up to 5,000 containers at once on Team. On boat each run counts against the plan's start limits.
198th of 336, with limits
$6,000 a month
Not ranked: misses a requirement189th 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
Modal fits sandboxes for your users on Team; you snapshot each user's filesystem and boot from it when the user comes back. OpenAI does not publish how many containers can run at once. A stopped boat sandbox keeps its disk for at least 14 days with no code.
349th of 349, with limits
$3,780 a month
Not ranked: misses a requirement3rd 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
Huge bursts of short rollouts suit Modal, with 5,000 containers at once on Team. OpenAI does not publish a container concurrency limit. boat's $2,000 plan charges for starts above 90 a minute and refuses them above 270.
195th of 349, with limits
$30,000 a month
163rd of 349, with limits
$11,982 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
355th of 359, with limits
$5,760 a month
Not ranked: misses a requirement10th cheapest of 359
$200 a month
CI runners
40 at once · 8 vCPU / 16 GB · 6,000 sessions of 12 min a month
CI needs Docker, root and open internet. Modal VMs have all three. Hosted OpenAI containers document no Docker or root, and Code Interpreter and Hosted Shell start with no outbound access. boat adds /dev/kvm on every sandbox for emulators; each CI job counts as a start.
347th of 374, with limits
$1,728 a month
170th of 374, with limits
$655 a month
2nd cheapest of 374
$86 a month
24/7 dev boxes
1 machine 24/7 · 4 vCPU / 8 GB
365th of 371, with limits
$1,051 a month
Not ranked: misses a requirement19th cheapest of 371
$26 a month
Computer-use agents
50 at once · 4 vCPU / 8 GB · 20,000 sessions of 15 min a month
OpenAI's Agents API has a hosted browser for computer use. On Modal you set it up: its runnable example installs Xvfb, x11vnc, noVNC and Chromium. boat ships a 1920x1080, 60 fps desktop and Chrome you can embed.
353rd of 367, with limits
$5,280 a month
Not ranked: misses a requirement7th cheapest of 367
$200 a month
Browser-use agents
50 at once · 2 vCPU / 4 GB · 30,000 sessions of 10 min a month
335th of 356, with limits
$1,440 a month
Not ranked: misses a requirement7th 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
334th of 343, with limits
$1,755 a month
Not ranked: misses a requirement6th 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
307th of 327, with limits
$35,100 a month
Not ranked: misses a requirement73rd 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
Parallel attack runs need open internet and Docker. Modal VMs have both. Hosted OpenAI containers document no Docker. boat fits too, within its start limits per plan.
310th of 351, with limits
$870 a month
27th cheapest of 351
$464 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

FeatureOpenAI ContainersModal VM Sandboxesboat
What it isA sandbox tool the model uses inside OpenAI's APIA VM you create from Python, TypeScript or Go code on Modal's serverless cloudA cloud VM you create, keep, stop and reach from outside
IsolationA fully sandboxed virtual machine; hypervisor not namedVM with its own Linux kernel on Cloud HypervisorFull VM with its own kernel, on physical hosts dedicated to boat (AMD Ryzen 7 9700X and Ryzen 9 9950X); vCPUs are shared
Root, Docker, systemdCommands do not run with sudo; Docker is not documented. You set it up: connect the Agents API to a self-hosted sandbox where you control the machineYes; you start dockerd yourselfYes, in every sandbox
Nested virtualizationNot documented for hosted containersEnterprise plan only, as an experimental option/dev/kvm on every sandbox
CPU benchmark (V8 Web Tooling, 4 vCPU / 8 GB, StarSling run of 3 October 2026)Not in the public benchmarks we use; vCPU per size not publishedVM runtime 15.48 runs/s, gVisor 12.60, both rank 7 of 15 (shared)28.06 runs/s, rank 2 of 15 (shared), on a Ryzen 9 9950X host
Longest sessionBy default expires after 20 minutes without use; expires_after can set a longer idle time, and no maximum is published24 hours (default 5 minutes); continue in a new sandbox from a filesystem snapshotAuto-stop defaults to 1 hour; set up to 30 days, or turn it off on a paid plan for no session cap
Files after the sessionData is discarded when the container expires. Agents API publishes files in /workspace/outputs as downloadable artifactsNo paused state. You set it up: snapshot_filesystem() before the end and boot a new sandbox from it (kept 30 days by default, or with no expiry), or keep files in a VolumeDisk saved every minute and at each stop with no code. A stopped sandbox has no compute charge and keeps its disk for at least 14 days; a saved snapshot keeps it longer
Fork and snapshotsNo fork call documented. You set it up: create a new container and upload the same filesSnapshot a running sandbox's filesystem and boot any number of new sandboxes from it; memory snapshots in alphaFork a running sandbox from its last 1-minute disk snapshot; saved snapshots as templates; no memory snapshots
Inbound accessNo inbound ports documented for hosted containers; you reach them through the APIEncrypted and raw TCP tunnels, connect tokens, inbound IP allowlistSSH, token-gated HTTPS URLs for up to 50 ports, raw TCP (IPv6 only on sandboxes without their own IPv4)
Outbound internetCode Interpreter and Hosted Shell: off until an admin sets a domain allowlist. Agents API sandboxes: on by default, can be limited to 1 to 100 hostsOpen by default; block all, IP-range allowlist or domain allowlist (beta)Open internet, no provider-side allowlist
Keeping API keys out of the sandboxdomain_secrets: a sidecar adds the real header for approved domains, the model sees a placeholderYou set it up: run a credential-injecting proxy in a Sidecar (experimental), from an official exampleOptional AI credentials proxy ($1 per day on, plus $1 per 1,000 requests) for model providers and custom HTTPS APIs
Coding agentsAgents API (beta) drives a managed Codex harness from outside, with steering, events and webhooksYou install the harness in the image; official examples cover the Claude Agent SDK and OpenCodeSeven harnesses installed, including Claude Code, Codex and OpenCode, with a prompt, steer and events API
Desktop and computer useHosted browser for the Agents API computer_use toolNot built in. You set it up: Modal's runnable example installs Xvfb, x11vnc, noVNC, Chromium and a Browser Use agentBuilt-in 1920x1080, 60 fps desktop and Chrome, computer tools for agents, embeddable stream
RegionsUS or EU processing for Code Interpreter; Agents API can also drive a sandbox you hostUS, EU and Asia-Pacific; pinning a region costs 1.15x to 1.75xGermany, Finland and France; you cannot pick a region, and there is no US or Asia region
Every feature Battleships tracks (43)
FeatureOpenAI ContainersModal VM Sandboxesboat
Full VM (own kernel)YesYesYes
Docker insideNo documented wayYesYes
Nested virtualizationNo documented wayYesYes
RootNo documented wayYesYes
SystemdNot publishedYesYes
Desktop GUIYesWith your own setupYes
BrowserYesWith your own setupYes
Computer-use APIYesWith your own setupYes
SSHNo documented wayWith your own setupYes
Persistent diskNo documented wayWith your own setupYes
Pause/resumeNo documented wayNo documented wayYes
Automatic snapshotsNo documented wayNo documented wayYes
Fork/cloneNo documented wayYesYes
Live fork (no pause)No documented wayNot publishedYes
Memory forkNo documented wayYesNo documented way
Custom image (Docker or snapshot)No documented wayYesYes
≥24 h sessionsYesYesYes
Idle auto-stopYesYesNo documented way
Wake on requestNo documented wayNo documented wayNo documented way
HTTPS preview URLsNo documented wayYesYes
Raw TCP inboundNo documented wayYesYes
Public IPv4No documented wayNo documented wayNo documented way
Egress allowlistYesYesNo documented way
Secret proxyYesWith your own setupYes
Secret proxy for any APIYesNo documented wayYes
Preinstalled agentsNo documented wayWith your own setupYes
Agent harness APIYesNo documented wayYes
MCP serverNo documented wayNo 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-hostingYesNo documented wayNo documented way
BYOCNo documented wayNo documented wayNo documented way
Open sourceNo documented wayNo documented wayNo documented way
Scoped API keysNot publishedNot publishedYes
Spend limitsNot publishedNot publishedYes
Usage per sandbox (API)No documented wayNot publishedYes
Audit logsNot publishedYesNo documented way
SSOYesYesNo documented way
SOC 2YesYesNo documented way
HIPAAYesYesNo documented way
EU data residencyYesYesNo documented way
Zero data retentionNot publishedNot publishedYes

Performance

OpenAI ContainersNot measured
Modal VM Sandboxes15.48 runs/s
boat28.06 runs/s

In StarSling's run of 3 October 2026 (run 37073680030), on the V8 Web Tooling Benchmark at 4 vCPU / 8 GB, Modal's VM runtime did 15.48 runs/s and its gVisor runtime 12.60, both rank 7 of 15 (shared). boat did 28.06, second of 15. StarSling ran Modal with cpu=4 and the sandbox saw 4 CPUs (PR #121). 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. Providers ran on different hardware in different regions. OpenAI Containers are not in the public benchmarks we use, so we cannot say how fast they are, and OpenAI does not publish their vCPU.

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. Modal VM Sandboxes measured on: VM Sandbox, request = size. 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. OpenAI Containers 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.

ScenarioOpenAI Containers, a monthModal VM Sandboxes, 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
$228 · API pay as you go · with limits$0 · Starter$20 · $20/mo
One agent that never stops
4 vCPU / 8 GB, 50 GB disk, running 24/7 all month
$1,051 · API pay as you go · with limits$109 · Starter · 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
$11,405 · API pay as you go · with limits$1,480 · Starter$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
$1,620 · API pay as you go · with limits$579 · Team$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
$6,000 · API pay as you go · with limits$1,911 · Team · with limits$8,800 · $2000/mo · with limits

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, because OpenAI does not publish the vCPU per size.

Modal VM Sandboxes: Modal bills by the second for the larger of the CPU and memory you request and what you use, until the sandbox ends. It prices CPU per physical core, and one core equals two vCPUs: a 4 vCPU / 8 GiB sandbox is 2 cores + 8 GiB, $0.476 an hour. StarSling ran Modal with cpu=4 and the sandbox saw 4 CPUs (PR #121); sized that way, Modal bills 4 cores, $0.76/h. Starter is $0 with $30 of credit a month, Team is $250 a month with $100 of credit, and pinning a region multiplies the price by 1.15x to 1.75x.

Modal VM Sandboxes: Plans cost $20, $100, $500 or $2,000 a month, and the whole plan price comes back as VM time for that month. A default 4 vCPU / 8 GB sandbox costs $0.036 an hour, billed per second while it runs, busy or idle. The $20 plan includes 200 starts a day; extra starts cost $0.03 to $0.07 each. A stopped sandbox has no compute charge. Saved snapshots above the included count and the AI credentials proxy still charge while sandboxes are stopped.

Limits in those scenarios

OpenAI Containers fit none of the five scenarios as written: hosted containers discard their files when they expire, document no Docker or root, and do not publish the vCPU per size. Code Interpreter and Hosted Shell start with no internet, and how many containers can run at once is not published. Modal VM Sandboxes fit the workday agent, the 50-agent fleet and the user sandboxes. The always-on agent does not fit as-is, because a Modal VM ends at 24 hours; you snapshot and boot a new VM each day. For the 1,000-job burst, Modal's bill assumes a small CPU request that bursts on shared CPU, which is not guaranteed. boat's limits: auto-stop defaults to 1 hour, and the $2,000 plan charges for starts above 90 a minute and refuses them above 270, so boat does not fit the burst either. A boat resume is like a reboot, and a machine failure loses what was written after the last snapshot.

ScenarioOpenAI ContainersModal VM Sandboxesboat
One coding agent, workdays
  • 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 for this scenarioNone for this scenario
One agent that never stops
  • 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
  • Starter: sessions capped at 24 h
None for this scenario
50 agents in parallel
  • 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 for this scenarioNone for this scenario
Sandboxes for your users
  • 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 for this scenarioNone for this scenario
1,000 short jobs at once
  • 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)
  • shared vCPUs on this tier (Modal (VM Sandboxes) sells dedicated cores separately as “VM Sandbox, request = size”): heavy, sustained CPU use can be slowed by other tenants
  • 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 OpenAI Containers when

your app already calls OpenAI models and the model only needs to run short pieces of code or shell commands 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 reach only chosen hosts: Code Interpreter and Hosted Shell start with no outbound access at all.
  • Nothing to run or clean up. Useful for short jobs: OpenAI creates the container, bills it by the minute, and deletes it when idle.

Use Modal VM Sandboxes when

you need a real VM with Docker for jobs that finish within a day, huge bursts of them, regions outside Europe, or strict outbound rules.

  • A real VM with root and Docker. Useful if the agent installs packages or runs containers: each sandbox has its own Linux kernel, root, Docker and systemd.
  • Very large bursts. Useful for huge batches of short jobs: Modal runs 5,000 containers at once on the Team plan and publishes no per-start fee.
  • Regions, outbound rules and one platform. Useful if you need the US or Asia-Pacific, strict outbound rules, or already serve models on Modal and want sandboxes on the same account.

Where boat fits

If your agent works for hours or days on the same machine, boat keeps that machine with no code. An OpenAI container expires after 20 idle minutes by default and its files go with it. A Modal VM ends within 24 hours, and you carry its files over with a filesystem snapshot. boat gives each agent a full VM with a desktop and coding agents built in, within its plan's start limits.

A disk that stays, with no code

An OpenAI container's files are discarded when it expires. On Modal you snapshot the filesystem before the 24-hour end and boot a new VM from it, or use a Volume. boat saves the disk every minute and at each stop, and keeps a stopped sandbox's disk for at least 14 days.

Desktop, browser and agents ready

OpenAI offers a hosted browser and a Codex harness through its Agents API beta. On Modal you install a desktop, a browser and an agent yourself, from Modal's examples. boat ships a 60 fps desktop, Chrome and seven coding-agent harnesses.

Root and a faster CPU in one run

OpenAI commands run without sudo and its vCPU per size is not published. Modal has root; in StarSling's run of 3 October 2026 its VM runtime did 15.48 runs/s and boat did 28.06 at 4 vCPU / 8 GB. That boat sandbox ran on a Ryzen 9 9950X host; boat also uses other hosts.

Use boat when your agents work for hours or days on a machine they come back to: root, Docker, a desktop and coding agents on a VM that keeps its disk across stops. Compare it one to one: boat vs OpenAI Containers and boat vs Modal VM Sandboxes.

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 OpenAI Containers cheaper than Modal VM Sandboxes?

No, in our scenarios Modal costs less. Sandboxes for your users cost $1,620 a month on OpenAI and $579 on Modal, and 50 agents in parallel cost $11,405 against $1,480. OpenAI also bills model tokens on top. On boat the same scenarios cost $200 and $317.

Which is faster?

In StarSling's run of 3 October 2026, Modal's VM runtime did 15.48 runs/s and its gVisor runtime 12.60 on the V8 Web Tooling Benchmark at 4 vCPU / 8 GB. boat did 28.06 on a Ryzen 9 9950X host. OpenAI Containers are not in that benchmark, and OpenAI does not publish their vCPU.

Can OpenAI Containers run Docker?

OpenAI's docs say hosted shell commands do not run with sudo, and no Docker support is documented. For full control, the Agents API can drive a sandbox you host yourself. Modal VM Sandboxes run Docker if you start dockerd, and boat has root, systemd and Docker in every sandbox.

How long can each one run?

By default an OpenAI container expires after 20 minutes without use, and its data is discarded. A Modal VM Sandbox runs 5 minutes by default and 24 hours at most; a filesystem snapshot carries its files to a new one. A boat sandbox auto-stops after 1 hour by default, and has no session cap once auto-stop is off on a paid plan.

Can I open a web app running inside each one?

OpenAI documents no inbound ports for hosted containers; you reach them through the API. Modal gives encrypted and raw TCP tunnels. boat gives token-gated HTTPS URLs for up to 50 ports, raw TCP and SSH.

Try boat

Install the CLI, then run boat new.

7-day free trial

More comparisons