Runtime's default floor is 50 millicores, a twentieth of a vCPU, which costs $0.00125 an hour. That is why a 2 vCPU, 4 GiB sandbox waiting on a model costs $0.03125 an hour, memory plus the floor, and not the price of two whole cores (pricing).
Why it matters for AI agents
An agent's sandbox spends most of its life waiting: for the model to answer, for a person to reply, or for the next tool call. Providers that bill every allocated vCPU charge full price for that wait. A provider that bills measured CPU still has to guarantee the machine something, or a busy neighbor could starve it. The floor is that guarantee. It is also what you pay for when the sandbox does nothing. A small floor makes waiting cheap. A larger one buys steadier performance under contention.
The floor in numbers
You set cpuFloorMillis in thousandths of a vCPU. CPU costs $0.025 per
vCPU-hour of measured use. The floor's hourly price is the floor multiplied by
that rate:
cpuFloorMillis |
Share of one vCPU | Floor cost an hour | 2 vCPU, 4 GiB sandbox, idle |
|---|---|---|---|
| 50 (default) | 1/20 | $0.00125 | $0.03125 |
| 250 | 1/4 | $0.00625 | $0.03625 |
| 500 | 1/2 | $0.0125 | $0.0425 |
| 1,000 | 1 | $0.025 | $0.0550 |
Memory adds $0.0075 per GiB-hour, whatever the floor. Above the floor, the
sandbox bursts up to its vcpu count. You pay for the CPU it measures.
Set a floor
TypeScriptimport { Sandbox } from "withruntime";await using sbx = await Sandbox.create({ vcpu: 2, cpuFloorMillis: 500 });console.log(sbx.info.cpu, sbx.info.cpuFloorMillis); // "shared" 500Pythonfrom withruntime import Runtimeruntime = Runtime()with runtime.sandboxes.create(vcpu=2, cpu_floor_millis=500) as sbx: print(sbx.info["cpu"], sbx.info["cpuFloorMillis"])A fork or a snapshot copy keeps its source's floor. It is billed as a create with that floor would be. A copy made without credit must fit the no-credit limits. So a sandbox with a floor above 250 forks only when the account has paid credit (snapshots and forks).
When to raise it
- Keep the default for agents that mostly wait. Also keep it for short jobs whose measured CPU is well above the floor anyway. In the standard example of 60-second runs with 20 CPU-seconds of work, the floor adds nothing.
- Raise it for a latency-sensitive server that must respond quickly even when the host is busy.
- Reserve every core with
cpu: "reserved"when the work needs whole vCPUs all the time. See shared vs reserved CPU.
Related
- Shared vs reserved CPU
- The sandbox environment: disk, CPU and memory
- Sandbox cost calculator
- What is a spending limit?
Facts on this page were checked on 25 October 2026.