What a coding agent costs per month

The answer is not a number, it is a range: about $4 to $78 a month for the same agent doing the same work. The entire spread comes from one decision Which model the agent calls.

Rates are per million tokens, and the two directions are priced separately.

Across 223 catalogue models that publish both rates, the median output rate is 4.0× the input rate, and 70% of them (155 models) charge at least 4× more for output than input. The other 625 raw catalogue entries are dropped by cleaning, test entries, dated snapshots and non-chat variants, not for a missing rate. This is why an agent workload is decided on the output column, not the input one everyone quotes.
An agent is one of the most output-heavy workloads there is, so that ratio decides more of the bill than the headline input rate does.

You need a key before the code below runs. Create an account, generate a key, and copy the base URL (https://aicomp.ai/v1). Create one free →
Check current rates → Free to sign up · $1 minimum top-up · No prepayment

Three workloads, priced

A day of work on this page's workload is 250k input and 50k output tokens — 5M input and 1M output across a 20-day month. That is the middle column below. The light column is roughly a third of that, the heavy column is roughly three times it.

Per 1M input / output tokens and a 20-day month
ModelGateway rate
in / out per 1M tokens
One day20 days
gpt-5-mini$0.125 / $1.00$0.08$1.62
claude-sonnet-5$1.00 / $5.00$0.50$10.00
kimi-k3$1.5 / $7.5$0.75$15.00
qwen3.8-max$1.00 / $3.00$0.40$8.00
deepseek-v4-flash$0.15 / $0.60$0.07$1.35

One day = 250k input + 50k output on this page's workload. 20 days = 5M input and 1M output. Rates checked 2026-10-22 (gateway rates move with upstream promotions), so verify the current number in your dashboard before committing to a budget.

Two things to take from the table. First, the ordering changes between columns. A model that looks reasonable at light volume can move several places at heavy volume, because the monthly total is a weighted sum of two very differently priced directions.

Second, the gap between the cheapest and most expensive row is roughly 18x at every workload. Whatever else you optimise, the model choice is the biggest single lever, and it is the one that takes a minute to change.

Where the money goes in an agent session

An agent session spends input tokens on three things: the system prompt and tool definitions, the accumulated conversation, and the results of every tool call it made. It spends output tokens on tool calls themselves, on the code it writes, and on the explanation it gives afterward.

The input side compounds and the output side does not. Every turn re-sends the conversation so far, which is why a session that runs long costs disproportionately more than two shorter sessions doing the same work. The output side is roughly linear in how much the agent actually produced.

That asymmetry is the reason a per-token comparison misleads: the same agent, run with long sessions instead of short ones, can cost twice as much on an identical model.

Estimating your own number

Count the days, not the requests. Take one representative day of agent work, split the tokens into input and output — dashboards that report only a combined total hide the split that decides the bill, then multiply by working days and apply the two rates separately.

If you cannot split them, assume output is more expensive than it looks. On the median model it is 4x the input rate, and agent work emits far more output per request than a chat workload does.

Get API access

FAQ

FAQ

How much does a coding agent cost per month?

On API rates, roughly $4 to $78 a month at 20 working days, depending on the model and how long your sessions run. The low end is a low-cost model with short sessions; the high end is a frontier model with long ones.

Why is output priced separately from input?

Because generating tokens costs more compute than reading them, and vendors pass that through. The median output rate is 4x the input rate, so workloads that generate a lot (which agents do) are priced very differently from workloads that mostly read.

Does a longer session cost more than two short ones?

Yes, usually noticeably. Every turn re-sends the full conversation, so cost grows with the square of session length on the input side. Splitting one long session into shorter ones is the cheapest optimisation available.

Is a cheaper model worse for coding?

Not necessarily, but the cheap rows here are cheap partly because their output rates are low, not only their input rates. For agent work, compare output rates first, that is the direction you are buying most of.

Related

Get API access