Count tokens and price a prompt before you send it.

Paste a prompt or a document to see roughly how many tokens it is, how much of a context window it fills and what it costs to send at scale, for GPT, Claude, Gemini or any model you add. Counted in your browser. Nothing is sent anywhere.

  • Free, no sign-up
  • Counted in your browser
  • GPT, Claude and Gemini
0 characters
Estimated tokens0Paste some text to count it.

How much of a context window it fills

What it costs to send

Enter the reply length and how often you send it. Edit any price: providers change them often.

Caching and batch pricing
ModelInput $ / 1MOutput $ / 1MWindow (K)Per requestPer monthCompare

Standard list prices checked on 7 October 2026, for prompts under 200K tokens. They go out of date: check the provider’s pricing page and change any number above. Token counts are estimates and can differ from a provider’s own count by 10 to 15 percent.

How to count tokens and estimate API cost

  1. Paste your prompt

    Paste or open the text you will send. The estimate updates as you type.

  2. Set the reply and the volume

    Enter how long the reply will be and how many requests you send each month.

  3. Compare the models

    Read the cost per request and per month for each model. Change any price to match the provider’s page, or add a model of your own.

Language models read and bill text in tokens: pieces of words, numbers and symbols. A short English word is usually one token, a long word several, and code, numbers and non-English text use more per word. Knowing the token count tells you whether a prompt fits in a model’s context window and what it will cost you at scale. This page estimates both in your browser, without sending your text anywhere.

What it does

  • Estimates the token count of any text and shows how it splits between words, symbols and code, numbers and non-Latin text.
  • Shows how much of an 8K, 32K, 128K, 200K and 1M context window the prompt fills.
  • Works out the cost per request and per month from your reply length and request volume, for several models side by side.
  • Lets you edit every price, add your own models and keep them in your browser for next time.
  • Handles prompt caching and the batch discount, which can cut the bill a lot for repeated prompts.
  • Opens text, Markdown, JSON, CSV and code files on your device.

Limits, honestly

  • The count is an estimate, usually within 10 to 15 percent. Each provider’s tokenizer is different, and their vocabularies are too large to run in a web page. For an exact count use the provider’s own tokenizer or token-counting API.
  • The prices were checked on 7 October 2026. Providers change them often and add models: check the pricing page and edit the numbers.
  • It counts text only. Images, audio and files sent as attachments are priced differently by each provider.
  • Hidden costs are not included: reasoning tokens some models spend before answering, tool calls and retries.
  • Context windows listed are common sizes. A model’s real limit and its rules for output length are on its documentation page.

LLM Token Counter & API Cost Calculator: questions and answers

What is a token in an LLM?

A token is the unit a language model reads and writes: a piece of a word, a whole short word, a number or a symbol. In English, 1,000 tokens is roughly 750 words. Models bill by the token and limit each request to a context window measured in tokens.

How accurate is this token counter?

It is an estimate that is usually within 10 to 15 percent for English text. It splits the text the way tokenizers do and guesses the cost of each piece. Exact counts need each provider’s own tokenizer, which is too large to ship in a web page. Use the provider’s token-counting tool when you need precision.

How many words is 1,000 tokens?

About 750 English words. Code, numbers, URLs and non-English text use more tokens per word, so 1,000 tokens covers fewer of them. Chinese, Japanese and Korean often cost one token or more per character.

How is LLM API cost calculated?

Input tokens times the input price, plus output tokens times the output price, with prices quoted per million tokens. Output usually costs several times more than input. Prompt caching lowers the price of repeated input, and batch processing can halve the total.

Why do the prices differ from the provider’s page?

The prices are the standard list prices from OpenAI, Anthropic and Google, checked on 7 October 2026. Providers change them often, so edit any number in the table to match the current pricing page, and add models that are not listed. Your changes are saved in your browser.

Is my text uploaded or stored?

No. The text is counted in your browser and never sent. Only the prices you edit are saved, in your own browser storage.

What happens if a prompt is longer than the context window?

The provider rejects the request or cuts the oldest text, depending on the API. Keep the prompt plus the reply under the window. The rows in the table turn red when a model’s window is too small.

Why does non-English text use more tokens?

Tokenizer vocabularies are built mostly from English and code, so other scripts break into more, smaller pieces. The same sentence can cost two to four times as many tokens in some languages.

More free tools

Project Estimate CalculatorCost and timeline from best, likely and worst hoursOpen tool →Lorem Ipsum GeneratorDummy text in Latin, English or PM speakOpen tool →Online NotepadMarkdown notes that autosave in your browserOpen tool →
Available for full-time and freelance

Need a custom tool, site or store?

I scope, design and build tools, websites and Shopify stores for teams in India and abroad. Send a short brief and I will reply within 48 hours.