Tool
AI API cost calculator
Estimate what an AI agent or app costs each month in API tokens, then get a spending cap to set before it runs. Enter your provider’s current price. It runs in your browser and nothing is sent anywhere.
Your estimate
- Estimated monthly cost
- –
- Suggested monthly cap
- –
- Estimated daily cost
- –
- Suggested daily cap
- –
- Cost per call
- –
How the numbers work
| Cost per call | (input tokens × input price + output tokens × output price) ÷ 1,000,000 |
|---|---|
| Daily cost | cost per call × calls per day |
| Monthly cost | daily cost × days per month |
| Suggested cap | cost × (1 + buffer %), rounded up to the cent |
Formulas last checked 26 October 2026. Prices are your inputs; this page lists no vendor prices.
Turn the estimate into real limits
- AI agent spend cap calculator: per-payment, daily and monthly caps when agents also make purchases.
- AI agent spending limits: where to enforce caps so the model can’t talk past them.
- What an AI agent costs: the other costs beyond tokens.
- Fund the session ceiling: why the monthly cap is a backstop, not the live brake.
FAQ
- How do I estimate my monthly AI API cost?
- Multiply calls per day by tokens per call, divide by one million, multiply by your price per million tokens, then multiply by the days you run each month.
- Why are input and output tokens priced separately?
- Many providers charge a different rate for tokens you send (input) and tokens the model writes (output), so enter both prices if your provider lists two.
- What monthly spending cap should I set?
- Set the cap a little above your estimate (the default buffer is 25%) so normal months fit and a runaway loop hits the limit.
- Where do I set the cap?
- Set it in your provider’s billing or usage-limit settings, or in code that counts spend before each call, not in the prompt.
- Does this calculator include any vendor prices?
- No, every price is your own input, so copy the current rate from your provider’s pricing page.
Embed this calculator
Add it to your site with one iframe. It loads one small page with no tracking scripts.