Insight

Reasoning Token Cost: What reasoning_effort Actually Bills

Reasoning token cost explained: thinking tokens bill at the output rate, so a 400-token answer can bill 12,400. Math at three effort levels and how to cap it.

Reasoning models hide one pricing detail in plain sight: the tokens they spend thinking are billed at the output rate, and they never appear in the answer you read. That is the whole story of reasoning token cost. A task that shows 400 tokens can bill 12,400 output tokens, and on a model whose output rate is five times its input rate, that is the gap between about half a cent and three cents for the same visible result.

This post covers where reasoning tokens surface in the response, illustrative cost math at three effort levels, and the two settings that keep a thinking budget from becoming a surprise. It is AtmoRouter-authored and makes no benchmark claims; reasoning lengths only mean something on your own tasks.

Why a short answer bills thousands of tokens

Models that reason before answering generate internal tokens ahead of the visible reply. Those tokens are billed at the model's output rate, not from a separate bucket, and they count against the response's output cap. On Chat Completions, max_completion_tokens covers reasoning and visible output together.

A quick live check makes the point. We asked alicn/deepseek-v4.1-flash how many primes lie between 1000 and 1100, answer as a number only, with reasoning_effort set to high. The visible answer was two characters. The response reported 2,215 completion tokens, 2,212 of them reasoning, and a charged cost of $0.000385. Cheap on that model, but the ratio is what carries over to expensive ones.

Two consequences follow. Cost variance lives on the output side, because reasoning length moves with task difficulty, so the same prompt can bill very differently twice. And a response can stop at the cap before it produces any visible text: you pay for input and the reasoning spent so far, and get an empty-looking result. On Chat Completions that response comes back with finish_reason set to "length"; check it instead of treating an empty message as a model failure.

Read the real number instead of estimating it

The counts are reported in usage, so you never have to guess. Treat the breakdown as optional: some models report completion_tokens_details.reasoning_tokens, others only fold reasoning into completion_tokens. On AtmoRouter the response also carries the charged amount in usage.cost and, for non-streaming calls, in the X-Atmorouter-Cost header. The snippet reads rates from /v1/models at startup instead of hardcoding them.

pythonimport os
import requests
from openai import OpenAI

BASE = "https://atmorouter.dev/v1"
client = OpenAI(base_url=BASE, api_key=os.environ["ATMOROUTER_API_KEY"])

catalogue = requests.get(f"{BASE}/models", timeout=30).json()["data"]  # live rates
RATES = {m["id"]: m["pricing"] for m in catalogue if m.get("pricing")}  # USD per 1M tokens

def run(model: str, effort: str, prompt: str) -> dict:
    resp = client.chat.completions.create(
        model=model,
        messages=[{"role": "user", "content": prompt}],
        reasoning_effort=effort,       # accepted values vary by model
        max_completion_tokens=16_000,  # reasoning + visible output
    )
    u = resp.usage
    details = getattr(u, "completion_tokens_details", None)
    reasoning = (getattr(details, "reasoning_tokens", None) or 0) if details else 0
    rate = RATES[model]
    estimate = (u.prompt_tokens * rate["input"]
                + u.completion_tokens * rate["output"]) / 1_000_000
    charged = (u.model_extra or {}).get("cost")  # AtmoRouter's usage.cost
    return {
        "effort": effort,
        "finish_reason": resp.choices[0].finish_reason,
        "reasoning_tokens": reasoning,
        "completion_tokens": u.completion_tokens,
        "estimate_usd": round(estimate, 6),
        "charged_usd": charged,
    }

print(run("alicn/deepseek-v4.1-flash", "high",
          "How many primes are between 1000 and 1100? Number only."))

If your estimate and charged_usd disagree, trust the charged figure and fix your assumptions (cached input, tier, or a reasoning count your model does not itemise).

Output rates are three to five times input rates

Rates below are from the live AtmoRouter catalogue at the time of writing, as from $X / $Y per million input/output tokens. "From" means the cheapest tier listed; models carry several tiers, rates refresh, and the model page is authoritative.

| Model | From input | From output | Output ÷ input | 10k reasoning tokens | |---|---|---|---|---| | mm/MiniMax-M3.1-Flash | $0.000375 | $0.0015 | 4.0x | $0.000015 | | zai/glm-5.3 | $0.0035 | $0.011 | 3.1x | $0.00011 | | alicn/deepseek-v4.1-flash | $0.043125 | $0.1725 | 4.0x | $0.001725 | | grok/grok-4.7 | $0.095 | $0.285 | 3.0x | $0.00285 | | cx/gpt-6-astra | $0.475 | $2.375 | 5.0x | $0.02375 | | oai/gpt-6-astra | $7.25 | $36.25 | 5.0x | $0.3625 |

Cached input bills at 10% of the input rate where the model supports it, but that discount applies to prompt prefixes only. Reasoning tokens are fresh output every time, so caching never touches them.

Illustrative math at three effort levels

Assume a 3,000-token prompt, a 400-token visible answer, and 800 / 3,000 / 12,000 reasoning tokens for low, medium and high effort. Those spans are plausible for a non-trivial task; they are not a benchmark. Rates are cx/gpt-6-astra at from $0.475 / $2.375 per million input/output tokens.

| Effort | Reasoning | Billed output | Cost per request | Per 1,000 requests | Reasoning share of cost | |---|---|---|---|---|---| | low | 800 | 1,200 | $0.0043 | $4.28 | 44% | | medium | 3,000 | 3,400 | $0.0095 | $9.50 | 75% | | high | 12,000 | 12,400 | $0.0309 | $30.88 | 92% |

Three observations. At high effort the visible answer is 400 tokens, but billed output is 31 times that. The same 12,400 output tokens on oai/gpt-6-astra (from $7.25 / $36.25) cost about $0.45 in output alone, roughly $471 per 1,000 requests at that effort. And caching two-thirds of the prompt on the cheaper model saves only about $0.0009 per request: it shifts the input line, not the conclusion that effort sets the bill.

Two settings that keep effort from running away

Size the cap to effort, not to answer length. If you set max_completion_tokens=1024 because answers run about 400 tokens, high-effort calls will truncate mid-thought and still bill input plus all reasoning spent so far, with no usable text. Leave headroom: OpenAI's reasoning guide recommends reserving at least 25,000 tokens for reasoning and output while you are still experimenting, then tightening once you have real usage data.

Escalate effort only where your evals justify it. Accepted reasoning_effort values differ between models, so test the ones you plan to use. Start low on classification, extraction and retrieval-style calls, then measure whether higher effort actually reduces the number of turns or retries a task needs. If it does not, you are paying output rates for thinking that changes nothing.

Track cost per resolved task, not per token

Log three numbers per request: reasoning tokens as a share of output (where the model reports them), the charged cost from usage.cost or X-Atmorouter-Cost, and whether the task actually finished. A model that costs twice as much per request but resolves in one turn usually beats one that needs three retries at half the price per call. Per-token tables hide that, which is why the effort knob, not the headline rate, is where most reasoning spend is won or lost. One more floor to remember: a minimum request charge applies, so very small calls do not divide down to zero.

FAQ

Are reasoning tokens billed separately?

No. There is no separate reasoning price. They are counted inside output (completion) tokens and billed at the model's output rate.

Why don't I see reasoning_tokens in usage?

Not every model itemises them. Some only fold reasoning into completion_tokens, which is why a two-word answer can still show hundreds of completion tokens. The charged cost in usage.cost is correct either way.

Can I cache reasoning tokens to cut the cost?

No. Only input prefixes are cacheable. Reasoning is generated fresh per request, so it is always billed at the full output rate.

Does max_completion_tokens include reasoning?

Yes. On Chat Completions it caps reasoning and visible output together, so a cap sized for the answer alone can cut a response off before any text appears.

Next step

If your agent also pays for tool schemas and long histories, the math in tool calling token cost per turn and long context API cost covers those lines. To see what your current effort setting really bills, create a key on AtmoRouter, run the snippet above against two or three models, and check live rates on each model page before you budget.

Newer

How to Set Up Roo Code With an OpenAI-Compatible API (AtmoRouter)

Older

How to Set Up Goose With an OpenAI-Compatible API (AtmoRouter)

Build with AtmoRouter.