lizard sandbox
Create and manage Sandboxes from the terminal. Alias: lizard sb.
Usage
lizard sandbox create [flags]
lizard sandbox list [flags]
lizard sandbox exec <id> -- <command>
lizard sandbox ssh <id>
lizard sandbox fork <id> [flags]
lizard sandbox rm <id> [flags]Every sandbox belongs to a project: the one you pass with -p, else the one linked to the current directory, else your account’s default project (the oldest project in your personal workspace).
Subcommands
lizard sandbox create
Create a sandbox and print its ID.
| Flag | Description |
|---|---|
-t, --template <name> | Template (default base). Enabled templates: base, interpreter, codex, desktop, desktop-camoufox (US East only), opencode, pi, prime, claude. The server checks the region’s list |
-s, --size <size> | nano, mini, small, medium (default; small during the trial), large, or big (paid plans only). nano works only with the base, claude and codex templates, mini only with those and interpreter, and big only with those four and desktop; these three take no volume |
--timeout <ms> | Lifetime in milliseconds (default 300000, five minutes); 0 disables expiration. During the trial, at most 3600000 (1 hour), and 0 gets 1 hour |
--region <code> | Region to create the sandbox in |
--snapshot <id> | Start from a saved snapshot; can’t be combined with --size |
--volume <name-or-id> | Attach a Persistent Volume |
--with-token [key] | Sign in lizard inside the sandbox with a new key limited to the sandbox’s project and deleted with the sandbox. The liz_ key you pass, or without a value the liz_ key you run with, only authorizes the request; a browser login has none. The base template has no lizard |
-p, --project <id> | Project (defaults to the linked one, else your default project) |
Lizard bills each size per second at a flat rate while it runs, including idle time. The price includes local disk and 2 TB of egress per account over a rolling 30 days. A successful pause stops compute charges; the paused sandbox’s disk bills at $0.14 per GB-month of used space until you resume or delete it, and so does each snapshot until you delete it. Persistent Volumes bill at the volume rate, whether attached or detached.
| Size | vCPU | Memory | Disk | Price |
|---|---|---|---|---|
nano | 0.5 (1 vCPU held to half a core) | 1 GiB | 5 GB | $0.00405/h |
mini | 1 | 2 GiB | 10 GB | $0.0081/h |
small | 2 | 4 GiB | 20 GB | $0.0162/h |
medium | 4 | 8 GiB | 40 GB | $0.0324/h |
large | 8 | 16 GiB | 80 GB | $0.0648/h |
big | 16 | 32 GiB | 120 GB | $0.1296/h |
Anything in the sandbox can read the key that --with-token installs and use it on the sandbox’s project until the sandbox is deleted.
Until your trial or plan starts, create returns HTTP 402 with a Checkout link; run lizard billing start. Limits count the vCPU of running sandboxes: 40 on Pro after the first paid invoice, 220 on Pro 5x and 1,200 on Pro 20x. Pro 5x and Pro 20x have no limit on sandbox starts. Paused sandboxes don’t count. During the trial, a sandbox runs in a US region and is small, mini or nano, 1 Small, 2 Mini and 2 Nano at a time. A second small, or a third mini or nano, running at once, whether you create, fork or resume it, returns HTTP 403 with TRIAL_SIZE_RUNNING; pause or delete one, or start a mini instead of a small. medium returns HTTP 403 with TRIAL_SANDBOX_SIZE, large or big returns HTTP 403 with SANDBOX_SIZE_NOT_ALLOWED, and another region returns HTTP 403 with TRIAL_SANDBOX_REGION. A trial sandbox is deleted 1 hour after it starts at the latest: without --timeout (or with 0) it gets 1 hour, and a --timeout over 3600000 returns HTTP 403 with TRIAL_SANDBOX_LIFETIME. Over the vCPU limit, create returns HTTP 429 with SANDBOX_LIMIT_REACHED. See Limits.
lizard sandbox list
List sandboxes in the linked project (alias ls).
| Flag | Description |
|---|---|
-p, --project <id> | List this project instead |
--all | List every sandbox across all your workspaces |
lizard sandbox rm <id>
Delete a sandbox (aliases delete and kill).
| Flag | Description |
|---|---|
-y, --yes | Skip confirmation |
lizard sandbox timeout <id> <ms>
Set a new lifetime, counted from now, in milliseconds (at least 1000). It is not an idle timer: running commands does not reset it. During the trial, the deadline can’t move past 1 hour after the sandbox was created; a later one returns HTTP 403 with TRIAL_SANDBOX_LIFETIME and latestExpiresAt.
lizard sandbox exec <id> -- <command>
Run one command inside the sandbox through sh -c, stream its output, and exit with its exit code.
lizard sandbox ssh <id>
Open an interactive shell in a running sandbox (alias shell). It uses your Lizard login, so there are no SSH keys to set up; a scoped API key reaches only sandboxes in its scope. Ctrl-C, arrows, and tab completion go to the sandbox. Type exit or press Ctrl-D to leave.
It needs an interactive terminal; in a script, use lizard sandbox exec. It is not the SSH protocol, so SSH clients, scp, and port forwarding don’t work.
lizard sandbox expose <id> <port>
Give a port in the sandbox an HTTPS URL. The port is private: requests need the sandbox’s access token, either in the X-Lizard-Access-Token header or as the lizard_token query parameter that the printed URL already carries. Requests without it get HTTP 401. With --json, the result also has hostname and accessToken.
lizard sandbox unexpose <id> <port> removes the URL.
lizard sandbox desktop <id>
Start the graphical desktop of a sandbox created with -t desktop and print its browser URL and a view-only URL. Treat both links like passwords.
| Flag | Description |
|---|---|
--view-only | Print or open only the view-only URL |
--resolution <WxH> | Screen size, from 640x480 to 3840x2160 |
--open | Open the desktop in your browser |
--status | Show the desktop’s state and URLs without starting it |
--stop | Stop the desktop and remove its URL |
lizard sandbox vnc <id>
Connect a VNC app (macOS Screen Sharing, TigerVNC, RealVNC) to the desktop of a sandbox created with -t desktop. The desktop has no public VNC port, so the CLI listens on localhost and carries each connection to the sandbox over a secure WebSocket. It starts the desktop if needed, prints the address and the VNC password, and runs until Ctrl-C.
| Flag | Description |
|---|---|
--port <port> | Local port (default 5900; if it’s taken, the next free one) |
--view-only | Use the view-only password: watch, no control |
--open | Open the address in your VNC app (vnc://, Screen Sharing on macOS) |
Pause, resume, and snapshots
| Command | What it does |
|---|---|
lizard sandbox pause <id> | Save the sandbox’s files and pause it. Running processes and memory end. A successful pause stops compute charges; the disk bills at $0.14 per GB-month of used space until you resume or delete the sandbox |
lizard sandbox resume <id> | Boot a paused sandbox fresh with its files |
lizard sandbox snapshot <id> --name <name> | Save only a running sandbox’s files as a snapshot that restores only in the sandbox’s project and region. It costs $0.14 per GB-month of used disk space until you delete it |
lizard sandbox restore <snapshot-id> | Start a new sandbox from a snapshot, in the snapshot’s project and region. --volume <name-or-id> mounts a volume from that project at /workspace, --timeout <ms> sets the lifetime (default 300000) |
lizard sandbox snapshots | List the snapshots taken in the project (-p for another project, --mine for every snapshot you took) |
lizard sandbox snapshot-rm <snapshot-id> | Delete a snapshot (alias snapshot-delete, -y skips confirmation) |
pause, resume, and snapshot wait until the work is done; pass --no-wait to return once it is queued. See Pause, resume, and snapshots for what each step keeps.
A snapshot of a sandbox with a volume attached includes a copy of the volume’s files as they were at capture. Every restore gets that copy and cannot take --volume, and anyone who can restore the snapshot can read those files. --volume works only with a snapshot of a sandbox that had no volume, and the volume must be in the snapshot’s project and region.
lizard sandbox fork <id>
Start live copies of a running sandbox. Lizard pauses the sandbox for a moment, captures its memory, processes, and files once, and boots every copy from that capture. The source keeps running with the same ID and lifetime. Prepare one sandbox (tools installed, app loaded), then fork it to spread work across copies without repeating the setup.
| Flag | Description |
|---|---|
-n, --count <n> | Copies to start, from 1 to 100 (default 1) |
--timeout <ms> | Lifetime of each copy, at least 1000; default: the source’s lifetime |
Each copy is a sandbox start: it counts toward the running and start limits, runs at the source’s size, and is billed at that size. With --json the output has one entry per copy, {"sandbox": {...}} or {"error": "..."}. If any copy could not start, the command exits 1, and the copies that did start keep running until you delete them. You can’t fork a paused sandbox or one with a volume attached (HTTP 409).
lizard sandbox files
| Command | What it does |
|---|---|
lizard sandbox files ls <id> [path] | List a directory (default /) |
lizard sandbox files cat <id> <path> | Print a file |
lizard sandbox files put <id> <local> <remote> | Upload a local file |
lizard sandbox files get <id> <remote> <local> | Download a file |
lizard sandbox files rm <id> <path> | Delete a file or directory |
Coding agents
Run a coding agent inside a sandbox on your own credentials. Connect them first with lizard agents. Create the sandbox from an agent template (codex, claude, opencode, pi, or prime); the base template has no Node.js and can’t run agents.
lizard sandbox prompt <id> <prompt...> sends a prompt and streams what the agent does.
| Flag | Description |
|---|---|
--agent <name> | codex (default), claude, pi, opencode, or prime |
-c, --conversation <id> | Continue this conversation |
--new | Start a new conversation |
-m, --model <model> | Model to use |
--effort <level> | Reasoning effort: minimal, low, medium, high, or xhigh |
--cwd <dir> | Working directory in the sandbox (default /workspace) |
-v, --verbose | Also print command output |
--no-wait | Return once the prompt is accepted |
Ctrl-C stops watching; the agent keeps working. lizard sandbox interrupt <id> [-c <conversation>] stops its running turn. lizard sandbox conversations <id> lists the conversations, newest first.
Examples
Create a sandbox and run a command
lizard sandbox create --size small --timeout 600000
lizard sandbox exec genuine-toddler-jasj -- python3 -c "print(1 + 1)"Open a shell
lizard sandbox ssh genuine-toddler-jasjAttach a Persistent Volume
lizard volume create agent-workdir --size 10
lizard sandbox create --volume agent-workdirServe a port
lizard sandbox exec genuine-toddler-jasj -- sh -c "nohup python3 -m http.server 3000 --bind 0.0.0.0 >/tmp/http.log 2>&1 &"
lizard sandbox expose genuine-toddler-jasj 3000Use a desktop from a VNC app
lizard sandbox create -t desktop
lizard sandbox vnc genuine-toddler-jasj --openRun Codex in a sandbox
lizard agents login chatgpt
lizard sandbox create -t codex
lizard sandbox prompt genuine-toddler-jasj "add a health check endpoint and test it"Save and restore a sandbox
lizard sandbox snapshot genuine-toddler-jasj --name my-app
lizard sandbox snapshots --mine # find the snapshot ID
lizard sandbox restore <snapshot-id>Fork a prepared sandbox
lizard sandbox fork genuine-toddler-jasj -n 8 --json # 8 copies with the same memory and files
lizard sandbox rm <copy-id> # delete a copy when its work is doneSee also
- Sandboxes — runtime, templates, and lifecycle
- Sandboxes quickstart — the same steps from the Lizard SDK
- lizard volume — Persistent Volumes to attach with
--volume - lizard agents — credentials for
sandbox prompt - Limits — sizes, running limits, egress, and lifetime
Updated