Tools/phuryn/claude-usage

claude-usage

A local dashboard for tracking your Claude Code token usage, costs, and session history. Pro and Max subscribers get a progress bar. This gives you the full picture.

2.0k+39/wkemergingPythonMIT Licensenew this week

The Lens

Claude Usage reads the JSONL session logs that Claude Code writes to your machine and turns them into charts. Per-model token breakdowns, cache hit rates, cost estimates, and session history, all in a local browser dashboard. Anthropic's own UI gives you a progress bar. This gives you the full picture.

Zero dependencies. Standard library Python only, no pip install. Clone the repo, run the dashboard command, and it serves a Chart.js UI at localhost:8080 that auto-refreshes every 30 seconds. A SQLite database at ~/.claude/usage.db caches the parsed data for fast incremental re-scans. CLI commands cover scan, today, stats, and dashboard.

Pro and Max subscribers who want to understand their actual token consumption per session and per model need this. The cost estimates use current API pricing, which is useful even for subscription users as a proxy for understanding usage patterns.

The catch: only captures local Claude Code sessions. Cowork sessions (server-side) are not included. Cost estimates reflect API pricing, not what you actually pay on a Pro/Max subscription. Single-maintainer project, so pricing tables need manual updates when Anthropic changes models.

Free vs Self-Hosted vs Paid

fully free

Free Tier

Everything. MIT licensed. Zero runtime cost, no external API calls.

Self-Hosted

Runs locally. git clone + python3 cli.py dashboard. No virtual env, no pip install, no server infrastructure.

Paid Alternatives

No direct competitor. Anthropic's built-in usage display is minimal. Third-party API cost trackers like Helicone ($0-150/mo) or LangSmith ($0-400/mo) cover API usage but not Claude Code local sessions.

Free and zero-dependency. Fills a gap Anthropic's own tools don't cover.

Self-hosting ops:trivial

Get tools like this every Wednesday

One featured tool, three on the radar. No fluff.

Score
59/100 · C+
Adoption17/30
Maintenance10/25
Community7/20
License15/15
Analysis10/10

A low score is not a verdict on quality. Young and niche tools start low by design. How we calculate scores

Trust Signals

Permissive license (MIT)

License: MIT License

Use freely, including commercial. Just keep the license.

Commercial use: ✓ Yes

About

Owner
Pawel Huryn (User)
Stars
2,002
Forks
364

Explore Further

More tools in the directory