Token and PDF counter
Find out how much of a model’s context your text uses, and leave room for the answer.
Loading the private counter… The explanation below is available now.
What does a token count tell you?
A token is a piece of text used by a model. It can be a word, part of a word, punctuation, or whitespace. Different model families can count the same text differently, especially code and languages other than English.
How to check whether a document will fit
- Choose the exact supported model tokenizer.
- Paste text or choose a text PDF. Review the extracted text before counting it.
- Enter the context length enabled in your app and allow space for your instructions, earlier messages, and the answer.
- If the total is too large, split the document or use a document-search workflow that retrieves relevant passages.
The counter runs in your browser. It downloads tokenizer files from this website and sends neither your document nor your text to a model provider. Shared links contain settings only. Scanned, encrypted, damaged, and partly extractable PDFs are reported instead of being treated as complete documents.
Context capacity and available memory are different limits. Use the memory calculator to check memory, read the context-window guide, or follow the local PDF chat setup.