Agent sandbox

A boundary that limits what an agent's commands can touch: a container, a virtual machine or operating-system restrictions.

Updated November 23, 2026

Sandboxes come in layers. Some agents restrict their own commands (Codex has read-only, workspace-write and danger-full-access sandbox modes). A container isolates the agent’s files and processes from the host. A separate virtual machine isolates everything, including the kernel.

The strongest sandbox is a machine that holds nothing you would miss. Then the agent can be given full access inside it, which is why most agents in an EnvHaven workspace start without prompts.