Claude Code Usage Monitor is a lightweight widget for Windows that provides real-time tracking of Claude API rate limits in your taskbar. With visual progress indicators for session and weekly usage, it ensures efficient API management while seamlessly integrating with your Windows environment.
Claude Code Usage Monitor is a lightweight widget designed for the Windows taskbar, enabling real-time tracking of Claude API rate limit usage. This tool simplifies the management of API limits by integrating seamlessly into the taskbar, providing a clear visual representation of usage statistics through two distinct progress bars:
- 5h — Displays session usage over a 5-hour rolling window
- 7d — Indicates weekly usage across a 7-day rolling window
Each progress bar reflects the current utilization percentage alongside a countdown until the rate limit resets, ensuring users remain informed of their API consumption.
Key Features
- Real-time Monitoring: Continuously polls every 15 minutes (with adjustable frequency) to update usage statistics and countdowns.
- Automated Mode Detection: Adapts to the Windows system’s dark or light mode settings for optimal visibility.
- Efficient Architecture:
- Reads the Claude OAuth token from
~/.claude/.credentials.json - Sends minimal API requests to the Anthropic Messages API and parses relevant rate limit headers (
anthropic-ratelimit-unified-*). - Renders the widget using Win32 GDI as a child window of the taskbar.
- Reads the Claude OAuth token from
Installation Requirements
- Operating System: Windows 10/11
- Rust toolchain (MSVC target) must be installed. Refer to Rust installation instructions.
- An active Claude Pro/Team subscription with appropriate OAuth credentials, as documented by Claude Code.
Usage Instructions
To start using the widget, run the compiled executable. The widget will appear in your taskbar, allowing immediate access to:
- Refresh the data
- Adjust the Update Frequency
- Exit functionality via an easy-to-navigate context menu.
Project Structure
The repository features a clean architecture, with source code organized into several modules including the main entry point, models for usage data, API polling logic, rendering, and system integration for dark/light mode detection.
Releases
Pre-built executables for Windows are available on the Releases page, enabling users to download and run the application without needing the Rust toolchain.
No comments yet.
Sign in to be the first to comment.