Free Token Counter
Count GPT tokens in your browser and see how text splits. Add your Anthropic key for a Claude count, or compare a web page as HTML, text and Markdown.
Loading tool…
How it works
Paste text or a URL
Text is counted in this tab as you type. A URL is fetched once; its HTML, text and Markdown are counted here.
Read both encodings
o200k_base and cl100k_base side by side, with every token highlighted.
Add Claude if you need it
With your Anthropic key, the text goes from this tab to Anthropic's token counting API. No key, no Claude number.
Which models use which encoding?
o200k_base: GPT-5, GPT-4.1, GPT-4o, o1, o3 and o4-mini. cl100k_base: GPT-4, GPT-3.5 Turbo and text-embedding-3.
How is the Claude count made?
Your key and text go from this tab straight to Anthropic's count_tokens endpoint, never to our server. Counting is free but rate limited. Anthropic calls the result an estimate that can include a few tokens it adds.
Does my text leave the browser?
GPT counts run in this tab. Count a URL sends only the URL to our server. Count with Claude sends the text and your key to Anthropic. The key is kept only if you tick Remember.
Is <|endoftext|> one token here?
No. Pasted text is counted as plain text, so special-token names count as their characters and never stop the count.
Give your agent the page, not the HTML.
Browser Use agents open pages in a real browser, including dynamic ones, and return structured data.