Why are output tokens typically 3-5× more expensive than input tokens?
Same topic, related formats. Practice these next.
Same topic, related formats. Practice these next.
Explain the physical reason output tokens are priced 3-5× higher than input tokens. Tie the pricing back to the underlying hardware utilization.
Input is one parallel prefill pass that saturates compute, so it is cheap per token. Output is N sequential decode steps, each gated by HBM bandwidth, so providers price it 3-5x higher.
Imagine a bakery oven. Reading your order (the input) is like baking a full tray at once: you heat the oven once and dozens of cookies come out together, so each cookie is cheap. Writing the reply (the output) is like baking one cookie, taking it out, then reheating the whole oven for the next single cookie. The expensive part is not the cookie, it is firing up that huge oven again and again for one item at a time. The model weights are the oven, and loading them from memory is the reheating. Input bakes a whole tray in one pass. Output reheats per cookie. That is why the company charges you more for each word it writes than for each word it reads.
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example.
Everything important, quickly.
4 min: prefill compute-bound versus decode bandwidth-bound, the roofline and arithmetic intensity argument, the per-instance decode throughput ceiling, how batching narrows the gap, then map the throughput ratio onto the 3-5x price band.
Real products, models, and research that use this idea.
What an interviewer would ask next. Try answering before peeking at the approach.
Red flags and common mistakes that signal junior thinking. Click to expand.
Claiming output costs more because generation does more math. It is the opposite: decode does the same matmuls as prefill but spreads them over one token per weight read, so it is bandwidth starved, not compute heavy.
The night-before-the-interview bullets. Scan these on the way to the call.
Primary sources. Skim if you want the original framing.