Cloudflare Sandbox vs Agent 37
Cloudflare Sandbox gives you containers inside the Workers platform. They sleep when idle, wake on the next request, and keep files through snapshots, automatic saves or R2 that your code sets up. Agent 37 gives each user an always-on agent machine that keeps its disk and can sleep with its memory saved.
The companies and products
Cloudflare Sandbox
Cloudflare Sandbox SDK runs untrusted or AI-generated code in Linux containers on Cloudflare's network, driven from a Cloudflare Worker.
Each sandbox is a Cloudflare Container backed by a Durable Object. Each container runs in its own Firecracker microVM with its own kernel and network. You build a linux/amd64 image, pick an instance type of up to 4 vCPU and 12 GiB, and reach the sandbox through your own Worker. The disk resets when the container stops, and your code keeps files with snapshots, automatic saves, R2 backups or R2 bucket mounts. It suits teams already on Workers who want sandboxes that sleep when idle. For code that only calls known methods, Cloudflare also offers Dynamic Workers, which run JavaScript in V8 isolates.
- Largest instance
- 4 vCPU, 12 GiB memory, 20 GB disk
- Compliance
- Cloudflare holds a SOC 2 Type II report
Agent 37
Agent 37 hosts AI agents, one isolated, always-on sandbox per user, behind one API.
You create an instance from a template (Hermes, OpenClaw, Claude Code, Codex, OpenCode, Pi, Grok or your own Docker image) and talk to it through a chat API, files, exec, SSH and HTTPS URLs. The default instance is a container enforced by gVisor. A VM type gives a full Linux machine with its own kernel for Docker, Kubernetes and Android emulators. It is built for companies that give each of their customers an agent.
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. “43rd cheapest of 361” means 42 of the other 360 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 | Cloudflare Sandbox: price rank | Agent 37: price rank | boat: price rank |
|---|---|---|---|
| Software factory 100 at once · 4 vCPU / 8 GB · 2,200 sessions of 8 h a month A long coding session needs its files to stay put. Agent 37 and boat keep the disk with no code. Cloudflare starts from a fresh disk after sleep unless your code saves a snapshot or works in a mounted R2 bucket. | 192nd of 365, with limits $1,543 a month | 4th cheapest of 365 $551 a month | 5th cheapest of 365 $634 a month |
| Always-on AI employees 50 machines 24/7 · 2 vCPU / 4 GB Agent 37 is built for always-on assistants that sleep with their memory kept. On Cloudflare the disk resets on sleep unless your code snapshots it, schedules automatic saves or mounts R2. boat keeps the disk with no code, but a resume is like a reboot. | 43rd cheapest of 361 $2,188 a month | Cheapest of 361 $279 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 suit short code runs: Cloudflare bills CPU only while busy, and Agent 37's small default sandboxes cost little. boat includes a set number of starts per plan, and extra starts cost $0.03 to $0.07, so large bursts cost more on boat. | 17th cheapest of 336 $144 a month | Cheapest of 336 $22 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 Cloudflare limits an account by resources (1,500 vCPU at once by default, higher on request), not by sandbox count. Agent 37 runs up to 1,000 awake instances once you have topped up $1,000. boat plans run 100 to 2,000 at once, with start limits per plan. | 19th cheapest of 349 $731 a month | Cheapest of 349 $79 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 | 147th of 349, with limits $9,428 a month | 9th of 349, with limits $363 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 | 60th cheapest of 359 $818 a month | Cheapest of 359 $58 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 Docker builds need disk and a full Docker setup. Cloudflare has 20 GB of disk at most and runs Docker with iptables turned off. Agent 37 runs Docker on its VM type, at 2.5x its default compute rate. boat runs Docker with BuildKit in every sandbox. | 303rd of 374, with limits $704 a month | 227th of 374, with limits $96 a month | 2nd cheapest of 374 $86 a month |
| 24/7 dev boxes 1 machine 24/7 · 4 vCPU / 8 GB Agent 37 and boat keep a machine and its disk around the clock. Cloudflare starts from a fresh disk after sleep unless your code snapshots it or works in a mounted R2 bucket. | 123rd cheapest of 371 $93 a month | 3rd cheapest of 371 $12 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 Cloudflare removed its built-in desktop in SDK 0.10.2; you build one into your image or use the separate Browser Run service. Agent 37 adds a noVNC desktop through a template build. boat streams a 60 fps desktop in every sandbox. | 207th of 367, with limits $460 a month | 3rd cheapest of 367 $120 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 | 68th of 356, with limits $233 a month | 47th of 356, with limits $29 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 | 102nd cheapest of 343 $286 a month | Cheapest of 343 $32 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 | 168th of 327, with limits $5,741 a month | 39th of 327, with limits $648 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 Agent 37 and boat can fork a machine; both copy the disk, and the fork boots fresh. On Cloudflare you snapshot a running sandbox and start new ones from it. boat also has raw ports over IPv6 and /dev/kvm. | 25th cheapest of 351 $325 a month | Cheapest of 351 $43 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 | Cloudflare Sandbox | Agent 37 | boat |
|---|---|---|---|
| Isolation | Firecracker microVM per container, own kernel and network | gVisor by default; full VM as an opt-in instance type | Every sandbox is a full VM with its own kernel, on a physical host dedicated to boat (AMD Ryzen 7 9700X or Ryzen 9 9950X); vCPUs are shared |
| Largest machine | 4 vCPU / 12 GiB / 20 GB disk | 4 vCPU on every type; up to 20 GB disk at 4 vCPU / 8 GB on the default type, up to 100 GB on VM and Performance | 16 vCPU / 32 GB / 251 GB disk (needs the $100 plan or higher) |
| Files between sessions | Disk is fresh after sleep; keep files with snapshots (public beta, 30 days), scheduled automatic saves, R2 backups or a mounted R2 bucket | Disk kept until you delete the instance; billed while stopped or asleep | Disk saved every minute and at each stop, with no code; kept at least 14 days after a stop, longer as a saved snapshot |
| Sleep when idle | Stops after inactivity and wakes on the next request | Opt-in auto-sleep (default 15 minutes) with memory checkpointed, wakes on the next request | No idle timer; auto-stop 1 hour after create or resume by default (up to 30 days, or off on paid plans) |
| Fork | Snapshot or back up a running sandbox, then start new sandboxes from it; no one-call fork | Fork any running, stopped or sleeping instance (disk copy, the fork boots fresh) | Fork a running sandbox in one call, from its last 1-minute snapshot |
| Docker inside | docker:dind with iptables and IP forwarding turned off | On the VM type, at 2.5x the default compute rate; the default gVisor type cannot run a Docker daemon | Docker with BuildKit and Compose, root and systemd in every sandbox |
| Nested virtualization | Not documented | /dev/kvm on the VM type, with a ready Android template | /dev/kvm in every sandbox |
| Desktop | Built-in desktop removed in SDK 0.10.2; headless browsers through the separate Browser Run service | You set it up: noVNC desktop through a template build, or the Ubuntu VM template | 1920x1080, 60 fps desktop and Chrome, computer tools, embeddable stream; no GPU |
| Inbound traffic | HTTP and WebSocket previews routed through your Worker; SSH; no raw TCP inbound or public IP | HTTPS URL per port, signed URLs, custom domains; no public IP; SSH through a WebSocket tunnel | Up to 50 HTTPS URLs, token-gated by default; SSH; raw ports over public IPv6; the IP changes at each resume |
| Egress control | allowedHosts deny-by-default list plus outbound handlers you write in Worker code | No provider-side allowlist documented | No provider-side allowlist |
| Keeping keys out of the sandbox | Your outbound handler adds the token for any HTTP or HTTPS host; you write the code | Managed LLM, search and Composio through a per-instance token; your own keys go in as env vars | Optional paid proxy ($1 a day while on, plus $1 per 1,000 requests) for model providers and custom HTTPS APIs; other secrets enter the sandbox |
| Coding agents | Guides for Claude Code, Codex, OpenCode and Pi in your image | Hermes, OpenClaw, Claude Code, Codex, Grok, OpenCode and Pi templates, with a chat API per instance | Seven installed (Claude Code, Codex, pi, OpenCode and more), with a prompt, steer and events API |
| Custom images | Any linux/amd64 container image | Your own linux/amd64 Docker image as a template | No; start from boat's Ubuntu 24.04 image or a saved snapshot |
| Regions | Several regions across Cloudflare's network; pin to a region or jurisdiction | Dedicated servers in the United States | Germany, Finland and France; no US or Asia region; you cannot pick one |
Every feature Battleships tracks (43)
| Feature | Cloudflare Sandbox | Agent 37 | boat |
|---|---|---|---|
| Full VM (own kernel) | Yes | No documented way | Yes |
| Docker inside | Yes | No documented way | Yes |
| Nested virtualization | No documented way | No documented way | 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 | Yes | Yes | Yes |
| Persistent disk | With your own setup | Yes | Yes |
| Pause/resume | No documented way | Yes | Yes |
| Automatic snapshots | With your own setup | Yes | Yes |
| Fork/clone | With your own setup | Yes | Yes |
| Live fork (no pause) | With your own setup | 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 | Yes | Yes | No documented way |
| Wake on request | Yes | Yes | No documented way |
| HTTPS preview URLs | Yes | Yes | Yes |
| Raw TCP inbound | No documented way | Not published | Yes |
| Public IPv4 | No documented way | No documented way | No documented way |
| Egress allowlist | Yes | No documented way | No documented way |
| Secret proxy | Yes | Yes | Yes |
| Secret proxy for any API | Yes | No documented way | Yes |
| Preinstalled agents | Yes | Yes | Yes |
| Agent harness API | With your own setup | Yes | Yes |
| MCP server | No documented way | No documented way | 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 | No documented way | No documented way |
| Open source | Yes | No documented way | No documented way |
| Scoped API keys | Not published | Not published | Yes |
| Spend limits | No documented way | Yes | Yes |
| Usage per sandbox (API) | Not published | Yes | Yes |
| Audit logs | Yes | Not published | No documented way |
| SSO | Yes | No documented way | No documented way |
| SOC 2 | Yes | Yes | No documented way |
| HIPAA | Yes | No documented way | No documented way |
| EU data residency | Yes | No documented way | No documented way |
| Zero data retention | Not published | Not published | Yes |
Performance
Cloudflare Sandbox and Agent 37 are not in StarSling's run of 3 October 2026 (run 37073680030), so we cannot say which has faster CPU. In that run boat did 28.06 runs/s on the V8 Web Tooling Benchmark at 4 vCPU / 8 GB, second of 15, on an AMD Ryzen 9 9950X host; boat also places some sandboxes on other hosts. ComputeSDK measured a 671 ms median start for Cloudflare with 100 at once (2026-11-06, default size); Agent 37 and boat are not in ComputeSDK. Agent 37 says its default instances share host resources and sells dedicated cores on its Performance type.
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. Cloudflare Sandbox and Agent 37 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.
| Scenario | Cloudflare Sandbox, a month | Agent 37, 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 | $39 · Workers Paid | $6 · Wallet (any top-up) | $20 · $20/mo |
| One agent that never stops 4 vCPU / 8 GB, 50 GB disk, running 24/7 all month | $148 · Workers Paid | $12 · Wallet (any top-up) | $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 | $1,660 · Workers Paid | $329 · Wallet ($50 lifetime top-ups) | $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 | $476 · Workers Paid | $33 · Wallet ($1,000 lifetime top-ups) | $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 · Workers Paid · with limits | $73 · Wallet ($1,000 lifetime top-ups) · with limits | $8,800 · $2000/mo · with limits |
Cloudflare Sandbox: You need Workers Paid ($5 a month minimum). CPU is billed only while busy, at $0.072 per vCPU-hour. Memory and disk are billed on the instance size until the container sleeps, including the idle wait before it sleeps, and 4 vCPU always comes with 12 GiB. Snapshot pricing is not published.
Agent 37: A prepaid wallet with no plan fee, metered per minute: $0.80 per vCPU and $0.70 per GB of RAM per month while running, and $0.09 per GB of disk per month, also while stopped or asleep. Performance compute costs 4x and VM compute 2.5x the default rate.
Agent 37: Plans cost $20, $100, $500 or $2,000 a month, and the whole plan price comes back as VM time for that month. A 4 vCPU / 8 GB sandbox costs $0.036 an hour, billed per second while it runs, busy or idle, with 51 GB of disk. A stopped sandbox has no compute charge; saved snapshots above the included count and the AI proxy, if on, still bill. The $20 plan includes 200 starts a day; extra starts cost $0.03 to $0.07.
Limits in those scenarios
Cloudflare's local disk tops out at 20 GB and resets after sleep, so the scenarios that keep 50 GB of files between days need your own snapshot, automatic-save or R2 code. An account runs 1,500 vCPU at once by default, short of the 2,000 vCPU the 1,000-job burst needs, though Cloudflare raises it on request. Agent 37 caps awake instances by total top-ups (50 at $50, 200 at $250, 1,000 at $1,000), and every type stops at 4 vCPU; the 50-agent scenario is priced on its VM type for Docker, and the burst runs on shared vCPUs. On boat, the $2,000 plan includes 90 starts a minute, extra starts cost $0.03 to $0.07, and starts above 270 a minute fail with 429, so boat does not fit 1,000 jobs at once.
| Scenario | Cloudflare Sandbox | Agent 37 | boat |
|---|---|---|---|
| One coding agent, workdays | None for this scenario |
| None for this scenario |
| One agent that never stops | None for this scenario |
| 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 |
|
|
|
Which one should you use?
Use Cloudflare Sandbox when
your app already runs on Workers, you want your own container image, or you want short sandboxes that sleep when idle, bill CPU only while busy and follow egress rules you write.
- Egress rules you can program. Cloudflare can block every host except the ones you list, and run your own code on each outbound request.
- Bills CPU only while busy. For many short, spiky sessions, a sandbox sleeps when idle, wakes on the next request, and bills CPU only while busy.
- Next to the rest of Workers. If your app already runs on Workers, sandboxes sit next to Durable Objects and R2, in a region you can pick.
Use Agent 37 when
you host one mostly idle assistant per customer in the US that should keep its files, sleep with its memory saved and wake on the next message, at a low price per hour.
- Sleeps and keeps its memory. Useful for assistants that sit idle most of the day: an instance sleeps, keeps its memory and wakes on the next message.
- Low price per hour. Agent 37's default type costs about $0.012 an hour in compute at 4 vCPU / 8 GB, and its bill is the lowest of the three in four of our five scenarios.
- Ready agent templates and dedicated cores. Start from Hermes, OpenClaw or Claude Code templates, or your own Docker image, and pick dedicated cores when speed must stay steady.
Where boat fits
Look at boat when your agents do hours of real work: installs, builds, Docker and emulators. On Cloudflare your code keeps the files, and on Agent 37 Docker needs the VM type. Every boat sandbox is a full VM that saves its disk with no code and can be forked while it runs.
A full VM is the default
On Cloudflare, Docker runs with iptables turned off and disk tops out at 20 GB. On Agent 37 the default gVisor type cannot run Docker, and the VM type bills 2.5x with no init system. boat has Docker, systemd and /dev/kvm on every sandbox, up to 16 vCPU.
Files kept with no code
A Cloudflare sandbox keeps its repo across sleep only if your code snapshots it or uses R2. Agent 37 and boat keep the disk. boat saves it every minute and at each stop; a resume is like a reboot, and a machine failure loses writes after the last good snapshot.
Keys kept outside, at a price
On Cloudflare you write the outbound handler that adds every token. On Agent 37 your own keys sit as env vars in the instance. boat's optional proxy ($1 a day while on, plus $1 per 1,000 requests) keeps the real keys of supported providers outside.
Use boat when your agents do real work for hours on a full VM with Docker, systemd and a desktop, with a disk saved every minute and forks of running machines. Compare it one to one: boat vs Cloudflare Sandbox and boat vs Agent 37.
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 Cloudflare Sandbox cheaper than Agent 37?
No. Agent 37's estimate is lower in all five scenarios on this page, for example $12 against $148 a month for one agent that never stops, and $33 against $476 for sandboxes for your users. boat costs $26 and $200 for those two. A nearly idle sandbox can cost less on Cloudflare than its estimate here, because it bills CPU only while busy.
Which is faster?
We cannot say: neither Cloudflare Sandbox nor Agent 37 is in StarSling's CPU run. boat did 28.06 V8 Web Tooling runs/s there at 4 vCPU / 8 GB, on a Ryzen 9 9950X host. ComputeSDK measured a 671 ms median start for Cloudflare with 100 at once; Agent 37 and boat are not in it.
Can I run Docker on Cloudflare Sandbox or Agent 37?
Yes on both, with limits. On Cloudflare, docker:dind works with iptables and IP forwarding turned off. On Agent 37, the VM type runs Docker, at 2.5x the default compute rate. boat runs Docker with BuildKit and Compose in every sandbox.
Which one keeps my files?
Agent 37 keeps an instance's disk until you delete it, and can save its memory when it sleeps. Cloudflare starts from a fresh disk after sleep unless your code saved a snapshot, scheduled automatic saves, made an R2 backup or worked in a mounted R2 bucket. boat saves the disk every minute and at each stop, and keeps it at least 14 days after a stop.
Where do they run?
Cloudflare places containers in several regions of its network, and you can pin a region or jurisdiction. Agent 37 runs on dedicated servers in the United States. boat runs on machines in Germany, Finland and France, with no US or Asia region.
Can I limit where a sandbox connects to?
On Cloudflare, yes: allowedHosts blocks every host not on your list, and outbound handlers can change each request. Agent 37 and boat do not offer a provider-side egress allowlist.
Try boat
Install the CLI, then run boat new.
7-day free trial
More comparisons
- boat vs Cloudflare Sandbox
- boat vs Agent 37
- E2B vs Cloudflare Sandbox
- Daytona vs Cloudflare Sandbox
- Modal vs Cloudflare Sandbox
- Vercel Sandbox vs Cloudflare Sandbox
- Cloudflare Sandbox vs Blaxel
- Cloudflare Sandbox vs Runloop
- Cloudflare Sandbox vs Tensorlake
- Cloudflare Sandbox vs Morph Cloud
- Cloudflare Sandbox vs CodeSandbox SDK
- Cloudflare Sandbox vs Northflank