An agent sandbox keeps your agent's code from reaching anything it shouldn't, but most say nothing about who can look into the sandbox itself.
Updated 4 December 2026. E2B, Modal and Daytona all isolate an agent's code from the host, and each is strong at what it's built for; none of the three describes protecting sandbox memory from the host's own operator in the documentation we checked. Of the options here, only a Hippius confidential VM keeps memory encrypted from the server owner, using AMD SEV-SNP. The trade-off is GPUs: Hippius VMs are CPU-only, so the model runs elsewhere, for example privately through SayGM.
| Option | Isolation by default | Can the host operator read memory? | GPUs | State between runs | Checked |
|---|---|---|---|---|---|
| Hippius confidential VM | AMD SEV-SNP confidential VM | No, encrypted by the processor¹ | No, CPU only | Persistent VM with encrypted disk | 4 Dec 2026 |
| E2B | Firecracker microVM | Not addressed in docs² | No³ | Pausing keeps filesystem and memory | 4 Dec 2026 |
| Modal Sandboxes | gVisor, VM runtime optional | Not addressed in docs² | Yes | Not kept unless snapshotted | 4 Dec 2026 |
| Daytona | Linux container, VM sandboxes optional | Not addressed in docs² | Yes | Filesystem kept when stopped; memory kept on VM sandboxes | 4 Dec 2026 |
Default configurations as each provider documents them. "Not addressed" means the provider's sandbox or security docs don't describe protecting memory from the host operator, not that the operator reads it.
Two jobs that get called "sandboxing"
When people compare agent sandboxes they usually mean one job: stopping code the agent wrote, or downloaded, from escaping and damaging the machine underneath. That's a real risk, because coding agents run untrusted code all day, and it's the job E2B, Modal and Daytona were built for.
The second job gets far less attention: stopping the machine underneath from looking in. An agent holds API keys, tokens and the documents it's working on, and all of it sits in memory while the agent runs. If the sandbox runs on someone else's server, the operator of that server is outside the sandbox's walls. A sandbox protects the host from the agent. Confidential computing protects the agent from the host.
You can need either, or both. The table above shows how the main options handle each job.
¹ Per the Hippius Confidential Compute docs, the host OS and hypervisor see only ciphertext. The server owner can still see that the VM is running, its size and its activity, along with network traffic metadata, and Hippius currently manages disk-key release. ² Based on Modal's security page, Daytona's sandbox docs and E2B's docs overview, checked 4 December 2026. ³ E2B has no publicly documented GPU sandbox, per independent comparisons; check E2B directly before relying on this.
How does each AI sandbox isolate code?
All three are well-engineered products with different strengths. This is a summary of their documented defaults, drawn partly from Upstash's comparison of 15 sandbox providers.
E2B sandbox
E2B runs each sandbox as a lightweight Linux VM on demand, built on Firecracker microVMs, the same technology behind AWS Lambda. Each sandbox gets its own kernel, which makes escaping into the host much harder than from a container. E2B can pause a sandbox with its filesystem and memory intact and keep it indefinitely, which suits agents that pick up work where they left off. It's purpose-built for agent code execution, with SDKs to match.
Modal sandbox
Modal sandboxes use gVisor by default, a user-space kernel that intercepts system calls before they reach the host, with a VM runtime as an option. Modal's security documentation describes data encrypted at rest and in transit and customer-supplied encryption keys. Its biggest advantage for agents is GPUs: sandboxes can attach GPUs and scale to very large numbers of concurrent runs.
Daytona sandbox
Daytona's default sandbox is a Linux container with its own filesystem and network stack, and it also offers full VM sandboxes and on-demand GPU sandboxes. Persistence is its strength: stopped sandboxes keep their filesystem, VM sandboxes can pause with memory preserved, and auto-stop timers keep idle costs down.

What a sandbox doesn't protect
Every isolation layer above draws its line in the same direction. Firecracker, gVisor and containers all keep the guest away from the host. None of them, on their own, hides the guest from the host, because the host still schedules its CPU and holds its memory.
Encryption at rest and in transit doesn't change that. It protects data on disk and on the wire, not data in use. When you pass an API key to a sandbox as an environment variable, that key is readable in memory for as long as the sandbox runs.
For short, disposable jobs, such as running a test suite on public code, this rarely matters. It matters more when the sandbox holds credentials that can spend money, data that belongs to your users, or an agent that runs for weeks and accumulates memory.
Where a Hippius confidential VM fits
A Hippius confidential VM isn't a drop-in replacement for a sandbox SDK. It's a full Linux VM that boots in a confidential mode: the processor encrypts its memory, and its disk only unlocks after the hardware report passes attestation. That makes it a good home for the long-running part of an agent, the process that holds keys and memory, rather than for thousands of throwaway code runs.
The two approaches also stack. Inside a confidential VM you can still run Docker or gVisor to contain the code your agent executes, so you get both directions of protection on one machine. The VMs run on servers owned by independent operators, and the hardware is what stops those operators reading them.
Because the VMs have no GPUs, pair the agent with a model service. SayGM routes every request through a sealed gateway and offers confidential models that run inference inside a TEE, so the prompt stays sealed too. See current VM sizes and hourly rates on the Hippius pricing page; billing is per second.

Which agent sandbox should you choose?
- Choose E2B for fast, disposable code execution with a purpose-built SDK and pause-and-resume.
- Choose Modal when the sandboxed code needs GPUs or very high concurrency.
- Choose Daytona for persistent development environments and GPU sandboxes with flexible auto-stop.
- Choose a Hippius confidential VM when the agent itself holds secrets, and you need the server's owner unable to read its memory. Add a container runtime inside it if the agent also runs untrusted code.
Common questions about agent sandboxes
How do you sandbox AI agents?
Run the code an agent generates in an isolated environment, such as a microVM, gVisor or a container, with limited network access and only the credentials that task needs. If the agent handles secrets or user data, also run it somewhere the host can't read, such as a confidential VM.
Which sandbox tools support secure AI agent code execution?
E2B, Modal and Daytona are the most widely used managed options, using Firecracker microVMs, gVisor and containers respectively. Self-hosted runtimes exist too. For protection from the host operator, look for confidential computing support such as AMD SEV-SNP or Intel TDX.
Can you run Docker containers inside an AI agent sandbox?
It depends on the platform, so check its docs. On a Hippius confidential VM you can, because it's a standard Ubuntu or Debian VM and Docker installs as usual.
Does a sandbox keep my API keys safe?
It keeps the agent's code from stealing keys from the host. It doesn't keep the host from reading keys inside the sandbox. For that, the sandbox needs to run on hardware that encrypts memory in use.
Final thoughts
An agent sandbox and a confidential VM answer different questions. One asks whether the agent can get out; the other asks whether anyone can see in. For agents that hold keys, wallets or private data, the second question is the one most comparisons leave out.
If your agent needs to keep secrets from the machine it runs on, launch a Hippius confidential VM and run your sandbox inside it.
About Hippius
Hippius is a distributed cloud platform built to give users a verifiable alternative to providers like AWS and Google Cloud. Files are encrypted and distributed across an independent network rather than held in a single provider's data center. Every storage claim, payment, and miner action is recorded on Hippius's own blockchain, so instead of asking users to trust the platform, Hippius lets them check it for themselves. On top of that foundation sits a full product suite: personal cloud storage, S3-compatible object storage with no egress fees, confidential compute on secure hardware, and a container and model registry for AI.
Website | Discord | Twitter | LinkedIn | Docs | Blog | Medium | Forum | Github
