Token Counter

Answer: The Token Counter produces your output instantly from the input you provide — everything runs in your browser, free, with no signup required.

Estimate tokens for GPT-4, Claude, Gemini & calculate API costs

Ad
0
Est. Tokens
0
Words
0
Characters
0
Sentences
$0.00
Est. Cost (GPT-4o)
ModelContext WindowFits in ContextInput Cost/1K
Ad

How Token Counting Works

Large Language Models process text in "tokens" — chunks of characters that represent words, parts of words, or punctuation. A general rule: 1 token ≈ 4 characters ≈ 0.75 words in English. Common words tend to be single tokens ("the", "and", "run"); rarer words split into pieces ("tokenization" becomes something like "token" + "ization"); and every punctuation mark, space pattern, and line break takes its share.

That's why two texts of identical word count can tokenize differently. A legal paragraph stuffed with defined terms and citations runs hotter than a chatty email, and a page of JSON or code can double the token count of the plain English describing it.

Why Token Counting Matters

How many tokens is that in words?

For budgeting, convert both directions using the standard ratio of about 1.3 tokens per word (OpenAI's published rule of thumb is 100 tokens ≈ 75 words; this tool uses the equivalent ~4 characters per token, cross-checked against a 1.3× word multiplier):

TextEst. tokensEst. characters
Sentence (15 words)~20~80
Paragraph (100 words)~130~520
Blog section (250 words)~325~1,300
Article (500 words)~650~2,600
Long article (2,000 words)~2,600~10,400

Paste the real text into the counter instead of trusting word-count math whenever precision matters — the whole point of a tokenizer estimate is catching the code, URLs, and tables that break the words-only shortcut.

What fits in a context window?

Context windows are quoted in tokens, which means nothing to most humans. The same budget in words and paperback pages (at 275 words per page):

Context windowApprox. wordsApprox. pagesFeels like
8K tokens6,000~22A long report
32K tokens24,000~87A short book
128K tokens96,000~350A thick novel
200K tokens150,000~550Two average novels
1M tokens750,000~2,700A bookshelf

Remember the window holds input and output. A model that must draft 2,000 tokens of answer has 2,000 fewer tokens of your document to read, and multi-turn chat re-sends the whole conversation every request, which is why long chats get slow or start "forgetting" the earliest messages.

Token efficiency by content type

Not all text tokenizes equally. Approximate characters-per-token by content, from tokenizer behavior across the major model families:

Content typeChars per tokenWhy
Plain English prose~4Common words are single tokens
Code~3 to 3.5Underscores, brackets, and rare identifiers split often
JSON / URLs~2.5 to 3Quotes, braces, and long path segments fragment badly
Non-Latin scripts~1 to 2Many scripts fall outside the common token vocabulary

The practical consequence: the same information costs different amounts depending on format. Pretty-printed JSON with indentation can run a third more tokens than the compact equivalent, and translating a prompt from English can double its token count in some languages. If you're piping structured data into prompts, strip what the model doesn't need.

How token billing actually works

Three mechanics explain almost every "why is my bill higher than my estimate" question. First, input and output are priced separately, and output tokens typically cost several times more than input — the answer you receive is the expensive part. Second, everything in the request counts: system instructions, few-shot examples, and the full conversation history on later turns. Third, most providers now discount repeated input through prompt caching, which can cut the cost of a stable system prompt dramatically on high-volume apps. For comparing per-model prices across providers at real volumes, the LLM pricing tracker puts current rates side by side, and the prompt writing guide covers trimming prompt length without losing quality.

Token Estimates by Model

Token counts vary slightly between tokenizers (tiktoken for OpenAI, SentencePiece for Claude, etc.). This tool provides a close estimate based on the standard ~4 chars/token ratio, then shows the result against each model's context window and input price so you can spot a "doesn't fit" before you send it.

Frequently Asked Questions

How many words is 1,000 tokens?

About 750 words of English prose, using the standard rule of thumb that 100 tokens is roughly 75 words. Going the other way, a 1,000-word article costs about 1,300 tokens.

How many tokens is a 500-word article?

Roughly 650 tokens for plain English, since a word averages about 1.3 tokens. Code, URLs, or heavy punctuation push the count higher because symbols and unusual character sequences tokenize less efficiently.

How accurate is a character-based token estimate?

Within roughly 10-20% for ordinary English prose. Exact counts require the model's own tokenizer — tiktoken for OpenAI models, Claude's tokenizer, SentencePiece-based tokenizers elsewhere — because every vocabulary splits text slightly differently.

Do all AI models count tokens the same way?

No. Each model family has its own tokenizer and vocabulary, so the same text tokenizes slightly differently across GPT, Claude, Gemini, and Llama. For English prose the differences are small — a few percent — which is why a single estimate is useful for budgeting across providers.

Why was I billed for more tokens than I sent?

API bills count more than your visible prompt. System instructions, conversation history on multi-turn requests, and the model's generated response all count — and output tokens are usually priced higher than input tokens. Many providers also discount repeated input via prompt caching, so itemized usage rarely matches a naive count of your text.