FREE · No Sign-up
Free Tool · AI Text Tools

AI API Cost Calculator

Compare the cost of OpenAI, Claude, Gemini, Grok and DeepSeek APIs for your token volumes.

Compare what the same workload costs on OpenAI, Anthropic Claude, Google Gemini, xAI Grok and DeepSeek. Enter tokens per request and requests per day; the table sorts every model from cheapest to most expensive, with prices checked against each provider’s official pricing page.

ModelProvider$ / 1M input$ / 1M cached input$ / 1M outputNotes
gpt-6-astraOpenAI$5.0$0.5$25.0prompts under 270K tokens
gpt-6.1-solOpenAI$1.0$0.05$5.0prompts under 270K tokens
gpt-6-lunaOpenAI$0.05$0.005$0.25prompts under 270K tokens
gpt-5.3-codexOpenAI$1.75$0.175$14.0
Claude Fable 5.1Anthropic$10.0$0.25$50.0cache read price shown
Claude Opus 5.5Anthropic$4.0$0.2$20.0cache read price shown
Claude Sonnet 5.5Anthropic$2.0$0.2$10.0cache read price shown
Claude Haiku 4.5Anthropic$1.0$0.1$5.0cache read price shown
gemini-3.1-pro-previewGoogle$2.0$0.2$12.0prompts up to 200K tokens
gemini-3.5-flashGoogle$1.5$0.15$9.0
gemini-3.8-flashGoogle$0.75$0.075$3.75price until 31 Dec 2026
gemini-3.1-flash-liteGoogle$0.25$0.025$1.5
grok-4.7xAI$2.0$0.5$6.0prompts under 200K tokens
grok-4.3xAI$1.25$0.2$2.5prompts under 200K tokens
deepseek-v4-proDeepSeek$1.32$0.044$3.96peak hours; off-peak half price
deepseek-flashDeepSeek$0.3$0.006$1.2peak hours; off-peak half price

Prices checked 2026-10-03 from each provider’s official pricing page (standard tier, text tokens). USD per 1 million tokens, standard (non-batch) tier, text, shortest-context price tier. Copied from each provider's official pricing page on the checked date. Prices change often - always confirm on the provider's page. 1 token ≈ ¾ of an English word; count your prompt exactly with the LLM token counter.

How It Works

Using AI API Cost Calculator

1

Enter tokens per request

Input (prompt) and output (response) tokens. Count a real prompt with the LLM token counter.

2

Add caching and volume

The share of input served from a prompt cache, and requests per day.

3

Compare

Cost per request, per day and per 30 days for every model, cheapest first.

Why Use This Tool

What you get with AI API Cost Calculator

Prices from official provider pages with the date they were checked

Includes cached-input pricing

Filter by provider

Runs in your browser

Works Great With

LLM Token Counter (GPT, Claude, Gemini)

Measure the real token count of your prompts before estimating cost.

Try LLM Token Counter (GPT, Claude, Gemini) →
FAQ

AI API Cost Calculator questions

Generating each output token requires a full pass through the model, while input tokens are processed together, so providers charge several times more for output.

If many requests share the same long prefix (instructions, documents), providers can cache it and bill those input tokens at a large discount. Set the cached share to see the effect.

They were copied from the official pricing pages on the date shown under the table. Providers change prices and add tiers (long-context, batch, regional) often, so confirm on their page before budgeting.

Most providers offer about 50 % off for asynchronous batch requests. This calculator uses standard real-time prices.

More from GrowLytics

Free tools for your site — and for you

More Free Tools

Other tools you can try free