What it is
There are two ways to run a trained model. Serverless (also called per-token or on-demand) runs it on capacity the provider shares between many customers: you send requests and pay for the tokens in and out, and when you send nothing you pay nothing. A dedicated deployment reserves hardware for your model alone: it is always loaded and ready, and you pay for every hour it exists.
| Serverless | Dedicated | |
|---|---|---|
| Billed by | Input and output tokens | Hours the deployment exists |
| Idle cost | None | Full hourly price |
| Start-up | Usually immediate | A cold start of minutes when created |
| Capacity | Shared; subject to rate limits | Reserved; predictable throughput |
| Availability | Only for models the provider supports this way | Most trained models, including open models |
How the costs compare
serverless cost per day = tokens per day × price per token
dedicated cost per day = 24 × hourly price (used or not)
break-even tokens/day = 24 × hourly price ÷ price per tokenThe intuition: with a dedicated deployment, the cost per token is the hourly price divided by how many tokens you actually push through it in that hour. At full load that can be cheaper than serverless. At low load it is far more expensive, and an idle hour has an infinite cost per token. Serverless has the opposite shape: the price per token is fixed, so cost tracks use exactly.
Why isn't everything serverless? Shared serving works by keeping a base model loaded for many customers. Some providers can attach a small fine-tuned adapter to that shared model per request, which makes per-token serving possible for tuned models. Others need the whole tuned model loaded on its own hardware — common for open models and for full fine-tunes — and then dedicated is the only option. Some providers go further and require reserved capacity for any customised model.
- Assume (illustrative, not real quotes) serverless at $0.60 per million tokens and a dedicated deployment at $5 per hour, i.e. $120 per day.
- Break-even: $120 ÷ $0.60 per million = 200 million tokens per day.
- A day of testing: 300 questions × 1,500 tokens = 450,000 tokens. Serverless: about $0.27. Dedicated: $120 for the day, or $10 if you delete it after two hours.
- A busy internal assistant: 50 million tokens a day. Serverless: $30. Dedicated: still $120.
- A high-volume product: 500 million tokens a day. Serverless: $300. Dedicated: $120, if one deployment can handle the load.
How to choose
- Use serverless when it is available and usage is low, uncertain or bursty — testing, evaluation, pilots.
- Use dedicated when the model can only be served that way, when steady traffic is above break-even, or when you need guaranteed capacity and latency.
- Always set an end time on a dedicated deployment used for testing, and delete it when done. Commitments of weeks or months may lower the hourly price but remove that option.
Common mistakes
- Forgetting a dedicated test deployment and paying for days of idle hours.
- Comparing a dedicated hourly price with a serverless per-token price without converting through expected usage.
- Assuming a tuned model can be served per token because its base model can.
- Signing a long capacity commitment for a model that is still being iterated on.
References and further reading
External sources open in a new tab.
- 01Increase model invocation capacity with Provisioned Throughput in Amazon BedrockAmazon Bedrock User Guide · docs.aws.amazon.comA real example of reserved capacity: billed hourly until deleted, with optional commitments.
- 02Inference EndpointsHugging Face docs · huggingface.coDedicated endpoints for open models, with autoscaling.
- 03Serverless computingWikipedia · en.wikipedia.orgThe general model of paying per use, and its trade-offs such as cold starts.