Your first session
Start a session by running claude in your project directory. From there, a handful of built-in commands guide you through setup:
/initwalks you through creating a CLAUDE.md for your project/agentshelps configure custom subagents/doctordiagnoses common issues with your installation/contextshows what is using space in the context window/modelswitches models mid-session
Claude Code can teach you how to use it — ask questions like "how do I set up hooks?" and it will explain.
# install (macOS / Linux / WSL)curl -fsSL https://claude.ai/install.sh | bash
# start a session in your projectcd ~/work/my-appclaude
# one-shot / scripted usageclaude -p "summarize the failing tests"Check your understanding
Section titled “Check your understanding”Question 1Which command creates a CLAUDE.md for your project interactively?
/init walks you through creating a CLAUDE.md.
Question 2What does /context show?
/context breaks down context window usage.