Mascot Logo
ai-agents-tutorial

Cheat sheet

Claude Code Slash Commands

The slash commands you reach for most, with their aliases. Type / inside a session to see every command.

Context & memory

/clear/reset, /newStart a new conversation with empty context (keeps CLAUDE.md).
/compactSummarize the conversation so far to free context, same session.
/contextVisualize how much of the context window is in use.
/initGenerate a starter CLAUDE.md from your project.
/memoryEdit CLAUDE.md memory files.

Control the session

/helpShow help and the list of available commands.
/modelSwitch the AI model for this session.
/config/settingsOpen settings (theme, model, editor mode…).
/permissions/allowed-toolsManage allow / ask / deny tool rules.
/planEnter plan mode before a large change.
/exit/quitExit the CLI.

Extend & delegate

/agentsCreate and manage subagents.
/mcpManage MCP server connections.
/reviewReview a pull request locally.

Recover & report

/rewindRoll code and conversation back to a checkpoint.
/resume/continueResume or fork an earlier conversation.
/usage/cost, /statsShow session cost and usage stats.
/feedback/bug, /shareReport a bug or send feedback to Anthropic.