LLM Pricing Calculator

Calculate the cost of using an LLM, compare providers and pick the right one for your needs.

Cost Calculator

Cost Summary

Input Cost

$0.0020

Output Cost

$0.0080

Total Cost

$0.0100

What You Can Do With $0.0100

Writing

  • 10 - 100 word essays
  • 0 - 0 Harry Potter books (~400 pages each)
  • 120 - 150 tweets

Code

  • 50 - 100 lines of code
  • 0 - 0 full-stack applications

Research & Analysis

  • 0 - 0 research papers analyzed
  • 0 - 1 data analysis reports

Model Comparison

Provider Model Input ($/MTok) Output ($/MTok) Context Window
OpenAIGPT-4.1$2$8-
OpenAIGPT-4.1 Mini$0.4$1.6-
OpenAIGPT-4.1 Nano$0.1$0.4-
OpenAIGPT-4.5 Preview$75$150-
OpenAIGPT-4o$2.5$10-
OpenAIGPT-4o Audio Preview$2.5$10-
OpenAIGPT-4o Realtime Preview$5$20-
OpenAIGPT-4o Mini$0.15$0.6-
OpenAIGPT-4o Mini Audio Preview$0.15$0.6-
OpenAIGPT-4o Mini Realtime Preview$0.6$2.4-
OpenAIO1$15$60-
OpenAIO1 Pro$150$600-
OpenAIO3$10$40-
OpenAIO4 Mini$1.1$4.4-
OpenAIO3 Mini$1.1$4.4-
OpenAIO1 Mini$1.1$4.4-
OpenAIGPT-4o Mini Search Preview$0.15$0.6-
OpenAIGPT-4o Search Preview$2.5$10-
OpenAIComputer Use Preview$3$12-
AnthropicClaude 3.7 Sonnet$3$15200,000 tokens
AnthropicClaude 3.5 Haiku$0.8$4200,000 tokens
AnthropicClaude 3 Opus$15$75200,000 tokens
GeminiGemini 2.5 Pro$1.25$10200,000 tokens
GeminiGemini 2.0 Flash$0.1$0.4-
GeminiGemini 2.0 Flash Lite$0.075$0.3-
GroqLlama 4 Scout (17Bx16E)$0.11$0.34-
GroqLlama 4 Maverick (17Bx128E)$0.2$0.6-
GroqDeepSeek R1 Distill Llama 70B$0.75$0.99-
GroqQwen QwQ 32B (Preview)$0.29$0.39-
GroqMistral Saba 24B$0.79$0.79-
GroqLlama 3.3 70B Versatile$0.59$0.79-
GroqLlama 3.1 8B Instant$0.05$0.08-
GroqLlama 3 70B$0.59$0.79-
GroqLlama 3 8B$0.05$0.08-
GroqGemma 2 9B$0.2$0.2-
GroqLlama Guard 3 8B$0.2$0.2-
GrokGrok-3 Beta$3$15131,072 tokens
GrokGrok-3 Fast Beta$5$25131,072 tokens
GrokGrok-3 Mini Beta$0.3$0.5131,072 tokens
GrokGrok-3 Mini Fast Beta$0.6$4131,072 tokens

The prices are per million tokens. The prices are rounded to the nearest 4 decimal places. We are not affiliated with any of the providers and the prices are not guaranteed to be accurate. These provider might update the pricing at any time without notice. I will try to keep the prices updated as much as possible.

I have pulled the data directly from the providers' websites. OpenAI, Anthropic, Google Gemini, Groq, Grok.

How am I calculating the tokens and cost?

Tokens are the basic units of text that LLMs process. They can be as short as one character or as long as one word. For example:

  • "Hello" = 1 token
  • "Hello world" = 2 tokens
  • "Hello, world!" = 3 tokens (including punctuation)

The cost calculation is straightforward:

  • Input Cost = (Input Tokens ÷ 1,000,000) × Input Price per Million Tokens
  • Output Cost = (Output Tokens ÷ 1,000,000) × Output Price per Million Tokens
  • Total Cost = Input Cost + Output Cost

For example, if you're using GPT-4 with 1,000 input tokens and 500 output tokens:

  • Input Cost = (1,000 ÷ 1,000,000) × $30 = $0.03
  • Output Cost = (500 ÷ 1,000,000) × $60 = $0.03
  • Total Cost = $0.06

For more detailed information about tokens, you can refer to OpenAI's token guide.

If you find any discrepancies, please DM me on X or Telegram.