Skip to content

AI Token Cost Calculator – Compare LLM API Pricing & Token Budgets

Estimate prompt and completion token costs across 50+ LLMs including GPT-4o, Claude 3.5 Sonnet, Gemini 1.5 Pro, and DeepSeek. 100% free and client-side.

100% Client-Side Privacy: All calculations, text transformations, and file operations run locally in your browser. No files or personal inputs are uploaded to external servers.

Tool controls

Drop file to count tokens (.txt, .md, .py, .js, .json, .csv)
Estimated Tokens
118
Words
81
Characters
497
Lines
10
+0 tokens
500 tokens
50 (One liner) 500 (Summary) 2,000 (Article) 8k (Long Code)
50% - 90% Off Input

Models supporting KV prompt caching (Claude 3.5, GPT-4o, DeepSeek) apply massive discounts when prompts exceed cache thresholds (typically 1,024+ tokens).

1 Request
Total Input Tokens
118
Prompt + System Overhead
Expected Output
500
Estimated completion length
Cheapest Provider
$0.00016
Gemini 1.5 Flash
Flagship Benchmark (GPT-4o)
$0.00530
Input: $2.50/M | Out: $10/M

Multi-Model Real-Time API Cost Matrix

Live Pricing Synced

Pricing per million tokens based on current live rates. Ranked from lowest to highest total query cost.

Live Models
Model & Provider Input Rate / 1M Output Rate / 1M Input Cost Output Cost Total Cost
* Rates verified against OpenAI, Anthropic, Google Cloud, and DeepSeek official API documentation. 1 Token ≈ 4 characters / 0.75 English words

Informational & Educational Disclaimer

This tool is designed for informational and educational estimation purposes only. Calculations are based on user-provided inputs and standard mathematical formulas. For official tax, legal, or financial decisions, please consult certified professionals or official government publications.