Skip to content

Finesssee/Win-CodexBar

 
 

Repository files navigation

Win-CodexBar - Windows Port of CodexBar

A Windows port of CodexBar - the tiny menu bar app that keeps your AI provider usage limits visible.

This is an unofficial Windows port. The original CodexBar is a macOS Swift app by Peter Steinberger. This port is built with Rust + egui for native Windows support.

Features

  • 22 AI Providers: Codex, Claude, Cursor, Gemini, Copilot, Antigravity, Windsurf, Zai, MiniMax, Kilo, Kiro, Vertex AI, Augment, OpenCode, Kimi, Kimi K2, Amp, Warp, Ollama, OpenRouter, Synthetic, JetBrains
  • System Tray Icon: Dynamic two-bar meter showing session + weekly usage
  • Native Windows UI: Built with egui - no web runtime required
  • Browser Cookie Extraction: Automatic extraction from Chrome, Edge, Brave, Firefox (DPAPI encrypted)
  • CLI Commands: codexbar usage and codexbar cost for scripting
  • Preferences Window: Enable/disable providers, set refresh intervals, manage cookies

Screenshots

Main Window

CodexBar Main Window

Settings

CodexBar Settings

Overview

CodexBar Overview

Getting Started

Quick Start (from source)

# Clone and run — prerequisites are installed automatically
git clone https://github.com/Finesssee/Win-CodexBar.git
cd Win-CodexBar
.\dev.ps1

This will:

  1. Check for Rust and MinGW-w64, install them if missing
  2. Build CodexBar in debug mode
  3. Launch the system tray app

Other options:

.\dev.ps1 -Release         # optimised build
.\dev.ps1 -Verbose         # debug logging
.\dev.ps1 -SkipBuild       # run last build without rebuilding

Download

Download the latest release from GitHub Releases.

  • Primary installable asset: CodexBar-<version>-Setup.exe
  • Optional portable asset: codexbar.exe

Manual Build

Prerequisites: Rust 1.70+ with x86_64-pc-windows-gnu target, MinGW-w64. Install them automatically with:

.\scripts\setup-windows.ps1

Then build:

cd rust
cargo build --release --bins
# Binaries at: target/x86_64-pc-windows-gnu/release/

Usage

GUI (System Tray)

codexbar menubar

CLI

# Check usage for a provider
codexbar usage -p claude
codexbar usage -p codex
codexbar usage -p all

# Check local cost usage (from JSONL logs)
codexbar cost -p codex
codexbar cost -p claude

Providers

Provider Auth Method What's Tracked
Codex OAuth / CLI Session, Weekly, Credits
Claude OAuth / Cookies / CLI Session (5h), Weekly
Cursor Browser Cookies Plan, Usage, Billing
Gemini OAuth (gcloud) Quota
Copilot GitHub Device Flow Usage
Antigravity Local Language Server Usage
Windsurf Local Config Usage
Zai API Token Quota
MiniMax API Usage
Kilo API Key / CLI (kilo login) Credits, Kilo Pass
Kiro CLI Monthly Credits
Vertex AI gcloud OAuth Cost Tracking
Augment Browser Cookies Credits
OpenCode Local Config Usage
Kimi Browser Cookies 5-Hour Rate, Weekly
Kimi K2 API Key Credits
Amp API Token Usage
Warp API Key Credits, Add-ons
Ollama Browser Cookies Usage
OpenRouter API Key Credits, Key Quota
Synthetic API Key Usage
JetBrains API Token Usage

First Run

  1. Run codexbar menubar to start the app
  2. Click Settings in the menu
  3. Go to Providers tab and enable the providers you use
  4. Make sure you're logged into the provider CLIs (e.g., codex, claude, gemini)

Browser Cookie Extraction

Win-CodexBar automatically extracts cookies from:

  • Chrome (DPAPI + AES-256-GCM)
  • Edge (DPAPI + AES-256-GCM)
  • Brave (DPAPI + AES-256-GCM)
  • Firefox (unencrypted SQLite)

For providers that need web authentication (Claude, Cursor, Kimi), cookies are extracted automatically when you're logged into the web interface.

Manual Cookies

If automatic extraction fails, you can add cookies manually:

  1. Go to SettingsCookies tab
  2. Select the provider
  3. Paste the cookie header from browser DevTools (F12 → Network → Request Headers → Cookie)

Differences from macOS Version

Feature macOS Windows
UI Framework SwiftUI egui (Rust)
System Tray NSStatusItem tray-icon crate
Cookie Decryption Keychain DPAPI
Widget WidgetKit Not available
Auto-update Sparkle GitHub Releases + local Setup installer

Privacy

  • No disk scanning: Only reads known config locations and browser cookies
  • On-device only: No data sent to external servers (except provider APIs)
  • Cookies are opt-in: Browser cookie extraction only happens for enabled providers

Credits

License

MIT - Same as original CodexBar


This is an unofficial Windows port. For the official macOS version, visit steipete/CodexBar.

About

Show usage stats for OpenAI Codex and Claude Code, without having to login. But for Window-Native

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages

  • Rust 98.8%
  • Other 1.2%