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

cc-usage-hours

v1.3.0

Published

Analyze Claude Code usage hours from session data

Readme

cc-usage-hours

Analyze Claude Code usage from session data in ~/.claude/projects.

Anthropic announced the new weekly limits with vague assurances about how many hours of usage an 'average user' would get. This tool is designed to help you estimate your usage in 'hours', and figure out how likely you are to run into limits.

To that end, it computes 3 different ways of measuring your usage in 'hours':

Metrics

  • Hours with Activity: Hours in which you used Claude Code at least once
  • Active Conversation Time: Duration of time during which you were interacting with Claude Code
  • Parallel Session Total: Sum of durations of all sessions, accounting somewhat for parallel usage.

Note that the parallel session total seems lower than expected, and so is probably only accounting for parallel sessions, not fully accounting for subagents.

Install

npm install -g cc-usage-hours

Or run directly via npx

npx cc-usage-hours

Usage

cc-usage-hours                # Auto-detect subscription
cc-usage-hours -s pro         # Specify subscription
cc-usage-hours -t active      # Use active time metric for limits
cc-usage-hours -w             # Show weekly breakdown
cc-usage-hours -m             # Show model breakdown
cc-usage-hours -m opus        # Show only Opus usage

Options

  • -g, --gap <minutes> - Inactivity before new session (default: 5)
  • -s, --subscription - Subscription: pro, max5x, max20x (default: auto)
  • -t, --metric <type> - Limit comparison: hours, active, parallel (default: parallel)
  • -w, --weekly - Show weekly breakdown
  • -m, --models [type] - Show model usage (optional: opus/sonnet)
  • -d, --detailed - Show all details

Requirements

  • Node.js >= 14.0.0
  • Claude Code with session data in ~/.claude/projects

License

CC0 1.0 Universal - Public Domain Dedication