Token Counter

Paste text or code below. Counted entirely in your browser — nothing is uploaded anywhere.

0
tokens
0
characters
chars / token
ModelContext windowUsage
Uses gpt-tokenizer (cl100k encoding — the same tokenizer OpenAI's models use, and a close estimate for Claude and most other current models too). Context-window percentages already reserve 15% headroom for system prompt, conversation, and response — the same margin llm-ctxpack uses when budgeting a repo pack.

Need this for a whole repo instead of pasted text? llm-ctxpack does git-diff-aware, budget-aware repo packing with secret redaction built in: npx llm-ctxpack . --budget 50000.