- Free
- No signup
- Claude, GPT and Gemini
- Copyable comparison
AI Token Cost Calculator
Paste a prompt or type your token counts, pick the models, and see what each request costs, per 1,000 requests and per month, split into input, cached input and output. Prices come from Anthropic, OpenAI and Google's own pricing pages, checked October 15, 2026.
Your request
Counted at about 4 characters per token, an estimate. Or type the count below.
Exact counts are in your API's usage data.
Include reasoning or thinking tokens; they are billed as output.
Caching and volume
The part of each prompt that repeats and is served from the cache.
A month here is 30 days.
Models to compare
What it costs
Claude Sonnet 5.5, per month
$270.00
$0.009 per request · $9.00 per 1,000 requests · 30,000 requests in 30 days
- Input
- $120.00
- Cached input
- $0
- Output
- $150.00
Side by side, cheapest first
Tap a model to see its split.
Price the product, not just the prompt
Token costs decide whether an AI product makes money. AI SaaS Builder, included in All Access, covers building, pricing and shipping small AI products, including caching and model choice. Start with the free Starter Kit: working files from the programs that open in your browser.
How the cost is worked out
Per request = (input × (1 − cached share) × input price
+ input × cached share × cache-hit price
+ output × output price) ÷ 1,000,000
Per 1,000 = per request × 1,000
Per month = per request × requests per day × 30
Tokens from text ≈ characters ÷ 4 (estimate)Example: 6,000 input and 800 output tokens on Claude Sonnet 5.5 at $2 and $10 per million cost $0.012 + $0.008 = $0.02 a request, or $20 per 1,000 requests. With 70% of the input served from the cache at $0.10 per million, the same request costs about $0.012.
Prices checked October 15, 2026
Standard-tier prices from Anthropic's pricing, OpenAI's pricing and Gemini API pricing. Where a provider charges more for long prompts, the calculator switches to that price once a request's input passes the line: Claude Haiku 5.5 above 100,000 tokens, OpenAI GPT-6 models above 272K, Gemini 3.1 Pro Preview above 200K. Gemini 3.8 Flash is at $0.75 / $3.75 through December 31, 2026, and $1.50 / $7.50 from January 1, 2027.
Counting tokens from text
OpenAI's key concepts page (checked October 15, 2026) gives the rule of thumb that 1 token is about 4 characters or 0.75 words of English. That is what the paste boxes use, so their count is an estimate: code, numbers and other languages usually take more tokens, and Claude and Gemini tokenize differently from GPT. For exact numbers, read the token counts your API returns with each response.
Not included: cache-write charges, batch and priority tiers, regional or data-residency uplifts, server-side tool fees, taxes, and retried or failed requests.
Questions
How do I calculate the cost of AI API tokens?
Multiply each kind of token by its price and add them up: input tokens times the input price, cached input tokens times the cache-hit price, and output tokens times the output price, with prices quoted per 1 million tokens. Then multiply by how many requests you make. This calculator does that for several models at once.
How many tokens is my text?
For English, OpenAI gives a rule of thumb of about 4 characters, or 0.75 words, per token, so 100 tokens is roughly 75 words. Code, numbers and other languages usually take more tokens, and Claude, GPT and Gemini each use their own tokenizer, so treat a count from pasted text as an estimate and use the token counts in your API usage data for exact figures.
How much does the OpenAI API cost?
On OpenAI's pricing page, checked October 15, 2026, GPT-6 Luna costs $0.10 per million input tokens and $0.50 per million output tokens, GPT-6.1 Sol $2 and $10, and GPT-6 Astra $10 and $50, at the standard tier. Requests with more than 272K input tokens cost more. What a request costs depends on how many tokens it uses, which is what this calculator works out.
How much does the Claude API cost per token?
On Anthropic's pricing page, checked October 15, 2026, Claude Haiku 5.5 costs $0.10 per million input tokens and $0.50 per million output tokens (for prompts up to 100,000 tokens), Sonnet 5.5 $2 and $10, Opus 5.5 $4 and $20, and Fable 5.1 $10 and $50. One million tokens is about 4 million characters of English, so a single request usually costs a fraction of a cent.
What are cached input tokens?
When the start of a prompt repeats from one request to the next (a long system prompt, a document, tool definitions), providers can serve that part from a cache at a much lower price. Claude Sonnet 5.5 charges $0.10 per million cache-hit tokens against $2 for fresh input. Set the cached share to the part of your input that repeats.
Why do output tokens cost more than input?
Generating text is more work for the model than reading it, so every model listed here charges five to about eight times more per output token. Long answers, and reasoning or thinking tokens, which are billed as output, can make output the biggest part of the bill even when the prompt is much longer.
Is this exact?
The prices are, as of the date checked. The token count from pasted text is an estimate, and the calculator leaves out cache-write charges, batch discounts, regional pricing, taxes and failed or retried requests. Use it to compare models and size a budget, then check your provider's usage dashboard.
Want the whole scenario?
The All Access tools take this job further. Open one to see what it does.