
Cheat Sheet
Every command. What it does. When to use it.
Core Commands
/helpShows all available slash commands and keyboard shortcuts.
Run this first in any new session to see what's available.
/initCreates a CLAUDE.md file in your project with instructions for Claude.
Put your coding standards, project context, and preferred patterns here. Claude reads it every session.
/clearClears the conversation history and starts fresh.
Use this when context gets too long and responses slow down. Your CLAUDE.md persists.
/compactCompresses conversation history to save context window space.
Better than /clear when you want to keep working but free up tokens. Use often on long sessions.
/costShows how much you've spent in the current session.
Check this periodically. A single long session can cost more than you think.
/doctorDiagnoses common issues with your Claude Code setup.
Run this when things feel broken — permissions, auth, or config issues.
/loginAuthenticates your Claude Code CLI with your Anthropic account.
You'll need an API key or Claude Pro/Max subscription.
/logoutLogs you out of the current session.
Use when switching between accounts or API keys.
/memoryOpens your persistent memory file where Claude stores context across sessions.
Review this regularly. Remove outdated info so Claude doesn't hallucinate based on old context.
/reviewAsks Claude to review your code changes (like a PR review).
Run this before committing. It catches bugs, suggests improvements, and checks for security issues.
Bonus Commands
/fastSwitches to a faster, cheaper model for quick tasks.
Perfect for simple edits, formatting, or questions that don't need deep reasoning.
/configOpens the Claude Code configuration file.
Set default model, custom instructions, key bindings, and more here.
/terminal-setupConfigures your terminal for optimal Claude Code experience.
Sets up shell integration, keybindings, and autocomplete.
/vimToggles vim-style keybindings in the Claude Code interface.
If you're a vim user, this makes navigation feel native.
/statusShows current model, session info, and connection status.
Quick way to check which model you're on and how much context is left.
More cheat sheets and frameworks — free, daily.
Built with AI. Obviously.