Serverless vs dedicated inference
Serverless vs dedicated inference compared: pay-per-use shared capacity versus reserved hardware for one model, and how to choose based on your traffic.
Updated
Serverless inference is a shared endpoint you pay for per use, usually per token or per call. Dedicated inference reserves capacity for one model, and you pay for that capacity whether or not requests arrive. Neither option changes what the model answers. They differ in how you are billed, who controls the queue, and how predictable the speed is.
How each option works
With serverless inference, the provider runs the model on hardware shared by many customers. You do not manage a server. Billing follows use, so a quiet night costs close to nothing.
The tradeoff is control. The provider decides how shared capacity is divided, so your requests can wait during busy periods. A model that has been idle can take longer on its first call while it is loaded again.
With dedicated inference, capacity is reserved for your model and no other customer’s traffic runs on it. The bill is the same in a quiet week and a busy one. You also choose the model version and set the limits yourself, so a result you measured this month can be reproduced next month.
Worked example: counting the monthly volume
Take one task and write down three numbers: calls per month, average input tokens per call, and average output tokens per call. Suppose an illustrative workload of 20,000 calls a month, averaging 3,000 input tokens and 300 output tokens each. That is 60 million input tokens and 6 million output tokens, or 66 million tokens in total.
Price that volume at the per-token rate in the serverless quote. Then price the smallest dedicated setup that handles your busiest hour, not your average hour, and add headroom. Put both monthly totals side by side. If you want to run the arithmetic with your own rates, the LLM cost calculator does it in a few fields.
Sizing is where most estimates go wrong. Capacity sized for the average hour builds queues at lunchtime. Capacity sized for the peak sits partly idle overnight. Pull the busiest hour from your logs and count the calls that arrive in it. Dividing a daily total by 24 hides the spikes that cause the trouble.
When serverless fits
Serverless suits work that arrives in bursts with long quiet gaps. Consider a legal team that reviews incoming vendor agreements on weekday mornings only. Reserved hardware would sit unused for most of each week, so a per-use bill is the better match.
It also suits early testing. Before you commit to any server, you need to know whether a model can pull the fields you care about from each document: party names, effective dates, termination notice periods and governing law. A shared endpoint lets you try several models by changing the model name in each request, and you do not commit to infrastructure until the answers are clear.
Serverless is the right call when nobody on the team runs model infrastructure. A per-use rate asks for less operational work than keeping a reserved setup patched and monitored.
When dedicated capacity fits
Dedicated capacity fits steady work. A pipeline that pulls new invoices from a shared inbox every hour and extracts line items, or a system that routes every incoming support ticket within seconds, keeps reserved capacity busy around the clock. The fixed cost then spreads across many calls, and the cost per call falls as volume rises.
Speed is the second reason. On a shared queue, wait times can change from one hour to the next. Reserved capacity is yours, so you can size it against the throughput you need and plan deadlines around it.
Data rules are the third. A model that runs inside your own cloud account or your own building operates under controls you set, and you decide who can reach the prompts and outputs. A shared endpoint can be fine for many workloads, but read its data terms before you send sensitive records there.
Mistakes that skew the decision
- Comparing a per-token rate with an hourly hardware rate without converting one into the other using your real token counts.
- Assuming dedicated is always cheaper. Reserved hardware costs the same when nothing runs, so an underused endpoint can cost more than the serverless bill it replaced.
- Sizing for the average hour, then blaming the model for queue delays that come from undersized capacity.
- Timing only the first call. A cold start on an idle model inflates the first answer, so time the second and later calls too.
- Choosing on price alone. Two setups with the same monthly cost can give different speeds and different data exposure.
Before you choose, confirm four things. You have the monthly call count and the average input and output tokens per call. You have the load for the busiest hour from real logs. You have the serverless rate in writing, with the terms that apply to it. You have run your own documents through both setups and compared the answers.
How Own Weights handles this
We fine-tune an open-weight model for one high-volume task that you currently send to a frontier API. We test it against your current model on your own data, and it has to beat that model on the test before we deploy it. We serve it in your cloud account or on-prem, so the capacity runs in your environment under your own controls. You own the weights, so the model you run stays with you if you change providers.
Where a model runs does not change its answers, so judge the deployment choice on cost, speed and data rules. Measured accuracy for our fine-tuned models is in full results.
If you run one steady task through an API today, the quickest way to see which side of the line you are on is the free AI cost audit. It maps your AI spend by task from your code and invoices. Use the “Book a free audit” button below to talk through your volume, or read what an AI cost audit finds in your code first. For the broader cost picture, see the cheapest way to run LLM inference at scale. You can also start at Own Weights.
Questions
Is serverless inference cheaper than dedicated inference?
It depends on how much traffic you send and how steady it is. Serverless usually costs less for low or uneven traffic, since you pay only for the calls that run. Reserved capacity tends to win when a steady workload keeps the hardware busy for most of the day.
Why is my serverless endpoint slow on the first request?
A model that has been idle can take time to load before it returns its first answer. Shared queues can add wait time when many customers send traffic at the same moment. Measure the second and later calls to see how much of the delay is the load step.
Do I need dedicated inference if my data is sensitive?
Not always, but a model in your own cloud account or building gives you the most control over where prompts and outputs go. Read your provider's data terms before you send sensitive records to any shared endpoint. This is a technical choice, not legal advice.