Cloudflare Rebuilds Containers to Make AI Agent Sandboxes Faster and More Flexible
Cloudflare has rebuilt its Containers infrastructure for AI agents, introducing faster sandbox startup, runtime environment selection and filesystem snapshots for persistent agent workspaces.
Xcademia Team

Cloudflare Reworks Containers for the AI Agent Era
AI agents are moving beyond simple question-and-answer interactions. Increasingly, they need a real computing environment where they can write code, install dependencies, run commands, test applications and preserve work between sessions.
Cloudflare says this shift requires a different approach to cloud infrastructure.
On September 30, 2026, Cloudflare announced a redesigned version of its Containers infrastructure focused specifically on agent workloads. The company says the new architecture allows applications to create sandboxes on demand, select the environment and compute resources at runtime, start Containers significantly faster, and save work through filesystem snapshots.
Cloudflare says Containers can now start more than six times faster under its new scheduling approach. An independent ComputeSDK benchmark cited by the company measured median startup time falling from 4.049 seconds to 648 milliseconds.
The update also brings the Durable Object directly into control of the Container through the ctx.container API.
Why AI Agents Need Different Infrastructure
Traditional application deployments usually work around a relatively stable configuration.
A developer selects a container image, chooses computing resources and deploys that configuration. The platform then manages the application fleet.
AI agent workloads can operate differently.
An agent may need to create a workspace only when a user starts a task. The task may determine which programming environment is required, how much compute is needed and which tools should be available.
For example, a coding agent could require a Node.js environment for one task and Python for another. An evaluation system may need many isolated environments that all begin from the same state.
Cloudflare says agent workspaces can also exist for only a few minutes, pause while an agent waits, or return days later with the previous files still available.
This creates three infrastructure requirements:
Fast startup: The sandbox should become usable quickly.
Runtime flexibility: The application should choose the environment when the task begins.
Persistence: The agent should be able to save and restore its workspace.
Cloudflare's redesign addresses these requirements through its new durable_object scheduling policy, faster runtime and filesystem snapshots.

What Changed in Cloudflare Containers?
The central change is how a Container is scheduled and controlled.
Previously, Cloudflare says Containers were organized primarily around application deployments. Configuration such as the image and compute resources was selected during deployment.
The new durable_object scheduling policy moves more of that decision-making into application code.
The application can choose the Container image and instance type when a task arrives.
In practical terms, one Durable Object can decide whether a task needs a Node.js or Python environment and select the appropriate compute size.
That means developers do not necessarily need separate application deployments for every environment.
Cloudflare describes this as moving infrastructure decisions closer to request-time application logic.
Faster Container Startup
Startup time is particularly important for AI agents because a user may be waiting for the agent to perform its first action.
Cloudflare says its previous startup path required the global control plane to resolve configuration, find capacity and coordinate placement.
The new approach starts from the Durable Object associated with the Container. Cloudflare says the infrastructure first looks for capacity on the same machine and then expands the search within the same location if necessary. It can also favor hosts that already contain the required image or snapshot.
The runtime was also redesigned to reduce work required before the first command can execute.
Cloudflare says the new runtime can restore a prepared virtual machine rather than booting a new virtual machine from scratch. It also reuses networking and filesystem setup and batches repeated operations.
Cloudflare's cited startup benchmark
Measurement | Previous path | New scheduling policy |
|---|---|---|
Median | 4.049 seconds | 648 ms |
95th percentile | 5.839 seconds | 910 ms |
99th percentile | 6.717 seconds | 1.129 seconds |
These figures come from the ComputeSDK Burst TTI Benchmark cited by Cloudflare, which launches 100 sandboxes concurrently. Cloudflare reports improvements of 6.2x at the median, 6.4x at the 95th percentile and 5.9x at the 99th percentile.
Cloudflare also reports a preliminary burst test in which a single account started 100,000 Containers in 5.387 seconds across six locations. The company describes this as its own preliminary testing rather than the independent benchmark.
Runtime Selection Becomes Part of the Application
Another major change is the ability to select the environment at runtime.
Cloudflare's example shows application code selecting between Python and Node.js images based on the incoming workspace requirements. The application can also select different instance types depending on the workload.
This is particularly relevant for agent platforms where different tasks can require different environments.
A single application could potentially handle multiple workspace types without deploying each environment as a separate application configuration.
Cloudflare also says runtime image selection changes how rollouts can work.
Developers can implement strategies such as:
Sending a percentage of new sandboxes to a new image
Keeping an active project pinned to its existing environment
Moving a workspace to a new image at a natural checkpoint
Changing the image selected for future starts to roll back an update
The important distinction is that these policies can live in application code rather than being handled entirely through a centralized rollout configuration.
A Prepared Image for Agent Workloads
Cloudflare is also introducing a ready-to-use system image called cloudflare/debian-trixie.
According to the announcement, it contains Debian Trixie Slim and Node.js 24.20.0 LTS. Developers can use it to start a Linux sandbox without first creating and publishing their own Dockerfile-based image.
Once the sandbox is running, an agent can use exec() to clone a repository, install packages and configure the environment.
Cloudflare says it can distribute and prepare the image across eligible Container hosts before requests arrive. This means the initial request does not necessarily need to wait for the base image to be downloaded and unpacked.
This approach separates two stages:
Start the Linux environment quickly
↓
Configure it for the specific agent task
That can be useful when the exact requirements of a task are not known until the agent receives the request.
Filesystem Snapshots Bring Persistence to Agent Workspaces
Fast startup addresses only part of the problem.
An AI agent may still need time to clone a repository, install dependencies and configure development tools.
If the environment disappears after every session, the same setup work has to happen repeatedly.
Cloudflare is therefore adding native filesystem snapshots to Containers in public beta.
A snapshot can capture the workspace so it can later be restored.
For example, a coding agent could:
Start a Linux sandbox.
Clone a repository.
Install dependencies.
Configure its development environment.
Work on the project.
Save a filesystem snapshot.
Stop the compute environment.
Restore the workspace during a later session.
Cloudflare says the repository, installed dependencies, build caches, configuration and edits can remain available through the snapshot.

Snapshots Can Also Support AI Evaluations
Cloudflare highlights another use case for filesystem snapshots: AI agent evaluations.
An evaluation may need to run the same task using different system prompts, skills, models or agent versions.
For a meaningful comparison, the underlying environment should remain consistent.
Cloudflare says one immutable snapshot can provide the same starting workspace for multiple isolated Containers. Each environment can then make its own changes without modifying the original baseline.
The basic model looks like this:
Prepared workspace
↓
Snapshot
↓
Multiple isolated sandboxes
↓
Different agent configurations
↓
Independent results
This can reduce repeated environment setup and help keep the starting conditions consistent during evaluations.
Cloudflare also describes a similar pattern for reinforcement learning systems, where multiple attempts can be created, monitored and reset from known workspace states.
Durable Objects Become the Controller
At the center of Cloudflare's redesign is the Durable Object.
Cloudflare says every Container is associated with a Durable Object that can manage its identity, state and lifecycle. Under the new model, the Durable Object can control the Container directly through ctx.container.
This creates a separation between the agent and the environment where it performs its work.
The Durable Object can maintain state and coordinate the session, while the Container provides the Linux environment.
Cloudflare describes the Container as a compute extension of the Durable Object.
This architecture can support several patterns.
An agent can remain available while its Linux workspace is stopped. When it needs a shell, compiler or development server, it can start the Container again.
Cloudflare also describes using the Durable Object to supervise security-related controls around the Container, including authorized services, repositories and operations.

What Is Changing for Cloudflare's Container and Sandbox APIs?
Cloudflare says the new architecture also changes the developer experience.
The company previously hid the Durable Object behind its Container class. Its Sandbox SDK was built on that abstraction.
Cloudflare says several capabilities have now become native, including:
durable_objectschedulingFaster startup
Runtime image selection
Runtime instance selection
Filesystem snapshots
Direct Container control through
ctx.container
Cloudflare says the existing Container class and legacy Sandbox class will be maintained through December 31, 2026. Existing deployments will continue running after that date, but the classes will no longer receive updates. Cloudflare recommends migration to ctx.container.
The company also says Sandbox SDK 1.0 is now positioned as a set of utilities rather than a base class.
For developers who want a higher-level environment, Cloudflare says @cloudflare/computer combines Dynamic Workers and Containers with a synchronized filesystem.
Why This Matters for AI Agent Development
The announcement highlights a broader industry shift toward AI systems that need access to real computing environments rather than only model inference.
An agent that can modify code, run tests or operate a development environment needs infrastructure that can respond dynamically to its tasks.
Cloudflare's redesign addresses several of these infrastructure challenges together:
Fast provisioning
The new scheduling path reduces the time between requesting a sandbox and running the first command.
Dynamic environments
Applications can choose images and compute resources based on the task.
Persistent workspaces
Filesystem snapshots allow work to be saved and restored.
Task isolation
Different agent tasks can operate in separate Container environments.
Lifecycle control
Durable Objects can coordinate the identity, state and lifecycle of the workspace.
Evaluation workflows
Snapshots can provide repeatable starting environments for multiple agent runs.
These capabilities are presented by Cloudflare as infrastructure improvements for agent workloads rather than as changes to the AI models themselves.
What Developers Should Know
For developers building AI-powered applications, the important idea is not simply that Containers are starting faster.
The larger change is that the sandbox becomes more programmable.
Instead of treating the Container environment as a fixed deployment configuration, the application can decide what environment it needs when a task arrives.
That distinction matters for agents because the workload can change from request to request.
A coding task may require one toolchain. An evaluation may require a clean baseline. A long-running project may require a previously saved workspace.
Cloudflare's new architecture is designed to let the application handle those differences directly.
For enterprises and development teams, this could mean more flexible architectures for applications in which AI agents need temporary or persistent computing environments. However, the practical impact will depend on how individual applications use these capabilities, and Cloudflare did not provide a universal performance guarantee for all agent workloads.
Availability
Cloudflare says the new durable_object scheduling policy is available to all today in public beta.
The announcement also identifies filesystem snapshots as being in public beta. Developers can access documentation, a GitHub sandbox example and integrations involving Cursor Cloud Agents, Devin Outposts and the OpenAI Agents API.
Cloudflare also provides a migration path for existing users moving from the older Container and Sandbox abstractions toward ctx.container.
The Bigger Picture
AI agents are increasingly being designed to perform multi-step tasks rather than return a single response.
That changes the infrastructure requirements behind them.
An agent may need a temporary Linux environment, access to tools, a repository, installed dependencies and a way to preserve its work. It may also need to stop computing while waiting and resume later without rebuilding everything.
Cloudflare's Containers update is designed around that model.
The announcement highlights a broader industry shift toward infrastructure that treats an AI agent's workspace as a programmable part of the application. Instead of deploying a fixed environment and leaving it running, developers can create, configure, pause, snapshot and restore environments according to the agent's workload. Cloudflare Blog
For developers building the next generation of AI applications, the important question is increasingly not only which model should run the agent, but also where and how that agent should work.
Cloudflare's redesigned Containers architecture is one approach to that infrastructure problem.
Source: Cloudflare Blog
About the Author