Toolstia / AI API cost calculator
AI API cost calculator
Enter the tokens in each request, the price per million tokens from your provider and how many requests you expect. The calculator shows the cost per request, per 1,000 requests and in total.
Enter the prices from your provider’s pricing page, which change often, so no prices are built in. Use any currency. Discounts for cached input or batch jobs are not included.
How it works
- Enter input and output tokens per request.
- Enter the input and output price per million tokens.
- Enter the number of requests and read the cost.
The formula
Cost is tokens divided by one million, multiplied by the price per million, for input and output separately. The two parts are added together.
Why you enter the prices
Prices change often and differ between models, so none are built in. Copy them from your provider’s pricing page and the result will be right for your plan.
Output usually costs more
Most providers charge more for output tokens than for input tokens, so long answers add up fast.
Planning a budget
Multiply by your expected number of daily or monthly requests to see a realistic budget before you build.
Questions
Does it include cached or batch discounts?
No. Enter an average price if you get a discount.
Can I use any currency?
Yes. Enter prices in your own currency and the results use the same one.
Is my data stored?
Everything happens in your browser, and nothing you paste is sent anywhere.