AI API cost calculator
Pick a job, set how many you’ll run a month, and see what it costs on every major AI model from OpenAI, Anthropic, Google, DeepSeek, and xAI, ranked cheapest first.
| Model | Per email | Per month | vs. cheapest |
|---|---|---|---|
| Claude Haiku 5.5Anthropic · fast | $0.00028 | $0.28 | 1× |
| GPT-6 LunaOpenAI · fast | $0.00028 | $0.28 | 1× |
| DeepSeek Flash (V4.1)DeepSeek · fast | $0.00072 | $0.72 | 2.6× |
| Gemini 3.5 Flash-LiteGoogle · fast | $0.0012 | $1.24 | 4.4× |
| Grok 4.3xAI · fast | $0.0020 | $2.00 | 7.1× |
| Gemini 3.8 FlashGoogle · balanced | $0.0021 | $2.10 | 7.5× |
| DeepSeek V4 ProDeepSeek · flagship | $0.0026 | $2.64 | 9.4× |
| Grok 4.7xAI · flagship | $0.0040 | $4.00 | 14× |
| Claude Sonnet 5.5Anthropic · balanced | $0.0056 | $5.60 | 20× |
| GPT-6.1 SolOpenAI · balanced | $0.0056 | $5.60 | 20× |
| Gemini 3.1 Pro (Preview)Google · flagship | $0.0064 | $6.40 | 23× |
| Claude Opus 5.5Anthropic · flagship | $0.0112 | $11.20 | 40× |
| Claude Fable 5.1Anthropic · flagship | $0.0280 | $28.00 | 100× |
| GPT-6 AstraOpenAI · flagship | $0.0280 | $28.00 | 100× |
Published list prices checked October 10, 2026, before tax. Token counts are estimates and vary by provider, since each counts text a little differently. Subscriptions like Claude Pro, ChatGPT Plus, or Google AI Pro (about $20 a month) are for using the chat apps yourself and can’t be called from your own software. Calculated in your browser; nothing is saved.
Based on each provider’s published prices, checked October 10, 2026. How the estimates work.
How AI API pricing works, in one minute
Every major provider charges the same way: per token, a chunk of text roughly three-quarters of a word long. You pay one price for input tokens, everything you send (instructions, documents, the conversation so far), and a higher price for output tokens, what the model writes back. Prices are quoted per million tokens, so “$2 / $10” means $2 per million input tokens and $10 per million output tokens.
A million tokens sounds like a lot, and for most single tasks it is: a typical email draft uses around 1,200 tokens in total. That’s why per-task costs are usually fractions of a cent, and why the bill depends far more on volume and which model you choose than on any single request.
What we found comparing the providers
- OpenAI and Anthropic price-match tier for tier. GPT-6 Astra and Claude Fable 5.1 are both $10 / $50, GPT-6.1 Sol and Claude Sonnet 5.5 are both $2 / $10, and GPT-6 Luna and Claude Haiku 5.5 are both $0.10 / $0.50. The real differences are in caching, long-prompt pricing, and how many tokens each uses for the same text.
- Google is cheapest in the middle and at the top. Gemini 3.8 Flash answers 2,000 support tickets for about $6.38 a month versus $17 on Sonnet 5.5 or GPT-6.1 Sol, and Gemini 3.1 Pro costs a fraction of the other flagships, although Flash’s price is promotional until the end of 2026.
- The budget models are astonishingly cheap. On GPT-6 Luna or Claude Haiku 5.5, $20 covers roughly 71,428 email drafts by our estimates.
- DeepSeek and Grok compete on headline price. DeepSeek halves its prices off-peak, and Grok’s low output price suits writing-heavy work.
- Model choice matters more than provider. Within one provider, the most capable model can cost 100 times as much as the cheapest. Picking the right tier saves far more than switching providers.
Flagship models compared
Each provider’s most capable current model, per million tokens.
| Model | Input | Cached input | Output | Batch in / out |
|---|---|---|---|---|
| Claude Fable 5.1flagship · 1M tokens | $10 | $0.25 | $50 | $5 / $25 |
| Claude Opus 5.5flagship · 1M tokens | $4 | $0.20 | $20 | $2 / $10 |
| GPT-6 Astraflagship · 1.05M tokens | $10 | $1 | $50 | $5 / $25 |
| Gemini 3.1 Pro (Preview)flagship | $2 | $0.20 | $12 | $1 / $6 |
| DeepSeek V4 Proflagship · 1M tokens | $1.32 | $0.044 | $3.96 | — |
| Grok 4.7flagship · 500K tokens | $2 | $0.50 | $6 | — |
Gemini 3.1 Pro and DeepSeek V4 Pro are priced closer to the others’ middle tiers, which is why the top of the market spans from about $1 to $10 per million input tokens.
Everyday and budget models compared
The models most businesses should actually use most of the time, on 1,000 email drafts a month:
| Balanced model | Input / output per 1M | 1,000 emails |
|---|---|---|
| Gemini 3.8 FlashGoogle | $0.75 / $3.75 | $2.1 |
| Claude Sonnet 5.5Anthropic | $2 / $10 | $5.6 |
| GPT-6.1 SolOpenAI | $2 / $10 | $5.6 |
| Fast model | Input / output per 1M | 1,000 emails |
|---|---|---|
| Claude Haiku 5.5Anthropic | $0.10 / $0.50 | $0.28 |
| GPT-6 LunaOpenAI | $0.10 / $0.50 | $0.28 |
| DeepSeek Flash (V4.1)DeepSeek | $0.30 / $1.20 | $0.72 |
| Gemini 3.5 Flash-LiteGoogle | $0.30 / $2.50 | $1.24 |
| Grok 4.3xAI | $1.25 / $2.50 | $2 |
API or subscription?
ChatGPT Plus, Claude Pro, and Google AI Pro each cost about $20 a month, and none of them include API access. They’re for using the chat apps yourself. The API is for putting AI inside your own software: a support bot, a document pipeline, an automation that drafts replies, or a feature in your product. If a person is typing into a chat window, a subscription is usually the simpler, better deal. If software is calling the AI on its own, you need the API, and for most small-business volumes the bill is modest.
Many teams use both: subscriptions for the people doing their own work, and the API for automations. Our guide to Claude’s subscription plans and our Is Claude worth it? calculator cover the subscription side.
How to choose a model without overspending
- Start in the middle. Build with a balanced model like Sonnet 5.5, GPT-6.1 Sol, or Gemini 3.8 Flash.
- Try the budget model on every step. Classification, extraction, and short replies often work just as well on Luna, Haiku, or Flash-Lite at a fraction of the price.
- Reserve flagships for hard steps. Use the top models only where you can see the quality difference.
- Use the discounts. Batch processing halves the price of anything that can wait, and caching makes repeated instructions nearly free.
- Measure real requests. Our estimates are a starting point; your provider’s usage dashboard tells you what your actual prompts cost.
Pricing by provider
- Claude API pricing: every current Anthropic model, discounts, and what common jobs cost.
- OpenAI API pricing: every current OpenAI model, discounts, and what common jobs cost.
- Gemini API pricing: every current Google model, discounts, and what common jobs cost.
- DeepSeek API pricing: every current DeepSeek model, discounts, and what common jobs cost.
- Grok API pricing: every current xAI model, discounts, and what common jobs cost.
Frequently asked questions
Which AI API is the cheapest?
For short, simple tasks, OpenAI’s GPT-6 Luna and Anthropic’s Claude Haiku 5.5 are the cheapest major models at $0.10 per million input tokens and $0.50 per million output tokens. For mid-range work, Google’s Gemini 3.8 Flash is cheapest among the big three, and DeepSeek is cheaper still off-peak. The cheapest model for you is the least expensive one whose results are good enough for the job.
What is a token?
A token is the unit AI providers use to measure text. In English, a token is roughly three-quarters of a word, so 1,000 tokens is about 750 words. You pay separately for input tokens (what you send) and output tokens (what the model writes back), and output usually costs four to five times more.
Is the API cheaper than a ChatGPT, Claude, or Gemini subscription?
They do different jobs. A subscription like ChatGPT Plus, Claude Pro, or Google AI Pro, about $20 a month, is for using the chat app yourself. The API is for building AI into your own software and is billed per use. For automated work like answering tickets or processing documents, the API is the only option and is often very cheap; for one person chatting, a subscription is simpler.
Why do output tokens cost more than input tokens?
Generating text takes much more computing work than reading it, so every provider charges more for output, typically four to five times the input price. That’s why jobs that write a lot, like articles or long answers, cost more than jobs that read a lot and write a little, like summaries.
How accurate is this calculator?
It uses each provider’s published list prices and standard estimates of how many tokens common jobs use. Real costs vary with the length of your prompts, how many tokens each model uses for the same text, caching, retries, and extras like web search. Treat it as a reliable way to compare options, then measure a sample of real requests before you budget.