Cloudflare Sandboxes
https://developers.cloudflare.com/sandboxes/
Cloudflare Sandbox SDK is a managed environment for running untrusted code on behalf of AI agents, built on top of Cloudflare Containers. Each sandbox is a Linux container with a shell, filesystem, and background processes that starts on demand and resumes from where it left off. Developers drive sandboxes from a Cloudflare Worker via the @cloudflare/sandbox TypeScript SDK to execute commands, manage files, run background services, and expose preview URLs.
| Pricing model | Per-second (10ms granularity), billed only while the instance is awake for active vCPU, memory, and disk |
|---|---|
| Pricing The headline compute price as the provider states it. Sorting ranks prices stated per vCPU over time, converted to hourly. Other pricing models sort after, unranked. | $0.000020 per vCPU-second (~$0.072 per vCPU-hour) plus $0.0000025 per GiB-second of memory |
| Free while idle Whether a stopped, paused, or sleeping sandbox costs nothing. | ✓ |
| Elastic Resources flex with what the sandbox actually uses, and the bill follows: yes when the provider bills on active or observed use, no when capacity is reserved or allocated and billed while it runs. | ✓ |
| Memory snapshots Whether RAM state survives a pause and resume, not just disk. | ✕ |
| Wake on request Whether a stopped sandbox wakes automatically on inbound traffic. | ✓ |
| Start / resume Typical time from create or resume to running. Sorting ranks stated times, converted to seconds; claims with no figure sort after, unranked. | ~1-3 seconds |
| Max runtime The longest a sandbox may run. | No fixed limit; runtime is not guaranteed and may end on host restart |
| Isolation The isolation technology between sandboxes. | Per-instance isolation on Cloudflare Containers platform (Firecracker microVMs; gVisor and QEMU also supported) |
| GPUs Whether GPU instances are available for sandboxes. | ✕ |
| Docker Whether Docker containers can run inside the sandbox. | ✓ |
| SDKs | TypeScript |
✓ yes · ✕ no · – no cited public fact.
All disk state is ephemeral; sleeping the sandbox wipes the filesystem, and 'Snapshots are coming soon' rather than generally available.
Sources
- https://developers.cloudflare.com/sandbox/guides/docker-in-docker/
- https://github.com/cloudflare/sandbox-sdk/blob/main/DOCKER_README.md
- https://github.com/cloudflare/sandbox-sdk
- https://github.com/cloudflare/sandbox-sdk/blob/main/packages/sandbox/README.md
- https://blog.cloudflare.com/sandbox-ga/
- https://developers.cloudflare.com/sandbox/
- https://www.ernestchiang.com/en/posts/2025/firecracker-powered-containers-arrive-on-cloudflare/
- https://developers.cloudflare.com/sandbox/api/backups/
- https://developers.cloudflare.com/containers/faq/
- https://developers.cloudflare.com/containers/platform-details/architecture/
- https://developers.cloudflare.com/sandbox/api/lifecycle/
- https://developers.cloudflare.com/sandbox/concepts/sandboxes/
- https://developers.cloudflare.com/sandbox/configuration/sandbox-options/
- https://developers.cloudflare.com/sandbox/platform/pricing/
- https://blog.cloudflare.com/container-platform-preview/
- https://nirvanalabs.io/blog/agent-sandboxes-comparison-2026
Last verified 2026-08-14. Corrections land through the update log.