Inference cost is the recurring expense of running a trained model to produce outputs, such as generated text, classifications or embeddings, as opposed to the one-time expense of training it. In AI in business, the cost of inference is usually expressed per million tokens, per request or per hour of GPU time, and it scales directly with usage, which makes it the dominant operating cost of production AI for most organizations.
Unlike AI training cost, which is incurred once per model version, inference cost grows with every user, every document and every agent step. A pilot that costs a few hundred dollars a month can become a six- or seven-figure annual line item once it reaches full adoption, so finance and engineering teams treat inference economics as a design constraint rather than an afterthought.
What drives the cost of inference
The cost of inference is determined by the compute and memory consumed per output, multiplied by the price of that capacity. For large language models, the main drivers are model size, the number of input and output tokens, the hardware used and how efficiently requests are batched on that hardware.
Output tokens are typically three to five times more expensive than input tokens on commercial APIs, because generation happens one token at a time and cannot be parallelized as well as reading the prompt. Long contexts add cost through the key-value cache, which occupies accelerator memory and limits how many requests can share one GPU.
The following table summarizes the principal cost drivers and how each one shifts the bill.
| Driver | Effect on cost | Typical lever |
|---|---|---|
| Model size | Larger models need more compute per token | Route simple tasks to smaller models |
| Output length | Each generated token is priced at a premium | Set length limits and concise formats |
| Context length | Long prompts raise input charges and memory use | Retrieve only relevant passages |
| Batch utilization | Idle accelerators still cost money | Batch requests and share capacity |
| Latency target | Faster responses need reserved headroom | Use asynchronous or batch tiers |
| Agent steps | Each tool call adds another model invocation | Cap iterations and cache results |
Pricing models for inference
Organizations pay for inference through one of several commercial arrangements, and the choice changes both the unit price and the financial risk. Token-based pricing through a model-as-a-service API converts inference into a pure variable cost, while self-hosting on owned or rented GPUs converts much of it into a fixed cost that becomes cheaper only at high, steady utilization.
The table below compares the common models from the buyer’s perspective.
| Pricing model | Unit of charge | Best fit | Main risk |
|---|---|---|---|
| Pay-per-token API | Input and output tokens | Variable or early-stage workloads | Bills grow with uncontrolled usage |
| Batch API tier | Discounted tokens, delayed results | Offline document processing | Results arrive in hours, not seconds |
| Provisioned throughput | Reserved capacity per hour or month | Predictable high-volume traffic | Paying for unused capacity |
| Self-hosted open model | GPU hours plus operations staff | Very high volume or strict data rules | Engineering effort and idle hardware |
| Per-seat software license | Users per month | Packaged assistants for employees | Vendor absorbs cost, then raises prices |
Many providers also offer prompt caching, which charges a reduced rate for repeated prompt prefixes such as long system instructions. For workloads that reuse the same context across many calls, caching can cut input charges by well over half, although the exact discount and cache lifetime vary by provider.
Inference cost compared with related cost concepts
Inference cost is one component of the total cost of ownership of an AI system, and it is often confused with neighboring concepts. Separating them matters because each is controlled by different decisions and owned by different teams.
| Concept | What it measures | When it is incurred |
|---|---|---|
| Inference cost | Compute to serve each prediction | Continuously, with every request |
| AI training cost | Compute and data to create a model | Once per model version |
| Fine-tuning cost | Adapting an existing model to a task | Occasionally, per adaptation cycle |
| AI capital expenditure | Data centers and accelerators | Upfront, then depreciated |
| Total cost of ownership | All costs including staff and integration | Over the full system life |
At the industry level, the share of spending devoted to inference has grown as models moved from research into products. Reasoning models, which generate long internal chains of thought before answering, have reinforced this shift because they can consume ten times or more tokens per answer than a standard model on the same question.
How organizations reduce inference cost
Inference cost is reduced by matching the model to the task and by eliminating wasted tokens. The most effective measures are architectural rather than contractual, and they usually deliver larger savings than negotiating a lower unit price.
| Technique | How it saves money | Typical trade-off |
|---|---|---|
| Model routing | Sends easy requests to a cheap model | Needs a reliable classifier |
| Quantization | Runs weights at 8 or 4 bits | Small accuracy loss on some tasks |
| Distillation | Trains a small model on large-model outputs | Upfront training effort |
| Semantic caching | Reuses answers to similar questions | Risk of stale or mismatched answers |
| Prompt compression | Removes redundant context | May drop useful details |
| Batch processing | Uses discounted non-urgent tiers | Higher latency |
Measurement comes first. Teams practicing AI FinOps tag every request with the product feature, customer and model that generated it, then report cost per successful task rather than cost per token. A cheaper model that needs three retries to finish a task is not cheaper in practice.
Common mistakes in estimating inference cost
Inference budgets are frequently wrong because early estimates use pilot traffic and short prompts, which rarely resemble production behavior. Several recurring errors explain most budget overruns.
- Ignoring output tokens: estimating only from prompt size understates the bill, since outputs carry the higher price.
- Underestimating agent loops: an AI agent may call the model 10 to 50 times for a single user goal.
- Assuming falling prices solve the problem: per-token prices have dropped sharply, yet usage typically grows faster, so total spending still rises.
- Forgetting hidden reasoning tokens: reasoning models bill for internal tokens that the user never sees.
- Treating self-hosting as free: owned GPUs carry depreciation, power, staff and idle-time costs.
A sound AI business case therefore models inference cost as a function of adoption, with low, expected and high usage scenarios, and links it to the value each request creates. This connection is what determines AI return on investment.
A non-technical view
Building an AI model is like building a factory. Inference is running that factory every day. Each answer the AI gives costs a small amount of electricity and computer time.
One answer is cheap. Millions of answers are not. That is why inference cost grows as more people use the tool. A company pays it every month, not once.
The key idea is simple. Use the smallest model that does the job well, and avoid asking the AI for more text than needed.
A concrete example
A mid-sized insurance company deploys a language model to summarize incoming claim documents. Each claim averages about 6,000 input tokens and 800 output tokens, and the company processes roughly 40,000 claims per month. Using a large frontier model through a pay-per-token API, the monthly bill reaches several thousand dollars, and projections show it tripling within a year as more claim types are added.
The team then routes standard claims to a smaller, cheaper model and reserves the large model for complex cases, which make up about 15 percent of volume. Because summaries are not needed instantly, overnight processing moves to a discounted batch tier. Shared instructions are placed at the start of every prompt so that prompt caching applies.
After three months, the company reports a cost reduction of roughly 70 percent per processed claim, while reviewer satisfaction scores remain unchanged. The finance team now tracks cost per summarized claim as a standing operational metric.