Two invoices, usually confused into one. The model bill is tokens or a subscription and it goes to the model vendor. The machine bill is hours or months and it goes to whoever runs the computer the agent sits on. Almost every “Claude Code is expensive” conversation is really about the second one.
Prices below are a dated snapshot, as published in October 2026 — re-verify before quoting, because vendor pricing pages move and an article is not a checkout page.
Bill one: the model
Two shapes, and they suit different working patterns.
| Plan | Monthly, as published October 2026 | Suits |
|---|---|---|
| Pro | $20 | One person, moderate daily use, cloud sessions included |
| Max | from $100 | All-day use, several parallel sessions |
| Team | $25 per seat, premium seat $125 | Shared billing, admin controls |
The API is metered instead. Prices per million tokens, as published October 2026:
| Model | Input | Output | A small task, roughly |
|---|---|---|---|
| Opus 5.5 | $4 | $20 | 1M in + 100k out ≈ $6 |
| Sonnet 5.5 | $2 | $10 | 1M in + 100k out ≈ $3 |
| Haiku 5.5 | $0.10 | $0.50 | 1M in + 100k out ≈ $0.15 |
That last column is the only one most people need. The token counts are made up for scale — a real task is often 50k input and 5k output — but the ratio between rows is real, and it is why the model choice moves the bill by an order of magnitude while the machine choice moves it by a factor of two.
Prompt caching is the other lever that matters. A coding agent resends the same repository context constantly; cached reads are billed at a fraction of fresh input, and a session that starts with a cold cache pays for the whole context once. Long sessions with a stable context are much cheaper per turn than many short ones.
Bill two: the machine
Here the arithmetic is simple and the variance is enormous.
| Where it runs | What you pay for | Idle cost | What it cannot do |
|---|---|---|---|
| Your laptop | Nothing extra | Zero — and everything stops when it sleeps | Run while closed |
| Vendor cloud sessions | Counts toward plan usage; no separate VM charge as published October 2026 | Nothing while you are not using it | Keep a workspace across a reclaim |
| Small VPS | A monthly charge, running or idle | Full price while idle | Size up without migrating |
| Cubs | $6 per vCPU per month running, $2 paused, metered per second from prepaid credit | The paused rate keeps the disk | Resize after creation |
A 4 vCPU / 8 GB machine on Cubs is $24 a month running, $8 paused, $0.0329 an hour. The same shape elsewhere, as published in October 2026 — the first six rows are that shape, the Hetzner row is not and is included because it is the number readers ask about:
| Provider | Monthly, as published October 2026 |
|---|---|
| Cubs | $24 running, $8 paused |
| boat.dev | $26.28 |
| exe.dev | $35 |
| DigitalOcean | $48 |
| AWS c6a.xlarge | $111.69 |
| A sandbox provider at per-second rates | about $245 |
| Hetzner CX23 (their smallest shared plan, from) | €5.49 plus €0.50 for IPv4 |
The Hetzner row is there deliberately: it is not the same machine. A CX23 is a smaller, cheaper shared plan, and it is the honest low-cost option if you are willing to maintain it — patching, keys, backups, and a reboot at the wrong moment are your problem rather than a line item. The bottom row is at the other extreme and is not a mistake either; per-second sandboxes charge for the shape of work they are built for.
The comparison that actually decides your bill is not provider against provider. It is hours running against hours paused.
# A 4 vCPU machine used 12 hours a day, 30 days, running the rest of the time paused
# running: 360 h x $0.0329 = $11.84
# paused: 360 h x $0.0110 = $3.95 (paused monthly $8 / 730 h)
# total: about $15.79 for the month
Twelve hours of machine time a day for about $16 a month, on a machine that keeps its disk — before the model bill, which is the other half. The same machine left running around the clock is $23.67. Neither number is large; four machines is where it starts to be.
Three setups, priced
1. Laptop only. Model bill only, no separate machine bill, and the agent stops when the lid closes. Fine for a task you are sitting at, useless for anything overnight. The hidden cost is the retry after the lid closed at 60% of a long job.
2. Vendor cloud sessions. Model bill only, no separate VM charge as published October 2026. The least setup of the three for working from a phone. The cost is not money, it is the reclaim: background shell commands and subagents do not survive an expired environment, so anything worth keeping has to be committed and pushed before you walk away.
3. A machine you keep. Model bill plus $24 a month for 4 vCPU, less if you pause. Adds the thing the first two cannot: the same disk tomorrow, a dev server someone can open, and a machine you can SSH into while the agent works. This is the setup the other guides in this set assume.
Put next to a full-time API user, the machine is the smaller bill by a wide margin. Put next to a Pro subscriber, it doubles the total. Both are honest descriptions; which one applies depends on whether you are running an agent or answering one.
Six ways to spend less
- Pause the machine. The single largest lever, and the one people forget. A paused machine at $2 per vCPU keeps the disk and costs a third of a running one. Pausing before you close the laptop for the evening is a habit worth forming; leaving the agent running deliberately is a different decision.
- Size for the workload, not the peak. An agent that needs 8 GB once a week does not need a 16 GB machine every day. On Cubs the size is fixed at creation, so the honest move is to measure
free -hunder a real build and pick one step above that. - Use the cheap model for the boring half. Haiku at $0.10/$0.50 against Opus at $4/$20 is a 40× difference on input. Renames, test scaffolding and log triage do not need the expensive model; the design decision does.
- Keep the context stable inside a session. Prompt caching rewards a long session with an unchanging prefix. Restarting the agent every twenty minutes throws the cache away and re-bills the repository context.
- Stop paying for idle agents. Four agents left attached overnight are four sessions drawing on a plan’s limits for nothing. If a task is not running, close it.
- Do not run a build suite four times in parallel. Each agent running the full test suite on its own worktree multiplies both the machine size you need and the time you spend waiting. Run the fast subset per agent and the full suite once before the merge.
The number that is not on either bill
An agent that dies at 3am costs nothing in compute and everything in the morning. That is the real argument for the third setup above, and it is not a rounding error: a night of lost work is worth several months of machine time at any of the prices in this article.
Where Cubs fits
Cubs is the machine half of the bill and nothing else: $6 per vCPU per month while running, $2 while paused, metered per second from prepaid credit, with a $25 starter credit and no card required. Model usage is never billed by the platform — your Claude or Codex subscription or API key is your own, which keeps the two bills separate and auditable. Monthly figures are estimates on 730 hours, not a subscription, and a machine keeps the price it was created with.