toktrack
Track AI CLI spending across Claude, Codex & Gemini in 40ms
toktrack β Fast AI CLI spending tracker for Claude, Codex & Gemini
Summary: toktrack scans AI coding CLI session files to report spending per model and day, supporting Claude Code, Codex CLI (including gpt-5.3-codex), Gemini CLI, and OpenCode. Built in Rust with SIMD JSON parsing, it processes over 3,500 files in about 40ms and caches cost history independently to preserve data after session deletions.
What it does
toktrack analyzes CLI session files to calculate spending by model and date using a single command. It supports multiple AI coding CLIs and caches cost data beyond default session retention periods.
Who it's for
Developers using Claude Code, Codex CLI, Gemini CLI, or OpenCode who need detailed, fast tracking of their AI usage costs.
Why it matters
It prevents unexpected billing by providing quick, accurate spending insights and preserves cost history even after session files are deleted.