Moo Statusline for Claude Code
A beautiful, informative statusline for Claude Code CLI that shows your project, git branch, model, context usage, and real-time rate limit tracking via the Anthropic API.
Codex CLI
For a Codex-oriented copy of the script, see statusline-codex.sh and README-CODEX.md.
Quick run:
chmod +x ./statusline-codex.sh
echo '{"cwd":"'$PWD'","model":"gpt-5.2-codex","info":{"last_token_usage":{"total_tokens":6472},"model_context_window":258400},"rate_limits":{"primary":{"used_percent":24.0,"window_minutes":300,"resets_at":1767958180},"secondary":{"used_percent":3.0,"window_minutes":10080,"resets_at":1768212356}}}' | ./statusline-codex.sh
Live watcher (separate terminal):
chmod +x ./codex-statusline-watch.sh
./codex-statusline-watch.sh
Features
- 🌿 Git Integration - Shows project name and current branch (highlighted in green)
- 🤖 Model Display - Simplified model names with version (e.g., opus 4.6, sonnet 4.5, haiku 4)
- 🧠 Effort Indicator - Shows thinking effort level as dots next to model name (●●• = medium; 5-dot scale on opus 4.7+ and fable for xhigh/max)
- Worktree Detection - In a worktree, shows the parent repo name + branch with 🌿 icons together; appends the folder name (light brown) only when it isn't derivable from the branch
- 📊 Context Tracking - Shows current usage vs auto-compact threshold (e.g.,
⛁ 97k/155k), respects autoCompactWindow setting
- ⚡ Live Rate Limit Data - Real 5-hour usage from Anthropic API with visual progress bar
- ⏰ Smart Reset Timer - Displays next reset time and countdown (e.g.,
↺ 9pm 1h43m)
- 🎨 Color-Coded Warnings - Orange/red alerts when context or rate limits are high
- 💰 Extra Usage Tracking - Shows extra usage progress bar and spend when 5-hour limit is reached
- 📈 Weekly Usage - Optional 7-day usage percentage when available
What It Looks Like

repo 🌿 main | opus 4.6 ●●● | ⛁ 65k/155k | [█░░░░] 5h:24% used ↺9pm 1h43m
When 5-hour limit is reached with extra usage enabled:
repo 🌿 main | opus 4.6 ●●● | [░░░░░] extra:12% used $515.00/$4250 | 5h:100% used ↺3pm.0h14m | w:63%
In a worktree (parent repo name + branch, icons together; the folder is added only when it isn't derivable from the branch):
myrepo 🌿 feature-branch | opus 4.6 ●●• | [█░░░░] 5h:24% used ↺9pm 1h43m
myrepo 🌿 feature-branch scratch-dir | opus 4.6 ●●• | [█░░░░] 5h:24% used ↺9pm 1h43m
Breakdown:
repo 🌿 main - Project name + git branch (branch in green #74BE33); in a worktree the gray name is the parent repo
🌿 branch - In a worktree the branch + worktree icons sit together; the folder name (light brown) is appended only when it isn't derivable from the branch (not a prefix/suffix match), e.g. 🌿 feature-branch scratch-dir
opus 4.6 ●●• - Current model with version and effort level dots
●●● = high (default), ●●• = medium, ●•• = low
- Opus 4.7+ and Fable use a 5-dot scale:
●●●●● = max, ●●●●• = xhigh, ●●●•• = high, ●●••• = medium, ●•••• = low
- Only shown for thinking-capable models (opus/sonnet/fable, not haiku)
- Reads from
/model command, CLAUDE_CODE_EFFORT_LEVEL env var, or alwaysThinkingEnabled setting
⛁ 65k/500k - Current context usage / compact threshold
- With
autoCompactWindow: used directly as threshold (e.g., 65k/500k)
- Without: defaults to
context_window_size - 45K (e.g., 65k/155k)
- Turns orange when <20k remaining, red when <10k
[█░░░░] 5h:24% used - 5-hour rate limit usage from Anthropic API
- Visual bar + percentage
- Gray: <50%, Yellow: 50-79%, Red: ≥80%
- Shows
w:3% if weekly data is available; at ≥50% also shows reset date and countdown (e.g., w:87% ↺ 6mar-midday.3h18m)
- When 5h hits 100% and extra usage is enabled, shows extra usage bar (light orange) with dollar spend
↺9pm 1h43m - Next reset time + countdown
- Icon in dark green (#357500)
- Clean time format:
9pm not 9:00pm
Installation
Plugin Install (Recommended)
# 1. Add the marketplace and install the plugin
/plugin marketplace add https://github.com/moogento/moo-statusline.git
/plugin install moo-statusline@moo-statusline
# 2. Run the setup command
/statusline
# 3. Restart Claude Code
Homebrew (macOS)
# 1. Tap and install
brew tap moogento/moo-statusline
brew install moo-statusline
# 2. Add to your Claude Code settings (~/.claude/settings.json):
{
"statusLine": {
"type": "command",
"command": "bash ~/.claude/statusline.sh"
}
}
# 3. Restart Claude Code
Quick Install
# 1. Download the statusline script
curl -o ~/.claude/statusline.sh https://raw.githubusercontent.com/moogento/moo-statusline/main/statusline.sh
chmod +x ~/.claude/statusline.sh