How to Check Your Claude Code Usage
There are three different questions hiding inside "how much Claude Code have I used?" — am I near my limit, what is my usage actually worth in dollars, and is that a lot. Each has its own tool: /usage, ccusage, and the leaderboard. This guide covers all three, plus the same tricks for OpenAI Codex and Gemini CLI.
1. /usage — the limits view
Inside any Claude Code session, type /usage. You get your current consumption against both limit layers — the rolling 5-hour session and the weekly cap — with reset times for each. The same dashboard lives at claude.ai/settings/usage if you'd rather check from a browser. This is the view to reach for when you're rationing your week.
What it doesn't tell you: tokens, dollars, or history. Percentages of an unstated allowance are deliberately opaque — for the real numbers you need to read your own logs. (New to the limits system? Start with how the limits actually work.)
2. ccusage — tokens and real dollars
Claude Code writes detailed session logs to your machine. The open-source ccusage CLI parses them locally — no account, no API key:
npx ccusage@latest daily — per-day tokens and API-equivalent cost
npx ccusage@latest monthly — monthly rollup, great for "what would API billing cost me?"
npx ccusage@latest blocks --live — live dashboard of your current 5-hour block
The killer column is API-equivalent cost: what your usage would have cost at pay-as-you-go prices. That number is how you know whether your subscription is a rounding error or a 10x bargain. Two caveats worth knowing: most tokens are prompt-cache reads (on Viberank's 11T+ tracked tokens, about 95%), which cost roughly a tenth of normal input — so big token counts overstate cost. And ccusage reads whatever logs exist locally, so a wiped machine means lost history.
The same command covers your other agents: ccusage reads local logs from Codex CLI, Gemini CLI, Copilot CLI, and OpenCode too, and aggregates them into one report. Codex users: we wrote up the Codex specifics separately.
3. Viberank — history, charts, and context
ccusage answers "what did I use?" — the leaderboard answers "is that a lot?" One command:
npx viberank-cliIt runs ccusage across all your detected tools and submits the totals (never code or prompts) to viberank.app. Your profile gets a GitHub-style activity heatmap, daily spend and token charts, per-model and per-tool breakdowns, and a global rank across 1,100+ developers. For calibration: the data says typical active users burn hundreds of dollars of API-equivalent value per month, and the heavy tail goes far beyond that.
Keep it current automatically
A one-off check goes stale the day you run it. Two commands make tracking permanent:
npx viberank-cli login — paste a token from viberank.app/settings/tokens
npx viberank-cli autosubmit — daily submission via launchd / systemd / Task Scheduler
From there your usage history builds itself — and when you're deciding whether to upgrade plans, the calculator can answer with your real numbers instead of a guess.
Checking usage FAQ
What's the fastest way to check Claude Code usage?
Type /usage inside Claude Code. It shows how much of your 5-hour session and weekly limit you've consumed and when each resets. The same data is at claude.ai/settings/usage.
How do I see my Claude Code usage in tokens and dollars?
Run npx ccusage@latest daily. It parses Claude Code's local session logs (no account or API key needed) into per-day input/output/cache token counts and API-equivalent USD costs per model. Add --json for machine-readable output.
Does ccusage work for OpenAI Codex and Gemini CLI too?
Yes. ccusage reads local logs from Claude Code, Codex CLI, Gemini CLI, Copilot CLI, OpenCode and more, and can report each separately or aggregate them — one report across your whole AI toolchain.
How do I track my usage over time automatically?
Run npx viberank-cli once to put your usage on the public leaderboard, then viberank-cli login and viberank-cli autosubmit to keep it current daily via your OS scheduler. Your profile charts daily spend, tokens, models, and streaks.
Is my code or conversation shared when I submit usage?
No. ccusage computes totals locally from your logs, and viberank-cli submits only aggregate numbers — tokens, costs, dates, and models. Code and prompts never leave your machine.