Agent Next Sandbox · GPU

GPU sandboxes, by the slice.

A GPU an agent can plan around.

Ask for the VRAM you need, from 0.5 GiB up to 28 GiB on today's RTX 5090. A 0.5 GiB slice runs small CUDA jobs; start at 2 GiB (tier M) for training-sized allocations. Pausing keeps your Python state. Usage is metered per busy second: on pause-capable templates, paused time and truly idle time meter nothing, unless a lease falls back to freeze-only, which happens when other processes in your lease hold VRAM or the VRAM probe is unreadable: the lease then keeps its seat and its paused time is billed.

Live now nvidia.5090 On request every other class: not live today Availability as of 2026-10-22

What it is

One card, many leases

Fractional

VRAM slices, 0.5 to 28 GiB

Each sandbox holds a slice of a shared GPU instead of renting the whole card. Ask for accel.vram_gb or a tier: S 1, M 2, L 8 GiB. Tier XL (32 GiB) needs a larger card, which is not live yet. A 0.5 GiB slice runs small CUDA jobs; start at 2 GiB (tier M) for training-sized allocations. Measured through the public API on 2026-10-17 on one RTX 5090 (nvidia.5090), the largest single torch tensor that allocated (binary search, 8 MiB steps) was: 0.5 GiB slice: 248 MiB; 1 GiB slice: 760 MiB; 2 GiB slice: 1784 MiB. About 264 MiB of each slice goes to the CUDA context and allocator. A create is admitted only if the slice fits what is free on the card; GET /v0/gpu/capacity reports the largest one as max_admit_gib.

State

Pause and resume

On pause-capable templates, pausing releases the GPU, unless other processes in your lease hold VRAM or the VRAM probe is unreadable, in which case the lease freezes, keeps its seat and bills its frozen time. When the GPU is released, your GPU state is spilled to host memory and restored bit-exact on resume. Your Python variables persist across execs and across pause and resume.

Billing

Busy-second billing

Every exec is billed from dispatch to result, and a resume bills the time it takes to restore your state. Idle residency bills only while the GPU is observed active, and suspended time bills 0, unless a lease falls back to freeze-only, which happens when other processes in your lease hold VRAM or the VRAM probe is unreadable: the lease then keeps its seat and its paused time is billed. Templates that cannot release the GPU bill while they hold it. Read billed seconds from meters.billed_s on get and exec replies, and from billed_s in the delete reply body; create, pause and resume replies carry no meters.

Planning

Typed refusals, an optional queue

When no seat is free, a create answers at once with a typed error and Retry-After. GET /v0/gpu/capacity shows free seats before you ask, and accel.wait_s (0 to 120 s) makes a create wait for one.

Isolation

A hard VRAM cap

The slice is enforced, not advisory: an over-slice allocation fails inside your job, and on hard-cap hosts, which includes our RTX 5090 node, a watchdog kills a lease that goes past its cap within about a tenth of a second. In 10 hostile-tenant trials at the shipped cap on rented A100 40 GB hosts at full density, the attacker (3 extra CUDA contexts) was stopped in all 10; its neighbours saw 0 errors in 9, and in the tenth one neighbour request was refused for capacity before the attack began.

API

REST, MCP, CLI

The same verbs and X-API-Key auth as the E2B-compatible CPU sandboxes, with an extra accel object on create. GPU leases are driven over REST, the remote MCP server or the sbx gpu verbs of the open-source sbx CLI (create, exec, pause, resume, kill, templates, info), not the stock E2B SDK, which drives CPU sandboxes only.

Templates include default (the plain CUDA worker) and mujoco; the full list is in the templates docs. A template is an operator-allowlisted image, so a request can only pick a name from that list; GET /gpu/templates lists what this plane serves.

Quickstart

Create, exec, destroy

set -euo pipefail
API=https://api.sbx.agent-next.com; H="X-API-Key: $SBX_API_KEY"
ID=$(curl -fsS -X POST -H "$H" -H 'Content-Type: application/json' \
  -d '{"accel": {"vram_gb": 2}}' "$API/sandboxes" |
  python3 -c 'import json,sys; print(json.load(sys.stdin)["sandboxID"])'); test -n "$ID"
curl -fsS -X POST -H "$H" -H 'Content-Type: application/json' \
  -d '{"code": "report[\"gpu\"] = torch.cuda.get_device_name(0)"}' "$API/sandboxes/$ID/exec"
curl -fsS -X DELETE -H "$H" "$API/sandboxes/$ID"   # the reply is the final meter snapshot; billed_s is at its top level

The exec body is Python source run in the lease's worker; torch is pre-bound on the default template and report is returned in the reply. Send cmd instead of code to run a shell command. GPU needs an invited key; the free tier has no GPU.

To plan before you create, read the free seats first, or ask the create to wait for one:

set -euo pipefail
API=https://api.sbx.agent-next.com; H="X-API-Key: $SBX_API_KEY"
curl -fsS -H "$H" "$API/v0/gpu/capacity"   # free seats and the largest slice a create is admitted for
ID=$(curl -fsS -X POST -H "$H" -H 'Content-Type: application/json' \
  -d '{"accel": {"tier": "S", "wait_s": 30}}' "$API/sandboxes" |
  python3 -c 'import json,sys; print(json.load(sys.stdin)["sandboxID"])'); test -n "$ID"
curl -fsS -X DELETE -H "$H" "$API/sandboxes/$ID"   # delete the lease when you are done with it

With wait_s, the create answers 201 as soon as a seat is admitted. If none frees in time it returns the typed gpu_capacity_exhausted refusal with Retry-After, so set your client timeout above wait_s.

Availability and price

Which GPU classes are live

Each row says whether the class is live now or on request. A class on request cannot be created yet: asking for it answers the typed gpu_class_unavailable refusal (400) and places nothing. The price in its row is the list price that applies once it is live. Pick a class with accel.class on create. Prices are per second on the exact slice you request, with no minimum billing, and every class sells from 0.5 GiB. Live seat counts need a key: GET /v0/gpu/capacity.

GPU classes: availability, and list price when available
Class Availability List price when available, $ per busy GiB-hour 0.5 GiB sandbox, per busy hour 4 GiB sandbox, per busy hour
nvidia.5090Live now$0.13$0.065$0.52
nvidia.rtx6000On request$0.10$0.05$0.40
nvidia.a10On request$0.18$0.09$0.72
nvidia.a6000On request$0.08$0.04$0.32
nvidia.a100-40gOn request$0.17$0.085$0.68
nvidia.gh200On request$0.08$0.04$0.32
nvidia.h100-pcieOn request$0.14$0.07$0.56
nvidia.h100-sxmOn request$0.18$0.09$0.72
nvidia.b200On request$0.13$0.065$0.52

To ask for a class that is not live, say so in the use-case field when you request beta access.

Paused and truly idle time bill 0 seconds on pause-capable templates, unless a lease falls back to freeze-only, which happens when other processes in your lease hold VRAM or the VRAM probe is unreadable: the lease then keeps its seat and its paused time is billed. A template with suspend_mode: "none" (for example mujoco) also bills while it holds the card. The verified tier includes 2 GPU-hours per month and 1 concurrent GPU lease. Card verification is not open yet, so every key is on the free tier for now. The free tier has no GPU: GPU is an invite-only beta, and an invited key gets a one-time 10 GPU-hours.

Access and limits

What to expect from the beta

Access

GPU is invite-only

GPU is an invite-only beta: a key needs a GPU grant or a GPU-enabled tier, and the free tier has no GPU. Join the waitlist for an invite. A key without GPU access gets a 403 on GPU calls, and when a key's GPU hours run out they answer 402. The beta runs on one RTX 5090 at a single site, reached over WiFi and a Cloudflare tunnel, and has no SLA. Published limits and known issues are in the GPU guide.

Limits

One lease, one job at a time

A verified key holds one live GPU lease (an invited key's cap is in the GPU guide), and a paused lease counts until you destroy it, so destroy a lease before you create the next one. One job at a time per lease. An exec timeout_s runs up to 3600 s, and a job that overruns it is killed along with its lease. A lease has no network by default.

Refusals

Errors an agent can act on

Refusals you can act on carry a stable error field, for example gpu_capacity_exhausted (409 or 503, with Retry-After), gpu_lease_cap (409), gpu_credit_exhausted (402) and gpu_class_unavailable (400). On a capacity refusal, honor Retry-After and retry the same request.