Sandboxes FAQ
Short answers about Sandboxes (beta): starting, forking, isolation, pricing, limits, what is not there yet, and where to get help.
On this page31
- Basics
- What is a sandbox?
- When can I send it commands?
- What is inside one?
- Can I run Docker?
- Where do sandboxes run?
- Is there an SDK?
- Can I stream a command's output?
- What if a command prints more than 4 MiB?
- Forking
- What does a fork copy?
- How many copies can one fork make?
- Do copies share randomness or identity?
- Security and isolation
- How are sandboxes isolated, and what can they reach?
- Can I reach a port in a sandbox at a URL?
- Do I get root?
- Do sandboxes install system updates?
- What can Prized see?
- What happens to my data when a sandbox is deleted?
- Pricing and limits
- How much does it cost?
- What do I get for free?
- What happens at the free 60 minutes?
- How long can a sandbox live, and what does pausing do?
- What happens at a limit, or when my credit runs out?
- What's not there yet
- Can I bring my own image?
- What else is missing?
- Getting help
- Where do I get help?
New here? Open Sandboxes to sign up and make an API key, then run the Quickstart.
Basics
What is a sandbox?
Sandboxes (beta) are Linux microVMs that your code creates, runs commands in, pauses, forks, and deletes through the API or the CLI. Unlike a box, the machine you work on every day, a sandbox is for one job at a time and runs up to 7 days at a stretch.
When can I send it commands?
As soon as it reads running, with no warm-up command (The edge); a resume is usually back to running in under a second. Create it with ?wait=running, and read it until running if the answer still says starting (Waiting). At busy moments a create can wait in starting a minute or two while capacity is added, or answer 503 sandbox_capacity with Retry-After and bill nothing (Limits: Sandboxes).
What is inside one?
Ubuntu 24.04 with Python 3, Node.js 22, git, and build tools (prized-base-v1), or all of that plus Claude Code and Codex (prized-agent-v1) or Docker (prized-docker-v1, once the workspace has paid in). Each takes 1 to 32 vCPU, 1 to 128 GB of memory, and 10 to 128 GB of disk (Templates).
Can I run Docker?
Yes, on prized-docker-v1, once the workspace has paid in with a plan or a top-up: docker, docker compose, and docker build work as prized without sudo (Run Docker and Compose in a sandbox). On the free credit alone, a create, fork, or resume from it answers 402 template_needs_payment; prized-base-v1 and prized-agent-v1 run on the free tier. Docker's daemon runs as root, so code that can use Docker is root inside that sandbox, which is still its own microVM.
Where do sandboxes run?
In us-west-2 (Oregon). Other regions are not available yet.
Is there an SDK?
Yes: pip install prized for Python and npm i @prized/sdk for TypeScript (Sandbox SDK for Python and TypeScript). The Sandbox API also works from any HTTP client, and prized sandbox from the CLI.
Can I stream a command's output?
With the SDKs, yes: on_stdout in Python and onStdout in TypeScript get the output as it arrives. The API's exec answers when the command ends, with up to 4 MiB of each stream; without an SDK, start a background process and read its output by offset.
What if a command prints more than 4 MiB?
One exec keeps the first 4 MiB of each output stream, and truncated says when it cut one. Pass full_output=True in Python or fullOutput: true in TypeScript: the result keeps up to 100 MiB of each stream, and a command with little output is still one request. If the sandbox's disk fills up first, the stream stops there, and truncated_reason / truncatedReason says write_failed.
Forking
What does a fork copy?
Each copy starts with the parent's memory, disk, and processes as they were at the fork, and runs. You can fork a running sandbox, which keeps running after a pause that grows with the memory it has used (in our tests, about 0.2 seconds idle and 2 to 4 seconds after using 2.5 GB), or a paused one, which stays paused. Copies are ordinary sandboxes, billed and counted against your quotas like any other (Fork).
How many copies can one fork make?
As many as fit on the parent's machine and in your workspace's quotas, up to 256 a request; more memory or disk, or a busy machine, fits fewer. A fork that does not fit makes nothing and answers 409 fork_capacity with fits, how many fit now: fork that many, or start a new sandbox and fork that. With no sandbox capacity free, a fork answers 503 sandbox_capacity as a create does (Limits: Sandboxes). A fork is all or nothing: if a copy still cannot start after the fork was accepted, every copy is deleted, each saying why in errorReason (Fork).
Do copies share randomness or identity?
Each copy gets its own hostname, IP address, /etc/machine-id, and boot_id, and a freshly reseeded kernel random number generator. Its connections to other machines are closed, and loopback ones keep working. Process IDs stay the parent's, and a process that was already running keeps what it holds in memory, its random state and any boot_id it already read included, so reseed or restart it after a fork before it makes keys, tokens, or IDs.
A copy's clock starts where its parent's was at the fork, or at the pause for a paused parent. Before the copy reaches running, its clock is moved forward to the current time if it is more than a second behind. This is best effort: if it fails, the copy runs behind until the sandbox's own time sync corrects the clock, which can take minutes.
Security and isolation
How are sandboxes isolated, and what can they reach?
Each sandbox is its own microVM with its own kernel. It reaches the internet outbound. Nothing reaches it from the internet but a request to one of its port URLs (with your API key or a token, or on a port you made public) or an SSH connection (prized sandbox ssh or SSH access), and sandboxes have no direct network path to each other (Security and trust).
Can I reach a port in a sandbox at a URL?
Yes: every port but 22 and 81 has an https URL (prized sandbox port ID 3000, or the sandbox's previewUrlTemplate). It answers a request carrying your API key in Prized-Key, and wakes a paused sandbox to answer it. To open it in a browser, or for a client that cannot send a header, such as a WebSocket in a web page, make a short-lived token; for anyone with the link, or webhooks, make the port public (the workspace owner, on a workspace that has paid in). Both give the port's prized.link URL, which opens in a browser tab, through the API or prized sandbox port ID 3000 --token and --public (Preview a port).
Do I get root?
No: commands run as the user prized, without sudo, so there is no apt install, though apt can unpack packages into your home (System packages without root). pip install and npm install -g install into your home (~/.local), or use a venv (python3 -m venv ~/.venv && ~/.venv/bin/pip install numpy) (Inside a sandbox). On prized-docker-v1, Docker can act as root inside the sandbox (Can I run Docker?).
Do sandboxes install system updates?
No: sandboxes run no unattended upgrades. Updated system packages ship as a new build of the template, for new sandboxes (Templates).
What can Prized see?
Commands and files pass through Prized's edge, which checks your API key on every request; the key never enters the sandbox, and the envVars you set are stored encrypted and never returned by any route. A running sandbox reports resource vitals, listening ports, and its top processes with their command lines (shortened), never file contents or terminal output (Security and trust).
What happens to my data when a sandbox is deleted?
Deleting a sandbox, by hand or at the end of its lifetime, erases its disk, memory, and environment variables with no undo. Paused state is not backed up; if the sandbox was moved to a new machine while paused, the encrypted copy from that move, which you cannot restore, ages out about 30 days after the move. What the workspace keeps after a delete, and what erasing the workspace removes, is on Data retention.
Pricing and limits
How much does it cost?
Per second, with no minimum: running, by vCPU, memory, and disk. Paused, no compute: the workspace's paused storage (each paused sandbox's disk and saved memory) is free up to 20 GB, then $0.05 per GB-month (Billing: Sandboxes).
| Resource | Running | Paused |
|---|---|---|
| vCPU | $0.04 per vCPU-hour | Not charged |
| Memory | $0.0125 per GB-hour | Saved memory counts as paused storage |
| Disk | $0.0001 per GB-hour | Counts as paused storage |
| Paused storage, per workspace | Not charged | First 20 GB included, then $0.05 per GB-month |
| Shape | Running | Paused |
|---|---|---|
| 1 vCPU, 2 GB, 10 GB disk | $0.066 an hour | 12 GB of paused storage |
| 2 vCPU, 4 GB, 10 GB disk | $0.131 an hour | 14 GB of paused storage |
| 4 vCPU, 8 GB, 10 GB disk (the default) | $0.261 an hour | 18 GB of paused storage |
| 8 vCPU, 16 GB, 10 GB disk | $0.521 an hour | 26 GB of paused storage |
| 32 vCPU, 128 GB, 10 GB disk (the largest) | $2.881 an hour | 138 GB of paused storage |
What do I get for free?
New workspaces get $30 of free credit with no card. On the free credit alone you can run 10 sandboxes at once, each up to 2 vCPU, 4 GB, and 60 minutes, so a free fork is a parent plus 9 copies; a top-up or a plan lifts the workspace to the full quotas and opens prized-docker-v1 (Free tier).
What happens at the free 60 minutes?
On the free tier, a sandbox that has run 60 minutes is deleted, memory and disk included, with no undo. Paused time does not count, so pause it before then to keep it (or set autoPauseMin on the create, and an idle one pauses itself): a paused one is kept 30 days after its last use, and a resume carries on the time left. After a top-up from $10, or a plan, new sandboxes get 24 hours by default, up to 7 days, and a running one can be extended (Run time).
How long can a sandbox live, and what does pausing do?
Until its run time ends, then it is deleted: 24 hours by default, up to 7 days, and you can extend it anytime (AI agent sandbox that pauses with memory and runs past 24 hours). A resume restarts the clock. On the free tier it is 60 minutes of running in all; paused time does not count (Run time). A paused sandbox keeps its memory and disk until you delete it (on the free tier, until 30 days after its last use) or its machine fails, bills for storage alone, and on resume every process carries on where it stopped, unless a move to a different kind of machine left only its disk (Paused retention, Pause and resume).
On resume, the system clock inside the sandbox is set to the current time, but its monotonic time misses most of a long pause, so renew tokens and leases then (Clocks inside the sandbox).
What happens at a limit, or when my credit runs out?
A request past a quota makes nothing and answers 429 sandbox_quota_exceeded, naming the limit in reason (Limits: Sandboxes). At a zero balance, with overage off, running sandboxes pause until you add credit and resume them, and a resume restarts their run time (on the free tier, carries on the time left) (Billing: Sandboxes).
What's not there yet
Can I bring my own image?
Not as a template yet: no templates from your own Dockerfile or image, and no saving a sandbox as a template. Build and run your image with Docker on prized-docker-v1 (Run Docker and Compose in a sandbox), or set up a sandbox once, system libraries included, pause it, and fork it for each job (Use a sandbox as your own template).
What else is missing?
Other regions, GPUs, egress allow and deny lists, a terminal in the dashboard, raw TCP into a sandbox, and more than 32 vCPU or 128 GB. Not yet lists each with what to use instead.
Getting help
Where do I get help?
Email with the sandbox id and the error from the response; common errors and their fixes are on Troubleshooting: Sandboxes. Report a vulnerability to the same address, before publishing it if you can (Security and trust).