One Reason Input Tokens Are Cheaper than Output Tokens A laptop benchmark of Qwen2.5-0.5B-Instruct in bfloat16 on an M2 MacBook Pro (16 GB) via PyTorch's MPS backend and Hugging Face transformers found a single output token can take up to 29× longer to generate than an input token, offering an explanation for why LLM APIs charge roughly 5× more for output tokens than input tokens as of October 2026. The author attributes the gap to the two inference phases: prefill processes the whole prompt in one pass and reads the model's weights once, while decode generates one token at a time and must reread all weights for each new token. The measurement separates time to first token (TTFT) from time per output token (TPOT) by timing generation of 1 and 101 tokens with greedy decoding and subtracting TTFT from the total. LLM APIs typically charge more for output tokens than input tokens. As of October 2026, I’ve found that output tokens for models by Anthropic https://platform.claude.com/docs/en/about-claude/pricing , OpenAI https://developers.openai.com/api/docs/pricing , and other providers are roughly 5× more expensive than input tokens. Why is that? I recently started learning about LLM inference and this seemed like an interesting question to dig into. I timed a small model on my laptop, measuring the time spent processing each input and output token. In this experiment, I found that one output token can take up to 29× more time than a single input token, which gave me insight into how tokens are priced. Two Phases for Generating Text with LLMs two-phases-for-generating-text-with-llms LLM inference requires two stages: prefill and decode. In the prefill phase the user’s whole prompt is processed in one pass. This requires reading the model’s weights just once. If you’re familiar with how the basic attention mechanism