AI API cost calculator
Enter the size of a request and your volume: the monthly cost is calculated for each OpenAI, Anthropic and Google model, cheapest first.
Your usage
Cost per model
Understanding an AI API bill
- Input and output are billed separately. Output costs three to six times more: a chatty assistant costs more than a long prompt.
- History is paid for again every turn. In a conversation, all previous messages are sent again: the tenth exchange costs far more than the first.
- Caching cuts the price of repeated parts. Identical instructions and documents from one request to the next are billed up to ten times cheaper when re-read.
- Batch processing is half price at OpenAI and Anthropic, for tasks that can wait a few hours.
- Reasoning is billed. The thinking tokens of recent models count as output, even if they are not displayed.
Benchmarks for estimating your tokens
| Content | Size | Tokens (order of magnitude) |
|---|---|---|
| An email | 150 words | 200 |
| A page of text | 500 words | 700 |
| A blog post | 1,500 words | 2 100 |
| A 30-page report | 15,000 words | 21 000 |
| A novel | 90,000 words | 125 000 |
To measure a specific text, use the token counter. Prices change often: check the provider's official page before committing to a budget.
How to use the API cost calculator
Your usage in tokens and requests, priced for each OpenAI, Anthropic and Google model.
-
Describe your usage
Input and output tokens per request, requests per day.
-
Add caching and batches
The share of input reread from cache and deferred processing reduce the bill.
-
Compare
Cost per request and per month, in dollars and euros, cheapest to most expensive.
About the API cost calculator
AI APIs bill per million tokens, separately for input and for output. The gap between models is considerable: for the same usage, the bill can vary by a factor of a hundred between a small fast model and the most powerful one. The calculator makes the gap visible before you write a line of code.
The prices are taken from the three vendors’ official pages and dated. The exchange rate comes from the European Central Bank and can be edited. The calculation does not cover separately billed tools, such as web search, nor the surcharge for very long contexts: take the result as a reliable order of magnitude, not as a quote.
Frequently asked questions about the API cost calculator
How much does the ChatGPT API cost?
It is pay-as-you-go, per million tokens, at a rate that depends on the model. The table gives the input and output price of each GPT model and the cost of your own usage.
What is the difference between a subscription and the API?
A subscription (ChatGPT Plus, Claude Pro, Gemini’s paid plans) is a monthly flat fee for the app. The API is billed by consumption and is used to build a model into software.
How can I reduce my bill?
Choose the smallest model that does the job, limit answer length, cache repeated instructions and use batch processing when the answer can wait.
Are the prices up to date?
The date of the price check is shown under the table, with a link to each official page. Prices change often: verify them before committing a budget.
Is it free?
Yes, with no sign-up and no usage limit.