Dev Runs in your browser

Token Calculator

Calculate text tokens and estimate LLM API costs across models and monthly volume.

0 characters · ~0 tokens

Project monthly cost

Standard prices per 1M tokens from Anthropic, OpenAI, Google, checked October 6, 2026. * Gemini 3.1 Pro Preview: prompts up to 200k tokens; Gemini 3.8 Flash: introductory price through Dec 31, 2026, then doubles.

How to estimate LLM API costs

What drives the bill

Cost is input tokens times the input price plus output tokens times the output price, for every request. Input includes system instructions, conversation history, and any retrieved documents, so it is usually far larger than what the user typed.

Output costs more

Every current model charges more per output token than per input token, often four to six times more. Long answers and reasoning add up faster than long prompts.

Check prices before you commit

Providers change prices and add models often. The presets here come from each provider's pricing page on the date shown; confirm on the provider's page before budgeting.

FAQ

Are tokens the same as words?

No. Tokens are pieces of text. English text averages around four characters per token, but it varies by language and model.

How accurate is the token count?

It's an estimate at about four characters per token. For exact counts, use the provider's token counting API for your model.

Do these prices include caching or batch discounts?

No. They're standard per million token prices. Prompt caching and batch processing can lower the real cost a lot.

Rather skip the token math? usedocs is one plan at $99/mo with 2,000 AI conversations a month.

AI support cost calculator

Try it on your own docs.
Decide in 7 days.

Start a free trial of Growth with no credit card. Import your docs, connect GitHub, and see which articles disagree with your code.

Questions first? Email hello@usedocs.app or ask the chat bubble.