How to Estimate AI API Costs: A Low Price per Token Is Not a Low Bill
Understand input, output, caching and repeated calls to estimate what you will really pay.
Edited by NexGateHub AI News · Updated · Method guide
Count the model calls behind one task
A chat message may call a model once. An agent that works on a file may read the document, call tools and then correct its own result. When you estimate, enter the number of model calls, not the number of users. Record the usage of a small batch of real tasks first, then project the monthly cost.
Price input and output separately
Input covers the prompt, the conversation history and any document context. Output is what the model generates. A price per million input tokens is not the price of a whole conversation. The formula is: input tokens per call × input price + output tokens per call × output price, multiplied by daily calls and 30 days, then divided by one million.
Worked example: 2,000 input tokens and 1,000 output tokens per call, with an assumed input price of $0.30 per million and an output price of $1.20 per million, cost $0.0018 per call. At 1,000 calls a day for 30 days that is about $54. These prices are for illustration only.
Cache discounts only count when the cache is hit
Repeated context can qualify for cached input pricing, but the rules differ by provider and model. Do not assume a 100% hit rate from the start. Estimate with 0% first, then adjust with your actual bill. Our calculator uses the normal input price for models without a published cache price, so an unknown discount never appears as savings.
What the token bill leaves out
Tool calls, web search, images and audio, cache writes or storage, and taxes may be billed separately. For reasoning models, billable output can include reasoning tokens you never see. Subscriptions and the API are usually billed differently, and a subscription does not include an equivalent amount of API usage.
Where to cut waste first
Remove unnecessary context and duplicate requests first, then limit long outputs you do not need, and only then compare models. Check quality on the same set of real tasks after each change. A cheap answer that needs repeated fixes may not lower your total cost.