Count tokens before API calls
Paste any prompt to see the exact token count for GPT-4o, Claude, Gemini, and Llama — avoiding unexpected context window overflow.
Estimate API costs
Enter your expected output tokens to see the estimated cost per model, so you can pick the most cost-effective option for your task.
Compare model pricing
View per-million-token input and output pricing side by side across all supported models to inform your model selection.
Add custom models
Define custom models with your own pricing, tokenizer family, and context window — saved to localStorage for persistent use.
Debug context limits
Check whether your prompt fits within a model context window before sending it, and see how many tokens remain for the response.
Token Counter runs entirely in your browser tab. No data is uploaded, no server processes your input, and no account is required.

Encode and decode Base64 for text, files, images, audio, and video.
Encoding & Data
Format, validate, minify, and explore JSON with tree, table, and map views.
Encoding & Data
Decode, verify (HMAC/RSA/ECDSA), encode, and compare JWTs side-by-side.
Security & Auth
Decode SSL/TLS certificates, chains, SANs, and fingerprints.
Security & Auth