One command setup
Get started with cc-statusline in three simple steps:Run the installer
Execute the interactive installer:
This command works immediately without any global installation. The
@latest tag ensures you get the newest version.Answer the prompts
The installer will ask two questions:1. Installation location:2. Feature selection:
What just happened?
The installer performed these actions automatically:Generated script
Created an optimized bash script at
.claude/statusline.shUpdated config
Modified
.claude/settings.json to register the statuslineSet permissions
Made the script executable with
chmod +xValidated setup
Checked for jq and provided installation guidance if missing
Preview before restart
Want to see your statusline without restarting Claude Code? Use the preview command:Understanding your statusline
Hereโs what each element means:Line 1: Environment information
๐ Directory display
๐ Directory display
Shows your current working directory with
~ abbreviation:~/my-project- Project in home directory~/code/work/api- Nested project path/usr/local/bin- Absolute paths shown as-is
๐ฟ Git branch
๐ฟ Git branch
Displays the current git branch:
main- Default branchfeature/statusline- Feature branch- Empty if not in a git repository
๐ค Model name
๐ค Model name
Shows which Claude model is active:
Sonnet 4- Claude 4.5 SonnetOpus 3- Claude 3 OpusHaiku 3- Claude 3 Haiku
๐ Claude Code version
๐ Claude Code version
Displays your Claude Code version:
v1.0.85- Release version- Helps track compatibility
๐จ Output style
๐จ Output style
Shows the current output style setting:
default- Standard outputXML- XML-formatted responsesJSON- JSON-formatted responses
Line 2: Context and session tracking
๐ง Context remaining
๐ง Context remaining
Shows how much of your context window is available:
95% [=========-]- Plenty of room50% [=====-----]- Half used10% [=---------]- Almost full (consider starting fresh)
Requires
jq to be installed. Without jq, this feature wonโt display.โ Session timer
โ Session timer
Countdown to when your usage limits reset:
3h 7m until reset at 01:00- Time remaining(37%) [===-------]- Progress bar showing elapsed time- Helps you plan when to start resource-intensive tasks
Line 3: Cost and token analytics
๐ฐ Cost tracking
๐ฐ Cost tracking
Displays your current session costs:
$49.00- Total cost so far($16.55/h)- Burn rate (cost per hour)- Helps you stay within budget
๐ Token statistics
๐ Token statistics
Shows token consumption metrics:
14638846 tok- Total tokens used (input + output)(279900 tpm)- Tokens per minute burn rate- Uses Claude Codeโs native
context_windowdata
As of v1.4.0, token stats are calculated natively from Claude Codeโs JSON input - no ccusage needed!
Common first-time issues
Statusline not showing after restart
Statusline not showing after restart
Problem: Claude Code started but no statusline appears.Solutions:
Missing jq warning
Missing jq warning
Problem: Installer warns that jq is not installed.Impact:After installing jq, re-run the installer:
- No context remaining percentage
- No token statistics
- No session timer
- Basic fallback parser used (less reliable)
- macOS
- Linux
- Windows
Slow execution (> 500ms)
Slow execution (> 500ms)
Problem: Statusline takes a long time to display.Solutions:
-
Check performance:
Look for the execution time in the output.
-
Disable heavy features:
Re-run init and disable session timer (requires external ccusage call):
-
Check for stale processes:
Kill any hanging processes if found.
Colors not working
Colors not working
Problem: Statusline shows without colors or with garbled characters.Causes:
NO_COLORenvironment variable is set- Terminal doesnโt support 256 colors
- Using a non-standard terminal
-
Check NO_COLOR:
If it outputs anything, unset it:
-
Verify terminal color support:
Should be
xterm-256coloror similar.
Next steps
Now that you have cc-statusline running, explore these topics:Configuration
Customize your statusline with advanced options
Features
Learn about all available features in detail
Troubleshooting
Solutions for common issues
Advanced usage
Custom installations and manual configuration