Chat Message Token Estimator
Estimate token usage across system, user, assistant, and developer chat messages.
About This Tool
Paste messages JSON or a role-prefixed transcript to estimate token usage by message.
This helps identify which messages dominate context before shortening history or retrieved content.
Estimated tokens
30
Messages
2
Avg/message
15
Token counts are a planning estimate. Use the target model tokenizer for final billing or hard limits.
How to Use
- 1
Enter the values you need or paste your text into the input area.
- 2
Adjust any options, units, or settings for your exact use case.
- 3
Review the result and copy it into your document, workflow, or next task.
Features
Instant Results
Outputs update directly in the browser as you enter values.
Browser-Based Processing
Your inputs are handled locally and are not uploaded for calculation.
Simple Inputs
Clear fields and readable outputs keep repeat tasks fast.
Free to Use
Use the tool immediately with no sign-up or installation.
Common use cases
- ›Estimate total chat tokens before an API call.
- ›Compare system, user, and assistant message weight.
- ›Trim long chat history before it reaches context limits.
Related Tools
Prompt Token Estimator
Estimate prompt tokens, characters, words, and lines before sending text to an LLM.
Chat Messages JSON Builder
Build clean chat messages JSON from system, user, and assistant message fields.
LLM Context Window Planner
Plan context window usage across fixed prompt tokens, chat history, retrieved docs, and reserved output.