Skip to content
All open-source projects
Token Meter app icon

Open source · Apache-2.0

Token Meter

See what your AI coding tools actually cost.

A native macOS menu-bar app that reads your Claude Code, Codex CLI, and local Ollama logs and turns them into token counts, cost estimates, and history — entirely on your own Mac. No account, no telemetry.

Apache-2.0SwiftmacOSSwiftUISwiftDataSwift ChartsWidgetKit

Version 1.0.0 · macOS 14.0 or later · Free

Token Meter — History and charts

What it does

Everything in Token Meter.

01

Menu-bar dashboard

Today's tokens and estimated cost at a glance, with input, output, and cache broken out.

02

A real app window

Overview, History, and Settings in a proper macOS window — with an optional Dock icon when you want one.

03

Reads your CLI logs

Watches Claude Code and Codex log files as they're written, so the numbers move in near-real time.

04

Rolling usage windows

A reconstructed 5-hour block with a live countdown, plus daily and weekly rollups.

05

History and charts

Tokens and cost over time, broken down per model and per project, kept in a local database.

06

Pricing you control

Bundled per-model rates, a daily community-sourced pricing feed, and your own overrides when you know better.

07

Local models too

Token counts, latency, and throughput for models you run through Ollama. Prompts are never inspected.

08

Widget and floating readout

A desktop widget, plus an optional always-on-top panel to keep the number in the corner of your screen.

Screens

See it running.

Token Meter — Menu-bar dashboard
Menu-bar dashboard
Token Meter — Widget and floating readout
Widget and floating readout

Read this first

It shows estimates, and says so.

Token Meter cannot show your real Claude Pro/Max or ChatGPT Plus subscription quota — neither Anthropic nor OpenAI exposes those limits through a public API. What it shows is reconstructed from the log files already on your Mac, and it is labelled estimated everywhere it appears.

  • Claude Code logs

    ~/.claude/projects/**/*.jsonl

    Estimated

    Parsed on your machine, no network. The logs are known to under-report token counts, sometimes significantly.

  • Codex CLI logs

    ~/.codex/sessions

    Estimated

    Parsed on your machine, no network. Same under-reporting caveat as Claude Code.

  • Ollama (local models)

    127.0.0.1

    Measured

    Real token counts from the local endpoint — and no cost to estimate, because the model runs on your Mac.

Usage from the Claude or ChatGPT web and desktop chat apps leaves no local trace, so it is invisible to the tool. The 5-hour block is Claude Code only, so Codex usage never inflates it. Billing-grade connectors to the provider usage APIs are planned, not shipped.

Install

Two ways to run it.

Take the notarized build, or build it yourself from source. Both end up in the same place.

01

Download and drag

Open the disk image and drag Token Meter into your Applications folder. The build is signed with a Developer ID and notarized by Apple, so it opens with no Gatekeeper warning.

02

Grant Full Disk Access

Reading CLI logs under your home folder needs Full Disk Access, in System Settings → Privacy & Security. The app detects the missing permission and walks you through granting it.

03

Or build from source

Needs macOS 14 and Xcode 16 or later. A source build is signed ad-hoc, which is fine locally — macOS may just re-confirm file access between launches.

git clone https://github.com/unichat-dev/token-meter.git
cd token-meter
make bootstrap
make build

Latest release

TokenMeter-1.0.0.dmg

macOS

Download for macOS1.4 MB
Version
1.0.0
Size
1.4 MB
Requires
macOS 14.0 or later
Released
Jul 24, 2026

Signed and notarized by Apple

Verify what you downloaded

Run this against the file you downloaded and compare it with the digest below. If the two don't match, don't open it.

shasum -a 256 ~/Downloads/TokenMeter-1.0.0.dmg

SHA-256

a343b12a19b5ce5789fc4a823e5b1c3c17b54cd0b889fb9d3304fdc9d482af84

Privacy

Nothing leaves your Mac.

All of it stays local

Parsing happens on-device and history lives in a local database under ~/Library/Application Support/TokenMeter.

Two network calls, both yours

A daily pricing refresh, and your own local Ollama endpoint if you use it. Nothing about your usage is ever transmitted.

No keys, no telemetry

This release holds no API keys at all. When connectors land, keys will live in the macOS Keychain only — never the database, defaults, or logs.

Source

Read it, fork it, ship it.

The whole thing is on GitHub under Apache-2.0. Issues and pull requests are welcome — students on our teams review them alongside everyone else.

github.com/unichat-dev/token-meter

Open the repository

Build with us

Want to build the next one?

Open an issue, send a pull request, or join the studio and ship something of your own — with your name on the commits.