AI API Cost Calculator
Compare OpenAI, Claude, and Gemini API costs per request or per month. Enter token counts or paste text for a rough estimate. No account or API key is required.
Cost comparison
Standard text API rates in USD
Estimates only. Actual charges may differ. Before budgeting, verify the current API rates on the provider’s website using the official pricing links below.
- Per request
- Per 1,000
- Per month
OpenAI, Claude, and Gemini API pricing
USD per million tokens on paid, standard synchronous text APIs. Rates checked . Each model links to its provider’s price list.
| Model and rate tier | Input | Cache read | Output |
|---|---|---|---|
| GPT-6.2 AstraOpenAI · Up to 272,000 input tokens | $8.00 | $0.40 | $40.00 |
| GPT-6.2 AstraOpenAI · Above 272,000 input tokens | $16.00 | $0.80 | $60.00 |
| GPT-6.2 SolOpenAI · Up to 272,000 input tokens | $2.00 | $0.10 | $10.00 |
| GPT-6.2 SolOpenAI · Above 272,000 input tokens | $4.00 | $0.20 | $15.00 |
| GPT-6.1 TerraOpenAI · Up to 272,000 input tokens | $1.00 | $0.05 | $5.00 |
| GPT-6.1 TerraOpenAI · Above 272,000 input tokens | $2.00 | $0.10 | $7.50 |
| Claude Opus 5.5Anthropic · Standard | $4.00 | $0.20 | $20.00 |
| Claude Sonnet 5.5Anthropic · Standard | $2.00 | $0.10 | $10.00 |
| Claude Haiku 5.5Anthropic · Up to 100,000 input tokens | $0.10 | $0.01 | $0.50 |
| Claude Haiku 5.5Anthropic · Above 100,000 input tokens | $0.50 | $0.05 | $2.50 |
| Gemini 4 NeonGoogle · Standard | $3.00 | $0.15 | $15.00 |
| Gemini 4 HydrogenGoogle · Standard | $1.50 | $0.075 | $7.50 |
How to calculate AI API cost
Per request, multiply each token count by its price per million and divide by one million. Add the uncached input, cache-read input, and output charges. Multiply that sum by your monthly request count. The long-context price tier is based on each request’s total input.
Example using Gemini 4 Neon
2,000 uncached input tokens at $3.00 per million cost $0.006. 500 output tokens at $15.00 per million cost $0.0075. That’s $0.0135 per request or $135.00 per month for 10,000 equal requests.
What the estimate includes
This compares standard text-token usage on the selected models. It prices cache reads once they meet the model’s minimum. Cache-write surcharges, cache storage, tool calls, images or audio, optional processing tiers, discounts, and taxes are separate.
Why can the token count differ from my bill?
Pasted text uses a rough estimate shared across models. Tokenizers split the same text differently. API requests can add system instructions, conversation history, tools, and billed reasoning. For a budget based on real traffic, enter the input, cached input, and output counts reported by the provider for representative requests.
Which token counts should I enter for Claude?
Claude reports uncached input, cache reads, and cache creation separately. For total input, add input_tokens, cache_read_input_tokens, and cache_creation_input_tokens. Enter cache_read_input_tokens in the cached input field. The calculator prices cache creation tokens at the ordinary input rate. Add any write surcharge separately. Claude API cache usage fields.
Does this calculate the price of a ChatGPT, Claude, or Gemini subscription?
The calculator estimates metered API usage. Consumer plan fees, included credits, and provider-specific allowances depend on the plan.