Skip to content
tokmeterGet Tokmeter

A local ledger for AI work · v1.24.0

Every token
has a trail.

Your coding agents already leave a record. Tokmeter reads it on your machine, so you can trace usage by agent, project, model and day.

24 local sources22 read-only MCP toolsNo account

01 / THE BETTER QUESTIONLOCAL LEDGER · FOUR VIEWS

A better question than “how much?”

Where did it go?

A total is a beginning. Read the same day by agent, project, model or estimated cost, with each source kept in its own column.

How Tokmeter makes the numbers
LEDGER / TUESDAYILLUSTRATIVE DATA
1.25Mtokens in one sample day
across four coding agents

Which agent wrote the record?

Claude Code486,210
Codex312,480
Cursor201,930
Gemini CLI247,700

Sample figures, not your data. Cost is an estimate, not a provider invoice.

24agents and editors with a built-in parser, plus custom sources22read-only MCP tools your assistant can call11menu bar themes for the same numbers0API keys, accounts or telemetry required

A day on the ledger

Four agents, one honest day.

Tokmeter works around your routine, not the other way round. Scroll from the first session to the moment the day is sealed.

Ledger · TuesdayLive
TimeAgent · projectTokensEst.
09:12Claude Codeproduct · Model A486,210$1.92
11:40Codexproduct · Model B312,480$1.14
14:05Cursorresearch · Model C201,930$0.61
17:30Gemini CLIside project · Model A247,700$1.15
Day total1,248,320$4.82
Illustrative sample · not an invoice
  1. 09:12Claude Code

    A morning refactor.

    Three sessions on the product repo, read from the transcripts the agent already wrote. Nothing to connect, nothing to sign in to.

    Input, cached input and cache writes stay in their own buckets.

  2. 11:40Codex

    A second opinion.

    A different agent, a different file format, the same ledger. Response receipts are read as the tool wrote them.

    Reasoning is its own bucket wherever the source reports it.

  3. 14:05Cursor

    An afternoon in the editor.

    Some tools keep their history in SQLite rather than files. Tokmeter reads those databases too.

    Missing data stays missing. Nothing is invented to fill a gap.

  4. 17:30Gemini CLI

    An evening experiment.

    The side project gets its own column, so it never hides inside the day’s total.

    Merge, rename, tag or hide projects with aliases.

  5. 23:59Sealed

    The day closes.

    At midnight the day is sealed with the prices it was billed at. A later price change won’t rewrite it, and a thread you delete before then still counts.

    Sealed days are immutable. Shrinking one takes an explicit, forced rescan.

One ledger · your way in

Fits the way you work.

01Command line

Stay in the terminal.

An overview, then models, projects, days and a narrative digest. Every report takes the same filters.

  • --today, --week, --since on every report
  • --project to narrow to one codebase
  • Plan windows and reset times with tokmeter quota
Read the CLI reference

~/work

$ tokmeter projects --today

Today · by project
product        798,690
side project   247,700
research       201,930

✦Projects, not just totalsIllustrative output

02macOS menu bar

A quieter glance.

Your working day in the menu bar, read from the same local daemon as everything else.

  • Eleven themes, from Paper to Passbook
  • Estimated and tool-reported costs shown apart
  • macOS 14+ on Apple silicon
Menu bar and themes
Tokmeter’s Paper theme in the menu bar app, showing daily tokens with estimated and tool-reported costs kept separate. Sample data.

✦Actual app renderSynthetic demo data

03MCP

Let your assistant read the same ledger.

Ask in plain words. The answer comes from the same local numbers, through tools that can only read.

  • 22 tools, every one marked read-only
  • Breakdowns, comparisons, forecasts and budgets
  • One command to add it to Claude Code
MCP tool reference

Which project used the most today?

callstokmeter_projectsread-only

product, at 798,690 tokens across Claude Code and Codex. About 64% of the day.

✦No write accessIllustrative exchange

Numbers with a point of view

Eleven ways to read the same day.

A paper edition, an instrument, a pocket passbook. Each one is the app’s own render of synthetic demo data.

The small print, up front

Numbers with their context intact.

01 · Cost

An estimate has a label.

API-equivalent estimates stay apart from tool-reported costs. Neither is automatically your provider’s invoice.

02 · Coverage

A missing field stays missing.

Session formats differ. Tokmeter reports what an agent writes and what its parser understands, and says which.

03 · Privacy

The ledger starts at home.

Your usage stays on your machine: no telemetry, no account, no API keys read or sent. The one credential it ever sends is the Cursor app’s own session, to cursor.com, and only when you run the opt-in tokmeter cursor sync. Tokmeter does download public price catalogs on its own about once a day, and the security page lists every host. The Mac app also checks for updates.

Inspect how the numbers are made

The details

Plainly, as built.

Checked against Tokmeter v1.24.0 at 99d2c82. If the source and this table disagree, the source wins.

Command line
Node.js 22+. Tools that keep history in SQLite need 22.13+, and DeepSeek Harness logs need 22.15+.
↗
Menu bar app
macOS 14+ on Apple silicon, installed with Homebrew.
↗
What it reads
Session files and local databases your agents already write. 24 integrations with a parser, plus custom sources in a documented line format.
↗
Assistants
An MCP server with 22 tools, every one marked read-only.
↗
Costs
Tool-reported costs and price-based estimates kept apart. Neither is your provider’s invoice.
↗
History
Each finished day is sealed with the rates it was billed at. A later price change won’t rewrite it.
↗
Network
An optional fetch of a public model-price catalog (--light skips it). The macOS app checks GitHub for updates. The opt-in tokmeter cursor sync sends the Cursor app’s own session to cursor.com.
↗
Account
None. No provider API keys, no telemetry.
↗
Licence
Applications AGPL-3.0-only. The core library MPL-2.0.
↗

Tokmeter v1.24.0

Your next day. A little clearer.

CLI / npm

Try it in one command.

npx -y @sriinnu/tokmeter@1.24.0 --today
Installation guide
macOS / Homebrew

Keep it in the menu bar.

brew install --cask sriinnu/homebrew-tap/tokmeterbar
Releases & source ↗
MCP / Claude Code

Let your assistant ask.

claude mcp add tokmeter --scope user -- npx -y @sriinnu/tokmeter-mcp serve
MCP tool reference