ccbar: see your Claude Code limits without leaving the prompt

Have you ever been deep in a Claude Code session and wondered how much usage you actually have left? Normally you stop, open the Claude website and check. Otherwise you keep spending context and limits without knowing how close you are to the edge. So I built ccbar.
What it shows
- Model and effort level.
- Current workspace.
- Context-window usage.
- 5-hour and 7-day limits, with the time left until each resets.
The bars change from green to yellow to red, so you can read your remaining headroom at a glance. When your current pace would use up a limit before it resets, ccbar adds a warning with the estimated time. Styles and themes let it match your terminal.
Install
npx ccbar-cliHow it works
Claude Code can run any command as a status line and pipe it a JSON object on every refresh. That JSON already includes the model, effort level, working directory, context-window percentage, cost, and both rate limits with their used_percentage and resets_at time. ccbar is a single Bash script that reads those fields with jq and draws two lines of coloured bars.
{
"statusLine": {
"type": "command",
"command": "~/.local/bin/ccbar render",
"padding": 0
}
}- No network calls and no tokens. Everything comes from the data Claude Code already passes in, so it’s instant and works offline.
- Burn-rate warning. From how much of a window you’ve used and how long is left until it resets, ccbar estimates whether your current pace runs out first, and when.
- Local history. It caches the last payload for
ccbar statsand appends a small, throttled history file (at most once a minute, size-capped), soccbar historycan draw a 7-day sparkline with estimated cost. - One dependency. Bash and
jq. A small Node wrapper exists only sonpxcan install it.
The installer wires ccbar into your Claude Code settings, backing up the file first, and runs a short setup wizard. It is also available as a Claude Code plugin. The code is on GitHub.