TokenTracker
TokenTracker is a local-first, zero-config CLI and desktop app that automatically collects and visualizes token usage across 25 AI coding tools (Claude Code, Cursor, Copilot, Gemini, Kimi, Grok, and others). It runs entirely on your machine with no account or API keys required, displaying costs, trends, and usage breakdowns in a web dashboard and native menu bar/system tray apps.
Key facts
Objective fields from the source. Values we can't verify are shown as “Unknown” rather than guessed.
| Field | Value |
|---|---|
| Repository | mm7894215/TokenTracker |
| Owner | mm7894215 |
| Primary language | JavaScript |
| License | MIT — OSI-approved |
| Stars | 941 |
| Forks | 91 |
| Open issues | 16 |
| Latest release | v0.74.0 (2026-07-08) |
| Last updated | 2026-07-08 |
| Source | https://github.com/mm7894215/TokenTracker |
What TokenTracker is
Node.js-based tool that installs hooks into supported AI tools' log/cache directories to extract token counts and cost data. Aggregates metrics locally into a SQLite database, serves a React/Vue dashboard on localhost:7680, and offers native macOS (Electron menu bar) and Windows (WebView2 system tray) wrappers. Optional cloud sync merges usage across devices; optional leaderboard and skills manager require opt-in sign-in.
Get the TokenTracker source
Clone the repository and explore it locally.
git clone https://github.com/mm7894215/TokenTracker.gitcd TokenTracker# follow the project's README for install & configurationNeed it deployed, integrated, or customized instead? DEV.co ships production installs.
Best use cases
Implementation considerations
- Node.js 20+ is a hard requirement. Verify all developers have it installed; CLI runs on macOS, Linux, and Windows; native apps (menu bar, system tray) are platform-specific.
- First run auto-detects and installs hooks into tool cache/config directories (e.g., ~/.cursor, ~/.config/copilot). Verify those paths exist and are not locked by MDM or endpoint security before rollout.
- SQLite database is stored locally (location varies by OS); no automatic cloud backup unless user opts in. Teams should document where data is stored and any local backup strategy.
- Cost pricing uses LiteLLM's model database (auto-refreshed daily if online) plus curated overrides. Offline snapshot is bundled, but custom model pricing requires manual entry or forking.
- Optional features (leaderboard, cloud sync, skills manager) require GitHub/OAuth sign-in and network access. Fully offline users should disable these to avoid confusion or errors.
When to avoid it — and what to weigh
- Centralized, enterprise-scale AI governance required — This tool is local-first by design. Enterprise customers needing audit logs, role-based access, or centralized policy enforcement should evaluate dedicated AI Ops platforms (e.g., LiteLLM proxy, Helicone, Langsmith).
- Strict air-gapped or non-Node.js environments — TokenTracker requires Node.js 20+ and uses system-level hooks to read tool logs/caches. Fully air-gapped systems or non-Node projects (Rust, Go, Java teams) will find it difficult to deploy.
- Real-time API billing integration with vendor accounts — TokenTracker infers costs locally; it does not integrate directly with OpenAI, Anthropic, Google billing APIs. For live account-level spend synced from vendor dashboards, consider vendor-native solutions.
- Windows system tray app on non-admin user accounts — The Windows installer is per-user (no admin required), but some enterprise locked-down workstations may block WebView2 or system tray integration. CLI remains usable; desktop app may fail.
License & commercial use
MIT License (permissive OSI-approved). Allows commercial use, modification, and redistribution with attribution and no liability. No copyleft obligations.
MIT License permits commercial use without restriction. However, integration with proprietary AI tools and usage of cost data inferred from third-party tool caches should be reviewed for compliance with those tools' terms of service. No explicit warranty is provided; use 'as-is' in production at your own risk.
DEV.co evaluation signals
Editorial assessment — not user reviews. Directional, with an explicit confidence level.
| Signal | Assessment |
|---|---|
| Maintenance | Active |
| Documentation | Strong |
| License clarity | Clear |
| Deployment complexity | Low |
| DEV.co fit | Good |
| Assessment confidence | High |
TokenTracker is local-first and collects only token counts and timestamps—never prompts, responses, or file contents. Hook installation reads cache/log files from installed tools; verify those directories are protected by OS/file-level permissions. Optional cloud sync and leaderboard require GitHub OAuth; review privacy policy for any cloud-sync use. No mention of security audit or vulnerability disclosure policy in README; for production use, consider requesting a security assessment or review GitHub issues for known CVEs.
Alternatives to consider
LiteLLM Proxy / LangSmith
Centralized, language-agnostic AI usage tracking with direct API integration and audit logs. Better for enterprise governance; requires proxy setup and API-key management.
Helicone or Langfuse
Cloud-based AI observability platforms with real-time dashboards, cost tracking, and advanced analytics. Trade-off: data leaves your machine; suitable for SaaS teams not requiring full air-gap.
Vendor-native dashboards (OpenAI Platform, Anthropic Console, GitHub Copilot Dashboard)
Direct account-level billing and usage from vendors. No setup, but siloed by provider and requires manual aggregation. Suitable if using only one or two tools.
Build on TokenTracker with DEV.co software developers
Run `npx tokentracker-cli` to install hooks, sync data, and open a beautiful usage dashboard at localhost:7680. Local, private, free.
Talk to DEV.coRelated open-source tools
Surfaced by semantic similarity across the DEV.co open-source index.
Related on DEV.co
Explore the category and the services that help you build with it.
TokenTracker FAQ
Does TokenTracker send my data to the cloud?
Which AI tools are supported?
What happens if a tool updates or changes its log format?
Can I use this in a corporate/air-gapped environment?
Custom software development services
Adopting TokenTracker is usually one piece of a larger software development effort. As a software development agency, DEV.co provides software development services and web development expertise — pairing senior software developers and web developers with your team to design, build, and operate open-source observability software in production.
Start tracking your AI spend in 30 seconds
Run `npx tokentracker-cli` to install hooks, sync data, and open a beautiful usage dashboard at localhost:7680. Local, private, free.