[FEATURE] Historical statistics for usage-limit hits (5-hour / weekly)

Open 💬 0 comments Opened Jul 9, 2026 by DavisToliasvili

Preflight Checklist

  • [x] I have searched existing requests and this feature hasn't been requested yet
  • [x] This is a single feature request (not multiple features)

Problem Statement

On subscription plans (Pro/Max), /usage (and the claude.ai usage page) only shows the CURRENT 5-hour window and CURRENT week utilization. There is no way to see how many times I have hit the 5-hour limit or the weekly limit historically.

The events are also not persisted anywhere locally, so they cannot be reconstructed after the fact. Verified on macOS (desktop app + CLI):

  • Session transcripts in ~/.claude/projects/**/*.jsonl contain no limit-reached records
  • Desktop app logs (~/Library/Logs/Claude/) contain no limit-reached records
  • OpenTelemetry export has no limit_reached-style event (only token/cost/api_request metrics)

The "limit reached" banner is UI-only and never written to disk. Without history, it is hard to make an informed decision about upgrading a plan, changing model mix, or restructuring heavy workflows.

Proposed Solution

  1. Persist a timestamped event locally whenever a session (5-hour) or weekly limit is reached, e.g. appended to a JSONL file under ~/.claude/ ({"ts": ..., "scope": "session" | "weekly"}).
  2. Surface simple aggregates in /usage, e.g.:
  • "5-hour limit reached: 4 times in the last 30 days"
  • "Weekly limit reached: 1 time in the last 12 weeks"
  1. Optionally emit an OpenTelemetry event (e.g. limit_reached with a scope attribute) for users who export metrics.

Even just #1 (a machine-readable local log) would be enough — users could compute their own stats.

Alternative Solutions

  • Mining local transcripts/app logs retroactively: verified they contain no limit-hit records, so this is impossible today.
  • Third-party ccusage reconstructs 5-hour blocks and token burn from transcripts, but can only estimate pressure — it cannot report actual cutoff events.
  • Manual tracking (noting each time the banner appears), which is error-prone and easy to forget.

Priority

Medium - Would be very helpful

Feature Category

Other

Use Case Example

  1. I use Claude Code daily and occasionally hit the 5-hour limit mid-work.
  2. At the end of the month I want to decide whether to upgrade to a higher tier or shift heavy tasks to a cheaper model.
  3. With this feature I would open /usage, see "5-hour limit hit N times / weekly limit hit M times over the last month", and make the call based on data instead of gut feeling.

Additional Context

_No response_

View original on GitHub ↗