Loading...
Loading...
Paste your prompt, estimate tokens, and compare API costs across 18 models from OpenAI, Anthropic, Google, DeepSeek, and Meta.
Pricing verified as of March 2026 from official provider pages.
Output tokens set to match input estimate (0 tokens).
| Model | Provider | Context | Total Cost |
|---|---|---|---|
| GPT-4o | OpenAI | 128K | $0.00 |
| GPT-4o Mini | OpenAI | 128K | $0.00 |
| GPT-4.1 | OpenAI | 1.0M | $0.00 |
| GPT-4.1 Mini | OpenAI | 1.0M | $0.00 |
| GPT-4.1 Nano | OpenAI | 1.0M | $0.00 |
| o3Reasoning | OpenAI | 200K | $0.00 |
| o3-miniReasoning | OpenAI | 200K | $0.00 |
| o4-miniReasoning | OpenAI | 200K | $0.00 |
| Claude Opus 4.6 | Anthropic | 200K | $0.00 |
| Claude Sonnet 4.6 | Anthropic | 200K | $0.00 |
| Claude Haiku 4.5 | Anthropic | 200K | $0.00 |
| Gemini 2.5 Pro | 1.0M | $0.00 | |
| Gemini 2.5 Flash | 1.0M | $0.00 | |
| DeepSeek V3.2 | DeepSeek | 164K | $0.00 |
| DeepSeek ReasonerReasoning (V3.2) | DeepSeek | 164K | $0.00 |
| Llama 4 ScoutOpen source | Meta (Groq) | 128K | $0.00 |
| Llama 4 MaverickOpen source | Meta (Groq) | 128K | $0.00 |
Tokens are not words. LLMs process text as tokens, which are subword units that may be full words, word fragments, or individual characters.
On average, 1 token ≈ 4 characters or ≈ 0.75 words in English. Code and non-English text tend to use more tokens.
Different tokenizers: OpenAI uses tiktoken (BPE), Anthropic and Google use their own proprietary tokenizers. Token counts can vary ~10-15% between models for the same text.
1. Be concise: remove filler words and redundancy from prompts.
2. Use system prompts wisely: they count as input tokens on every API call.
3. Set max_tokens: cap output length in API calls to control costs.
4. Use cheaper models for simple tasks (GPT-4o Mini, Haiku, Flash).
5. Batch API: most providers offer 50% savings for async processing.
6. Prompt caching: reuse cached prompts for 50-90% input savings.
Pricing last updated: March 2026. Prices may change - always verify with official provider pricing pages before production use.