← Blog

Awake-time billing for agent sandboxes: what you pay for and what you don't

How Sandscale bills agent sandboxes by awake vCPU-hours, with idle time free. Includes a worked example with the arithmetic shown.

An agent run is mostly waiting. It calls a model, waits for tokens, runs a command for a few seconds, waits for the next tool call, and sometimes sits for an hour because a person has to approve something. If a sandbox bills for every second it exists, you pay for that waiting. Sandscale bills for the time the box is awake instead. This post explains what that means, how the numbers work, and where the model stops being cheaper than you might assume.

What “awake vCPU-hour” means

The unit is one vCPU running for one hour while the box is awake. A box that is paused, or idle between tool calls, does not count. For how metering works in detail, see pricing.

Sandscale’s own example: a 2 vCPU agent box that is open for 10 hours and awake 10% of the time uses 2 awake vCPU-hours (2 vCPU × 1 awake hour).

So the formula is:

awake vCPU-hours = vCPU count × hours awake

What is free and what isn’t

Free:

  • Paused time. Pausing a sandbox writes its memory out alongside its files. Resuming reads the memory back and the processes carry on. A paused sandbox doesn’t use vCPU-hours. Pause and resume are available on every plan (see pause and resume).
  • Idle time between tool calls. The box stays open and you aren’t charged for the gaps.

Not free:

  • Awake time, at the vCPU count you chose.
  • Storage above your allowance. One allowance covers disks, snapshots, templates and objects: Free 5 GB, Pro 50 GB, Team 100 GB per member (pooled). Above that it is $0.15 per GB-month. The first 10 GB of snapshots and templates is free.
  • Burst above base size, which counts in the same hours (see below).

How memory is counted

Every vCPU comes with 4 GiB of memory, included in the price. Memory above that is converted: 4 GiB-hours of extra memory counts as 1 vCPU-hour. So a 2 vCPU box has 8 GiB included. A 2 vCPU box with 16 GiB has 8 GiB extra, which counts as 2 extra vCPU-hours for every hour, on top of the 2 for CPU.

What your plan includes

Free Pro Team
Price $0 $20/mo billed annually, $25 monthly $40/member/mo billed annually, $48 monthly
Included awake vCPU-hours / month 100 1,500 2,000 per member, pooled
Boxes running at once 3 30 30, more on request
Largest box up to 2 vCPU up to 16 vCPU up to 16 vCPU, 32 on request
Session length up to 4 h up to 24 h up to 24 h
Beyond your hours new boxes wait until next month $0.05 per awake vCPU-hour, or $10 per 500-hour pack, or keep it off same as Pro

Included hours reset every month and do not roll over. Running boxes are never stopped because your hours ran out. On paid plans you decide what happens at the limit: turn on usage beyond the plan at $0.05 per awake vCPU-hour, buy a pack of 500 awake vCPU-hours for $10 ($0.02 per vCPU-hour), or leave it off so new boxes wait. Spend caps can be set per task, agent, project and organization.

A worked example (hypothetical workload)

This is an invented workload for illustration, not a measurement of any real customer or run.

An agent run on a 2 vCPU box (8 GiB, within the included 4 GiB per vCPU):

  • The box is open for 60 minutes.
  • It is awake for 10 minutes, running commands, tests and file edits.
  • It is idle for 50 minutes, waiting on a model or a human reviewer.

Awake-time billing:

2 vCPU × (10 / 60) h = 0.333 awake vCPU-hours per run

If the same run were billed for the whole hour it existed:

2 vCPU × 1 h = 2 vCPU-hours per run

The ratio is 2 / 0.333 = 6. That ratio is just the share of the hour that was awake (1/6). It is not a general claim; if your agent is awake 50 minutes out of 60, the gap nearly disappears.

Over a month

Say a team runs 1,000 such runs in a month, one box per run:

Awake-time:          1,000 × 0.333 = 333.3 awake vCPU-hours
Billed whole hour:   1,000 × 2     = 2,000 vCPU-hours

On the Pro plan (1,500 included hours, $20/month billed annually):

  • 333.3 awake vCPU-hours is inside the 1,500 included. Monthly cost is the plan price: $20.
  • 2,000 vCPU-hours would be 500 over. At Sandscale’s published overage rate that is 500 × $0.05 = $25 extra, or one $10 hour pack (500 hours). So $30 with the pack, or $45 with overage turned on.

The last two lines apply Sandscale’s own rates to a different billing basis to show the shape of the difference. They are not what any other provider charges; other providers have their own rates, rounding and rules, and you should run your own numbers from their published pricing.

On the Free plan (100 hours), the monthly total above would not fit in either case: 333.3 awake vCPU-hours exceeds 100, and new boxes would wait until next month. Free is for trying things out.

A second check, from the pricing page

Sandscale’s own pricing page gives this one: one developer on Pro whose agent keeps a 2 vCPU box open 8 hours every working day, awake a quarter of the time, uses about 88 awake vCPU-hours, inside the 1,500 included.

Burst: when a box gets bigger for a while

A box has a base size and a burst limit you set. Pro allows up to 4× the base; Team up to 8×. The box runs at base size, bursts when a job needs more CPU or memory, then returns to base. Burst draws from the same hours and counts only the CPU actually used above base: a minute at 8 vCPU uses 8 vCPU-minutes.

For the example above, a 2 vCPU base that bursts to 8 vCPU for two of its ten awake minutes would use:

8 vCPU × 2 min + 2 vCPU × 8 min = 16 + 16 = 32 vCPU-minutes = 0.533 awake vCPU-hours

That is above the 0.333 base case. Burst is useful for a test run or a compile step, but it moves the number.

Where this model doesn’t help

  • Busy agents. If a box is awake nearly all the time (long builds, a model running locally, a tight loop of tool calls), awake time is close to wall-clock time and the idle discount is small.
  • Things that must stay on. A workspace that needs to accept connections at any time never sleeps. Sandscale sells an always-on workspace as an add-on: $9 a month for 2 vCPU and 8 GiB, or $19 a month for 4 vCPU and 16 GiB with a 50 GB disk, at a flat price that uses none of your hours. Regular workspaces sleep when idle and wake when you connect (Free: after 30 minutes idle).
  • Storage. Idle boxes cost no vCPU-hours, but disks, snapshots and templates count against the storage allowance whether the box is awake or not.
  • Dedicated cores. If you need guaranteed full speed with no oversubscription, that is $0.04 per vCPU-hour and billed by wall clock, not awake time.

How to keep the number small

  1. Pause instead of leaving a box idle during a long review. Memory and files are kept, so the agent carries on where it stopped. See pause and resume.
  2. Snapshot after setup. Install dependencies once, save the sandbox, and start new ones from that point so the awake clock isn’t spent on pip install every run. See snapshots; the pricing table lists them on every plan.
  3. Set a timeoutSeconds so a sandbox you forgot, or a run that got stuck, is stopped. The quickstart shows timeoutSeconds: 600 on create (see quickstart).
  4. Set spend caps per task or agent, or leave usage beyond your included hours off, so a loop can’t run past your plan. See pricing.
  5. Pick the smallest box that works. Awake hours scale with vCPU count; a 2 vCPU box uses half of what a 4 vCPU box does for the same wall-clock work, if the job isn’t CPU-bound.

Try it with your own numbers

The only reliable way to know is to look at your own agents. Run a few representative tasks and compare how long each box is open with how long it is awake. If the plan limits matter to you, the plans reference lists them, and pricing has the full table. Free includes 100 awake vCPU-hours a month.

You can start free or read how a sandbox is isolated and started.