A native macOS menu bar application that monitors your Claude Code spending in real-time, providing intuitive visual feedback and detailed breakdowns. Inspired by ccusage.
Claude Nein lives in your macOS menu bar, keeping you constantly updated on your Claude Code API usage costs. It automatically discovers your Claude project log files, parses them efficiently, and presents a clear summary of your spending.
- Visit the Releases page and download the
ClaudeNein-<version>-unsigned.zipasset from the latest release. - Unzip the archive and move
ClaudeNein.appto your/Applicationsfolder. - Reset the quarantine flag on the app:
xattr -d com.apple.quarantine /Applications/ClaudeNein.app - Open the app. On first run, the app will ask you for access to the Claude directories.
- Real-Time Menu Bar Display – today's spend appears in the menu bar and animates smoothly when the value changes.
- Detailed Spend Summaries – the dropdown menu shows totals for today, this week and this month.
- Model‑Specific Costs – see which models account for the most spend.
- Automatic & Efficient Monitoring – uses FSEvents to watch Claude log files with minimal overhead.
- Persistent Data Storage – usage is cached locally in Core Data so data survives restarts.
- Run at Startup Option – enable automatic launch when you log in.
- Database Management – built in "Reload Database" command clears and reloads cached usage.
- Spend Graphs – interactive graph view showing spending trends by day, month, or year with navigation controls and switchable plot types (bar and cumulative).
- Secure & Private – all processing happens on your Mac; the only network request fetches pricing information.
- Claude Directory Access Control – you explicitly grant and revoke access only to the Claude log directories.
- Up‑to‑Date Pricing – pricing data is pulled from LiteLLM with cached and bundled fallbacks, and the current data source is displayed in the menu.
- Comprehensive Logging – centralized logging system for debugging and monitoring app behavior.
- Permissions – on first launch you grant read‑only access to the
~/.claudeand~/.config/claudedirectories via a clear Yes/No dialog. - File Monitoring – the app searches
~/.claude/projectsand~/.config/claude/projectsfor.jsonllogs and monitors them with FSEvents. - Parsing – changed files are parsed and deduplicated, extracting model names, timestamps and token counts including cache tokens.
- Data Storage: Parsed usage entries are stored in a local Core Data database with intelligent deduplication to prevent duplicate entries.
- Cost Calculation: Using the latest pricing data, it calculates the cost for each entry and aggregates spending data from the database.
- UI Update: It displays the aggregated costs in the menu bar and detailed dropdown menu, with real-time updates as new data arrives.
- Open
ClaudeNein.xcodeprojin Xcode (15 or later). - Select the ClaudeNein scheme.
- Build and run the project to launch the menu bar app.
- To run the unit tests use
xcodebuild test -scheme ClaudeNein -destination 'platform=macOS'.
- Language: Swift
- Framework: SwiftUI for UI components, AppKit for menu bar integration
- Platform: macOS (menu bar app)
- Data Storage: Core Data for persistent local storage
- Architecture: The app runs as a background agent (
NSStatusItem) managed by a centralMenuBarManagerclass. It uses:FileMonitorfor observing file system changes with FSEventsDataStorefor Core Data persistence and spend calculationsPricingManagerfor fetching and caching model pricing dataHomeDirectoryAccessManagerfor handling secure file access permissionsGraphRendererfor modular graph rendering with multiple plot typesSpendGraphViewfor interactive spending visualization
The app monitors Claude Code .jsonl files located in your Claude configuration directories, for example:
~/.claude/projects/~/.config/claude/projects/
The project is organized as follows:
ClaudeNein/
├── ClaudeNeinApp.swift # Main app entry point with MenuBarManager
├── Models.swift # Data models (UsageEntry, SpendSummary, etc.)
├── DataStore.swift # Core Data persistence layer for usage entries
├── Model.xcdatamodeld/ # Core Data model definition
├── FileMonitor.swift # Monitors the file system for log changes
├── HomeDirectoryAccessManager.swift # Handles permissions for home directory access
├── DirectoryAccessManager.swift # Additional directory access management
├── SpendCalculator.swift # Calculates spend totals and breakdowns
├── PricingManager.swift # Fetches and manages model pricing data
├── JSONLParser.swift # Parses `.jsonl` log files
├── LiteLLMParser.swift # Parses pricing data from LiteLLM source
├── LaunchAtLoginManager.swift # Manages launch at login functionality
├── SpendGraphView.swift # SwiftUI view for spending graphs
├── GraphRenderer.swift # Modular graph rendering system
├── AboutView.swift # About dialog with app information
├── Logger.swift # Centralized logging system
└── Assets.xcassets/ # App icons and assets
Claude Nein is designed with privacy as a priority:
- Local Processing: All log file parsing and calculations happen on your Mac.
- Local Data Storage: Usage data is stored locally in a Core Data database on your machine.
- No Data Transmission: No usage data or personal information is ever sent to any external server.
- Limited Permissions: The app only requests the read-only permissions necessary to access Claude's log files.
- Transparent Pricing Updates: The only network request made is to the public LiteLLM GitHub repository to fetch
model_prices_and_context_window.json.
Contributions are welcome! Please feel free to open an issue or submit a pull request.
This is an unofficial, third-party application and is not affiliated with, authorized, or endorsed by Anthropic. Use at your own risk.

