npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@robertoecf/claude-code-statusbar

v0.1.0

Published

Minimal information-dense statusbar for Claude Code. Shows dir, git, model, context, and rate-limit windows with live time-until-reset.

Readme

claude-code-statusbar

A minimal, information-dense statusbar for Claude Code. Shows directory, git branch, model, context window, and rate-limit windows with time-until-reset.

Example

wealthuman main | Opus 4.7 (1M) | ctx 87% | 2h 33m · 76% | 5d 12h · 59%

Segment by segment:

| Segment | Source | Color | |---|---|---| | wealthuman | Current directory (basename) | Blue | | main | Git branch — main* with * if dirty | Green clean, magenta dirty | | Opus 4.7 (1M) | Model name (normalized, strips "Claude " prefix) | Blue | | ctx 87% | Context window remaining | Green >50%, yellow 20–50%, red ≤20% | | 2h 33m · 76% | 5-hour session window: time until reset · percent remaining | Green >40%, yellow 15–40%, red ≤15% | | 5d 12h · 59% | 7-day weekly window: time until reset · percent remaining | Same thresholds as 5h |

The rate-limit segments only appear for Claude Pro/Max subscribers and only after the first API response in the session. Values come from the rate_limits.*.used_percentage and rate_limits.*.resets_at fields Claude Code passes to the statusline script via stdin JSON — they refresh on both turn-start (when you submit a prompt) and turn-end (when the assistant finishes), so the countdown stays fresh without polling.

Install

Requires jq (brew install jq on macOS).

Option 1 — npx (recommended)

npx @robertoecf/claude-code-statusbar

Installs the script to ~/.claude/statusline-command.sh and merges the statusLine entry into ~/.claude/settings.json (without clobbering your other settings).

Option 2 — manual

curl -fsSL https://raw.githubusercontent.com/robertoecf/claude-code-statusbar/main/statusline-command.sh \
  -o ~/.claude/statusline-command.sh
chmod +x ~/.claude/statusline-command.sh

Then add to ~/.claude/settings.json:

{
  "statusLine": {
    "type": "command",
    "command": "bash ~/.claude/statusline-command.sh"
  }
}

Restart Claude Code. The statusbar appears at the bottom of the CLI.

Design choices

  • No labels where the metric is obvious. 24% · 2h 33m not session: 24% resets in 2h 33m. Reading it is faster than reading prose.
  • Remaining, not used. 76% = you have 76% left. Consistent with how people actually think about quota.
  • Color follows health, not value. Green = you're fine, red = pay attention. ctx 5% is red because you're low, 5h · 5% is red because you're close to the limit.
  • Middle dot (·) inside a segment, pipe (|) between segments. The pipe marks a hard boundary between unrelated facts (dir vs branch vs model). The dot pairs two facets of the same fact (time-left and quota-left of the same window).
  • Graceful fallbacks. No rate_limits in the JSON (non-subscriber, pre-first-response): segment disappears. resets_at in the past: percent stays, time disappears.
  • Readonly git. Uses --no-optional-locks so the statusline never touches .git/index.lock during reads.

Credits

Rate-limit visualization inspired by the OpenAI Codex CLI statusbar. Data source (stdin JSON per Claude Code's statusline docs).

License

MIT.