How pricing works
How each request is metered and priced, how cached tokens are billed, and how to estimate your cost.
Prices
Every model in the catalogue has a list price in US dollars, shown on the Models
page and returned by GET /v1/models. Each type of model is priced in its own unit:
| Model type | Priced per |
|---|---|
| Chat | 1M input tokens and 1M output tokens, each at its own price |
| Embeddings | 1M input tokens |
| Speech to text | Second of audio (shown per minute on the Models page) |
| Text to speech | Character of input text (shown per 1M characters) |
| Image | Generated image |
| Video | Second of generated video |
How a request is metered
- From the reported usage, never estimated. Each request is metered from the
usagethe model reports for it: the tokens (or characters, seconds or images) it actually used. - Priced at nano-USD precision. The usage is priced at the model's catalogue price, to a billionth of a US dollar.
- Visible on every response. The
usageblock of each response shows what was metered for that request; the console's Analytics page breaks your usage and cost down per model and per key.
How the cost is settled (against a prepaid credit balance, with a reservation held while the request runs, or against a postpaid budget) and the errors you get when funds or a budget run out are described in Billing.
Cached tokens
Some chat models publish a cheaper cached input price. It applies to the input tokens the model reports as read from its prompt cache, such as a long system prompt repeated across requests. Those tokens are billed at the cached input price; the rest of the input is billed at the input price. A model with no cached input price bills every input token at its input price. Cached tokens are reported, never estimated: see Cached tokens.
Estimate your cost
The token calculator turns a use case and its traffic, or your own tokens per request, into monthly tokens and cost at the current list prices:
cost = (input tokens × input price + output tokens × output price) ÷ 1,000,000with both prices per 1M tokens.
Deprecated models
A deprecated model still works, at its listed price, until its sunset date, which the Models page shows next to it. After that date it is no longer listed or served. See Models & Aliases for the lifecycle.