Skip to content

ddaverse/llm-token-counter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 

Repository files navigation

🚀 LLM Token Counter (GPT, Claude, Gemini)

If you are building AI apps, managing LLM tokens and API cost is critical.

I built a free browser-based tool that helps developers instantly estimate token usage and cost for modern LLM APIs.

🔗 Tool: https://www.ddaverse.com/llm-token-counter

What this tool does

Count input tokens for any prompt

Estimate output tokens

Calculate API cost automatically

Show context window usage

Works for multiple AI providers

LLM APIs charge based on tokens processed, not characters or words, so understanding token usage helps control costs and avoid context-limit errors.

Supported Models

GPT-4o / GPT-4.1

GPT-4o mini

Claude 3.5 Sonnet / Haiku

Gemini 2.0 Flash

Gemini 1.5 Pro

Llama 3.1

Mistral AI

Key Features

⚡ Real-time token counting

💰 Input + output cost estimation

📊 Context window usage meter

📄 Export token report (.txt)

🔒 100% private — runs locally in browser (no API key needed)

Example Use Cases

Developers use this to:

Optimize prompts before sending to APIs

Estimate OpenAI / Claude API costs

Avoid context window overflow

Debug prompt size during prompt engineering

Example: Prompt: "Explain microservices architecture"

Input tokens: ~200 Output tokens: ~80 Estimated GPT-4o cost: ~$0.0009

Perfect for

AI engineers

Prompt engineers

LLM developers

AI SaaS builders

API cost optimization

About

Free online LLM Token Counter to estimate token usage and API cost for modern AI models like GPT-4o, Claude, Gemini, Llama, and Mistral. Paste your prompt, get instant token count, context usage, and estimated API cost — all processed locally in your browser.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors