LLM Cost per Request: Cut Your AI Bill in 2026

LLM Cost per Request: Cut Your AI Bill in 2026

Why does one AI request cost a fraction of a cent while another quietly drains a monthly budget? The answer rarely comes down to a single price tag. LLM cost per request is the product of a few moving parts: how many tokens go in, how many come out, which model handles the work, and whether you use discounts like caching or batch processing. Get those parts right, and your AI bill becomes predictable. Get them wrong, and you end up paying flagship prices for work a small model could do in milliseconds.

This article breaks down the real math behind per-request cost, shows where the money actually goes, and offers practical ways to bring the number down without wrecking quality.

The basic formula behind every request

Most commercial AI APIs bill by the token, a chunk of text roughly three-quarters of a word. Since the transformer architecture behind modern language models processes text in these units, providers price input and output separately. Per-request cost follows a simple structure:

Cost per request = (input tokens × input price) + (output tokens × output price), plus any fixed per-call fees, caching discounts, or batch reductions.

Two things trip people up here. First, output tokens usually cost several times more than input tokens, because generating text is heavier work than reading it. Second, output length is the dominant variable in most workloads. A short question with a long answer can cost far more than a long document with a one-line reply.

For a deeper walkthrough of how these token mechanics play out across providers, the explainer on tracking cloud data transfer costs draws a useful parallel: in both cases, the bill tracks usage you can measure, and the surprises come from the parts you didn’t measure.

Why output tokens dominate the bill

Why output tokens dominate the bill

Imagine two requests to the same model. Request A sends a 2,000-token document and asks for a yes/no classification. Request B sends a 50-token question and asks for a 1,500-word essay. On paper, Request A looks bigger. In practice, Request B often costs more, because every one of those generated words is billed at the higher output rate.

This matters for anyone building features like summarizers, chatbots, or report generators. The instinct is to worry about the size of the input. The reality is that controlling response length usually saves more money. Practical levers include:

  • Setting a hard `max_tokens` limit on every call

  • Instructing the model to answer concisely in the system prompt

  • Asking for structured output (JSON, a single label) instead of prose

  • Truncating or summarizing long inputs before they reach the model

A common mistake is leaving `max_tokens` at its default maximum “just in case.” That single setting can multiply worst-case costs by ten or more, especially on reasoning models that generate long internal traces billed as output.

The model tier decision is the biggest lever

Nothing changes per-request cost as dramatically as choosing the right model. Flagship models are priced for hard reasoning, nuanced writing, and complex multi-step tasks. Smaller models like GPT-4o mini, Claude Haiku, and Gemini Flash cost a small fraction of that, and for classification, extraction, routing, and simple Q&A they perform nearly as well.

Workload Typical model tier Relative cost per request
Spam filtering, tagging, routing Small Very low (often sub-cent)
Summarization, extraction Small to mid Low
Customer chat, drafting Mid Moderate
Complex reasoning, code generation Flagship High
Long reasoning traces Reasoning model Highest

A pattern that works well in practice is model routing: send easy requests to a small model and escalate only the hard ones to a flagship. Many teams find that 70 to 90 percent of traffic never needs the expensive tier. The trick is measuring quality on the routed subset rather than assuming the small model is good enough. (Large language model)

If you want to see how engineering teams make cost data actionable rather than abstract, the notes on making cloud cost reviews useful to engineers translate directly: per-request cost only improves when the people writing the code can see it.

Prompt caching: paying less for repeated context

Many applications resend the same large context on every call: a system prompt, a knowledge base excerpt, a set of instructions. Prompt caching lets providers store that prefix and charge a reduced rate when it reappears.

Anthropic introduced prompt caching in August 2024, pricing cache reads at roughly 10 percent of standard input cost at launch, with a premium for writing to the cache. OpenAI added automatic prompt caching in October 2024, discounting cached input tokens by about 50 percent. Exact percentages shift over time, so check current rates before you model savings.

Caching saves work when three conditions hold: the cached prefix is large, it repeats often, and it stays stable across requests. Put volatile content, such as the user’s question, at the end of the prompt so the stable prefix remains cacheable. A frequent error is mixing changing data into the system prompt, which breaks the cache on every call and erases the savings.

Batch processing for non-urgent work

Not every request needs an answer in two seconds. OpenAI’s Batch API, announced in April 2024, offers roughly 50 percent off standard rates for asynchronous jobs with a 24-hour turnaround. Anthropic and Google offer comparable batch discounts.

Batch is ideal for overnight jobs: re-scoring a backlog, generating embeddings for a corpus, classifying thousands of support tickets, or running evaluation suites. The savings are real and require almost no code change beyond switching endpoints. The catch is latency. Anything a user is waiting on should stay on the real-time path.

A practical split many teams adopt: real-time traffic goes through the standard API with caching enabled, while everything that can wait a day goes through batch. That single division often cuts total spend by a third or more.

Prices fall, but so does your margin for sloppiness

Per-token prices have dropped sharply. Between 2023 and 2025, frontier-class pricing fell by roughly an order of magnitude at equivalent capability tiers. GPT-4-class rates that started near $30 per million input tokens and $60 per million output tokens in March 2023 moved toward single-digit dollars within a couple of years. The direction is clear even if exact comparisons depend on which models you treat as equivalent.

Cheaper tokens create a trap. Teams add features freely because each request looks trivial, then discover that volume, retries, and agent loops multiply the count. A request that costs $0.002 is nothing; ten million of them is $20,000. The discipline that matters is measuring cost per successful outcome, not cost per API call. If a request fails and retries three times, you paid four times.

Reasoning models change the math

Models that generate long internal reasoning traces, such as OpenAI’s o1 released in September 2024, bill those hidden tokens as output. A single request can cost many times a standard chat completion, and the reasoning length is not always visible to the caller.

This is a documented pricing characteristic, not a bug. The practical response is to reserve reasoning models for tasks that genuinely need them, cap reasoning effort where the API allows it, and monitor output token counts closely. A reasoning model used for simple extraction is an expensive way to get the same answer.

Self-hosting shifts the cost structure entirely

For open-weight models, per-request cost stops being a list price and becomes an infrastructure question. The number depends on GPU rental or amortization, utilization rate, and throughput in tokens per second. Published benchmarks from inference providers and academic evaluations show wide variance, and there is no single authoritative figure. (NIST Artificial Intelligence overview)

The honest answer is that self-hosting can be cheaper at high, steady utilization and more expensive at low or spiky utilization. It also adds operational work: capacity planning, model updates, monitoring. Teams often start with hosted APIs and revisit self-hosting only when volume justifies a dedicated engineering effort.

What a realistic cost model looks like

Building a per-request estimate that survives contact with production takes a few steps:

  • Log input and output token counts for every call, tagged by feature and model.

  • Multiply by current per-token prices, with an “as of” date attached.

  • Add retries, failed calls, and any agent loops that fan out into multiple requests.

  • Layer in caching and batch discounts where they actually apply.

  • Track cost per successful outcome alongside cost per call.

The last step is where most teams find surprises. A feature with a low per-call cost but a high failure rate can be more expensive than a premium model that gets it right the first time.

It also helps to keep cost visible to the people building features. When per-request cost lives only in a finance spreadsheet, nobody changes behavior. When it shows up in dashboards next to latency and error rates, engineers make better trade-offs on their own. The news and updates section is worth following for how these practices evolve as pricing changes.

Common mistakes that inflate per-request cost

A few patterns show up again and again:

  • No output cap. Leaving `max_tokens` unbounded invites runaway responses.

  • Flagship by default. Using the biggest model for every task because it’s the easiest choice.

  • Broken caching. Putting changing content early in the prompt so the cache never hits.

  • Ignoring batch. Running overnight jobs on the real-time endpoint.

  • No retry budget. Letting failed calls retry indefinitely without a ceiling.

  • Measuring the wrong thing. Tracking average cost per call instead of cost per outcome.

None of these require deep expertise to fix. They require someone to look.

Conclusion

LLM cost per request is not a mystery number handed down by providers. It is a calculation you can control: input tokens times input price, output tokens times output price, adjusted for model tier, caching, and batch discounts. The biggest levers are choosing the right model, capping output length, and measuring cost per successful outcome rather than per call.

Prices will keep moving, and any figure quoted here should carry an “as of” date when you use it. What stays stable is the method. Log your tokens, model your costs, route your traffic, and keep the number visible to the people who write the code. Do that, and per-request cost becomes a design decision instead of a monthly surprise.

FAQ

What is LLM cost per request?

It is the total amount a provider charges for one API call, calculated as input tokens multiplied by the input price plus output tokens multiplied by the output price, adjusted for any caching, batch, or fixed per-call fees.

Why are output tokens more expensive than input tokens?

Generating text requires the model to produce tokens one at a time, which is computationally heavier than reading a prompt in a single pass. Providers reflect that difference in their pricing, typically charging several times more for output.

How much does prompt caching actually save?

It depends on the provider and the model. At launch, one major provider priced cache reads at roughly 10 percent of standard input cost, while another discounted cached input tokens by about 50 percent. Savings only materialize when the cached prefix is large, stable, and repeated often.

Is a smaller model always cheaper per request?

Per call, yes, usually by a wide margin. But cost per successful outcome can flip the answer if the small model fails more often and triggers retries or manual fixes. Measure quality alongside cost before committing to a tier.

When should I use a batch API instead of real-time calls?

Use batch whenever the result is not needed immediately: overnight scoring, bulk classification, embedding generation, or evaluation runs. Batch discounts of roughly 50 percent are common, at the cost of a longer turnaround window.

Do reasoning models cost more per request?

Yes, often substantially. Reasoning models generate internal reasoning traces that are billed as output tokens, so a single request can cost many times a standard chat completion. Reserve them for tasks that genuinely need multi-step reasoning.

Latest articles

Scroll to Top