TokenTracker is a free, open source monitoring & observability project written in JavaScript and released under MIT. It has 1,659 GitHub stars, 172 forks and 34 open issues, and was last pushed yesterday. On this registry it ranks #189 of 271 tracked projects in Monitoring & Observability, with 5 head-to-head comparisons available.

What is TokenTracker?

TokenTracker is a local-first AI token usage and cost tracker for AI coding tools such as Claude Code, Codex, Cursor, Gemini, and the DeepSeek Harness, delivered as a CLI, a local web dashboard, and native desktop apps for macOS, Windows, and Linux.

What it is

TokenTracker is a locally running observability tool that measures how many tokens AI coding assistants consume and what that consumption costs. It ships as an npm package named tokentracker-cli, a dashboard served at http://localhost:7680, and native desktop builds: a macOS menu bar app distributed as TokenTrackerBar.dmg, a Windows system tray application distributed as TokenTracker-Setup.exe, and a Linux TokenTracker-linux-x86_64.AppImage. The project lives in the Node.js ecosystem, requires Node.js 20 or newer, and is written in JavaScript under the MIT licence.

The concrete problem it solves is visibility into AI spend without surrendering prompts or logs to a third party. TokenTracker parses tool logs on the machine where they were produced and never reads prompts. That replaces the common arrangement in which usage accounting depends on a cloud account and API keys held by an external service. No account creation, no API key provisioning, and no data upload are part of the normal workflow; the dashboard opens locally on first run.

Key capabilities

  • CLI entry point npx tokentracker-cli installs hooks, syncs data, and opens a dashboard at http://localhost:7680 with usage trends, model breakdown, and cost analysis.
  • Auto-detected hooks for every supported AI coding tool already installed on the machine.
  • Four native widgets covering usage, activity heatmap, top models, and rate limits.
  • A desktop pet companion that codes, celebrates streaks, follows the cursor, and rests when the user rests.
  • Fifteen achievement tracks unlocked from actual coding behaviour.
  • An optional Skills tab that browses more than 250 public skills and syncs them across Claude, Codex, Grok, Antigravity, Gemini, OpenCode, and Hermes.
  • Cursor token reading via the system sqlite3 CLI, with a fallback to node:sqlite on supported Node releases.

Who uses it and how

  • Individual developers running several AI coding tools at once and wanting per-model cost and usage breakdowns in one place.
  • macOS users who prefer an always-visible menu bar status icon, desktop widgets, and the dashboard rendered in a WKWebView.
  • Windows users who want a per-user installer requiring no administrator rights, or the portable zip from the releases page, with the dashboard in WebView2.
  • Linux users running the tray-enabled AppImage build.
  • Privacy-conscious developers who want usage analytics while keeping prompts and logs entirely on their own machine.

Getting started

Run npx tokentracker-cli with Node.js 20 or newer installed; the first run installs hooks, syncs data, and opens the dashboard. Native desktop builds are available as TokenTrackerBar.dmg, TokenTracker-Setup.exe, and TokenTracker-linux-x86_64.AppImage, with a homepage at https://www.tokentracker.cc.

How it compares

This registry provides no list of paid products that TokenTracker replaces, and the project's own facts name no comparable tools. On the evidence available, it stands alone in this registry as a local-first token and cost tracker for AI coding tools.

When to use it — and when not to

A self-hoster must run a Node.js 20 or newer runtime, keep a local dashboard bound to port 7680, and have either the system sqlite3 CLI or a Node release supporting node:sqlite available for Cursor token reading; no external database, object storage, or SMTP service is required. Anyone who needs hosted, multi-user, or centrally administered team reporting should look elsewhere, because TokenTracker is explicitly local-first and account-free. The facts also contain an inconsistency worth noting before adoption: the registry metadata and tagline describe support for 31 coding tools, while the README claims 39, so the exact coverage count should be verified against the current release.

project readme (upstream, from github) — read inline

Token Tracker

English · 简体中文 · 日本語 · 한국어 · Deutsch

Track every AI token — then bring your usage to life

An accurate, local-first token usage and cost dashboard for 39 AI coding tools — plus a desktop pet, 4 native widgets, and 15 achievement tracks. No cloud account, no API keys, no setup.

npm version npm downloads Homebrew License: MIT CLI macOS app Windows app GitHub stars Featured in 阮一峰周刊 #393 Author tokens


📊 See the token dashboard in action





🐾 A living desktop companion
Codes, celebrates streaks, follows your cursor, and rests when you do.
🧩 Four native widgets
Usage, activity heatmap, top models, and rate limits at a glance.

🏆 Unlock achievements from the way you actually code.



🎬 Meet TokenTracker



Token Tracker Dashboard



If TokenTracker saves you time, please star it on GitHub — it helps other developers find it.


ko-fi


⚡ Quick Start

Requirements: Node.js 20+ (CLI runs on macOS / Linux / Windows; native desktop app ships for macOS (menu bar), Windows (system tray) and Linux (AppImage, tray). Cursor token reading uses the system sqlite3 CLI when available and falls back to node:sqlite on supported Node releases).

npx tokentracker-cli

That's it. First run installs hooks, syncs your data, and opens the dashboard at http://localhost:7680.

What you get in 30 seconds:

  • 📊 A local dashboard at localhost:7680 with usage trends, model breakdown, cost analysis
  • 🔌 Auto-detected hooks for every supported AI tool you have installed
  • 🏠 Local-first — parses logs on your machine; no account or API keys required
  • 🧩 Optional: a Skills tab that browses 250+ public skills and syncs them across Claude · Codex · Grok · Antigravity · Gemini · OpenCode · Hermes

Want a native desktop app?

  • macOSDownload TokenTrackerBar.dmg → drag to Applications. Menu bar status icon, desktop widgets, and the dashboard in a WKWebView.
  • WindowsDownload TokenTracker-Setup.exe → run the per-user installer (no admin needed). System-tray app with the dashboard in WebView2. Portable zip also on the releases page.
  • LinuxDownload TokenTracker-linux-x86_64.AppImagechmod +x and run. Tray app with the dashboard in a WebKitGTK window. It carries its own GTK/WebKit, so it needs nothing from your distro beyond a current glibc; on GNOME the tray icon still needs the AppIndicator extension. .deb and .rpm packages are also on the releases page — those link the distro's webkit2gtk-4.1, gtk3 and appindicator instead, so the .deb will not install on Debian 12 (use the AppImage there).

Install globally for shorter commands:

npm i -g tokentracker-cli

tokentracker              # Open the dashboard
tokentracker sync         # Manual sync
tokentracker status       # Check hook status
tokentracker status --json     # Machine-readable summary (pipe to jq, ingest from AI agents)
tokentracker status --light    # Plain ASCII table (CI / SSH, no spinner)
tokentracker doctor       # Health check

🍺 Homebrew (macOS)

Prefer brew? Install directly — no extra tap step needed:

# macOS menu bar app (DMG)
brew install --cask xiufengsun/tokentracker/tokentracker

# CLI only
brew install xiufengsun/tokentracker/tokentracker

Upgrade with brew upgrade --cask xiufengsun/tokentracker/tokentracker. The tap auto-bumps within an hour of every new release.

🐧 Linux (AppImage, .deb, .rpm)

Every release ships all three. One self-contained file, no package manager:

chmod +x TokenTracker-linux-x86_64.AppImage
./TokenTracker-linux-x86_64.AppImage

Or install through your package manager:

sudo apt install ./TokenTracker-linux-x86_64.deb    # Debian / Ubuntu
sudo dnf install ./TokenTracker-linux-x86_64.rpm    # Fedora / RHEL

Debian 12: the .deb depends on libappindicator3-1, which bookworm dropped in favour of libayatana-appindicator3-1, so apt refuses it. Use the AppImage.

All three bundle their own Node runtime and the dashboard. The AppImage additionally carries GTK3, WebKitGTK and appindicator, which is why it is ~120MB and installs nowhere; the .deb and .rpm link the distro's webkit2gtk-4.1, gtk3 and appindicator instead, at ~55MB. Tested on Arch + KDE Plasma; on GNOME the tray icon requires the AppIndicator extension, and clicking the tray icon opens the menu rather than the window (a libayatana-appindicator limitation).

An Arch PKGBUILD for a local pacman install lives in TokenTrackerLinux/packaging/arch/tokentracker-linux — see TokenTrackerLinux/README.md. It is not published to the AUR.


✨ Features

  • 🔌 39 AI tools out of the box — Claude Code, Codex CLI, AStudio, Cursor, Gemini CLI, Antigravity, Kiro, OpenCode, OpenClaw, Every Code, Hermes Agent, GitHub Copilot, Kimi Code, CodeBuddy, WorkBuddy, Grok Build, oh-my-pi, OmO, pi, Dots, Prime Agent, Craft Agents, Reasonix, Kilo CLI, Kilo Code, Roo Code, Zed Agent, Goose, D

readme truncated — read the full docs on github

Frequently asked questions

Is TokenTracker free to use?

TokenTracker is open source under the MIT licence. There is no licence fee and no seat count — you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does TokenTracker do?

Local-first AI token usage & cost tracker for 31 coding tools incl. Claude Code, Codex, Cursor, Gemini & DeepSeek Harness—with native apps. Never reads prompts.

What is TokenTracker written in?

TokenTracker is primarily written in JavaScript. Its source is publicly available at https://github.com/xiufengsun/TokenTracker, and it has 1,659 GitHub stars.