Direct Answer

Total API Cost = (Input Tokens ÷ 1,000,000 × Input Rate) + (Output Tokens ÷ 1,000,000 × Output Rate). For example, 2,000 input + 500 output tokens on GPT-4o ($2.50 / $10.00 per 1M) costs $0.0100 per call ($10.00 per 1,000 calls, or $300/month at 1,000 daily requests), whereas GPT-4o mini / Gemini 2.5 Flash ($0.15 / $0.60) costs just $0.00060 per call ($18/month).

$
$
Used to project daily and 30-day monthly LLM API spend.
Paste text above to auto-calculate input tokens (1 token ≈ 4 characters / 0.75 words).
Transparent Token Pricing Formula

Total API Cost = (Input Tokens ÷ 1,000,000 × Input Price) + (Output Tokens ÷ 1,000,000 × Output Price)

Projected 30-Day Monthly API Cost
$300.00
GPT-4o | 2,500 total tokens/call × 30,000 monthly requests
Cost per API Call
$0.0100
Cost per 1,000 Calls
$10.00
Daily API Cost
$10.00
Tokens per Call (In + Out)
2,500
  • Input Cost per Call (2,000 tokens)$0.00500
  • Output Cost per Call (500 tokens)$0.00500
  • Monthly Input Volume60.00M tokens
  • Monthly Output Volume15.00M tokens
  • Monthly Input Cost (30 days)$150.00
  • Monthly Output Cost (30 days)$150.00
  • Projected 30-Day Monthly Cost$300.00

Popular LLM API Pricing Comparison (Per 1M Tokens)

AI Model Input ($/1M) Output ($/1M) 1M Combined (50/50) Best Use Case
GPT-4o (OpenAI) $2.50 $10.00 $6.25 Flagship multimodal chat, coding & structured JSON
GPT-4o mini (OpenAI) $0.15 $0.60 $0.375 High-volume classification, summaries & support bots
o3-mini (OpenAI) $1.10 $4.40 $2.75 Fast STEM reasoning, math & algorithmic code
Claude 3.7 Sonnet (Anthropic) $3.00 $15.00 $9.00 Complex software engineering, writing & agent workflows
Claude 3.5 Haiku (Anthropic) $0.80 $4.00 $2.40 Low-latency interactive UI & data extraction
Gemini 2.5 Pro (Google) $1.25 $10.00 $5.625 Long-context codebase analysis & deep reasoning
Gemini 2.5 Flash (Google) $0.15 $0.60 $0.375 Ultra-low-cost multimodal pipelines at scale

How LLM API Token Pricing & Budgeting Works

Every major AI API provider—including OpenAI, Anthropic, and Google—bills usage per 1 million tokens, separating input tokens (your system prompt, conversation history, RAG documents, and user query) from output tokens (the completion generated by the model). As a quick rule of thumb in English, 1 token equals roughly 4 characters or 0.75 words, meaning 1,000 tokens is approximately 750 words.

Output tokens almost always carry a 3× to 8× price multiplier compared to input tokens. If your application sends a 2,000-token system prompt and receives a 500-token answer on GPT-4o ($2.50 input / $10.00 output), half of your entire API bill comes from the shorter 500-token completion. Keeping responses concise, enforcing structured JSON schemas, and setting tight max_tokens caps directly protects your unit economics.

For production SaaS apps, model routing produces the biggest savings: handling routine extraction, tagging, or FAQ queries with GPT-4o mini or Gemini 2.5 Flash ($0.15 / $0.60 per 1M) cuts spend by over 90% compared to frontier models, reserving GPT-4o, Claude 3.7 Sonnet, or Gemini 2.5 Pro for complex reasoning steps.

Frequently Asked Questions

How much is 1M OpenAI tokens?

On GPT-4o, 1 million input tokens cost $2.50 and 1 million output tokens cost $10.00 ($6.25 for a 50/50 split). On GPT-4o mini, 1 million input tokens cost $0.15 and 1 million output tokens cost $0.60, while o3-mini costs $1.10 per 1M input tokens and $4.40 per 1M output tokens.

How much is 1,000 tokens in AI models?

1,000 tokens is roughly 750 English words or 4,000 characters. On GPT-4o, 1,000 input tokens cost $0.0025 and 1,000 output tokens cost $0.01; on GPT-4o mini or Gemini 2.5 Flash, 1,000 input tokens cost just $0.00015 and 1,000 output tokens cost $0.0006.

How are tokens calculated from English words and characters?

Most modern byte-pair encoding (BPE) tokenizers split standard English text at roughly 4 characters per token, or about 0.75 words per token (100 tokens ≈ 75 words). Code, JSON formatting, and non-English scripts typically consume slightly more tokens per character.

Why do output tokens cost more than input tokens in LLM APIs?

Input prompts are processed in parallel during a single prefill pass on GPU clusters, whereas output tokens must be generated sequentially one token at a time while keeping the KV-cache in high-bandwidth GPU memory—making output tokens 3× to 8× more compute-intensive to serve.

How can developers reduce monthly OpenAI, Claude, and Gemini API costs?

Route classification, extraction, and simple chat turns to fast models like GPT-4o mini, Gemini 2.5 Flash, or Claude 3.5 Haiku; enable prompt caching for repeated system instructions; cap max_tokens on completions; and use Batch APIs for non-urgent workloads.