Claude Code First Setup: Complete Beginner Guide
Everything you need to know to start using Claude Code effectively.
You’ve installed Claude Code. Now what? This guide walks you through the first session and essential configuration.
Starting Your First Session
Open your terminal and run:
claude
You’ll see an interactive prompt. Type your first message:
Hello! What can you help me with?
Claude will explain its capabilities. Try something practical:
List all files in the current directory
Understanding the Interface
The Claude Code interface has several parts:
┌─────────────────────────────────────────────┐
│ Claude Code [tokens: 5k] │ ← Status bar
├─────────────────────────────────────────────┤
│ │
│ [Your conversation appears here] │ ← Conversation area
│ │
├─────────────────────────────────────────────┤
│ > │ ← Input prompt
└─────────────────────────────────────────────┘
The status bar shows:
- Token usage
- Current model
- Session info
First-Time Permissions
Claude Code asks permission before:
- Reading files
- Writing files
- Running commands
- Accessing the network
For each request, you’ll see:
Claude wants to: Read file src/index.ts
Allow? (y/n/always)
Options:
y- Allow this one timen- Deny this requestalways- Always allow this type of action
For trusted projects, you can be more permissive. For sensitive code, be more careful.
Essential Slash Commands
Slash commands are shortcuts for common actions:
| Command | What it does |
|---|---|
/help | Show all available commands |
/clear | Clear the conversation |
/compact | Summarize and reduce context |
/model | Switch between models |
/exit | Exit Claude Code |
Try them:
/help
Setting Up Your Project
Navigate to a project directory and start Claude Code there:
cd ~/projects/my-app
claude
Now Claude can see and work with your project files.
Create a CLAUDE.md File
This file tells Claude about your project. Create one:
Create a CLAUDE.md file for this project with basic information
Or manually create CLAUDE.md in your project root:
# My App
## Tech Stack
- React 18
- TypeScript
- Node.js 20
## Commands
- `npm run dev` - Start development server
- `npm run build` - Build for production
- `npm test` - Run tests
## Code Style
- Use functional components
- Prefer named exports
- Follow existing patterns
Claude will read this automatically and follow your guidelines.
Basic Workflows
Read and understand code
Explain what the src/utils/auth.ts file does
Make changes
Add error handling to the login function in src/auth.ts
Run commands
Run the tests and show me any failures
Ask questions
How does the routing work in this app?
Session Management
Named sessions
Start a named session:
claude --session "fixing-login-bug"
Resume a session
claude --resume
List sessions
claude sessions list
Choosing the Right Model
Claude Code supports multiple models:
| Model | Best for |
|---|---|
| Sonnet | General tasks (default) |
| Haiku | Quick, simple tasks |
| Opus | Complex reasoning |
Switch models:
/model haiku
Or:
/model opus
Important Settings
View current settings
claude config show
Common settings to adjust
Theme:
claude config set theme dark
Default model:
claude config set model sonnet
Getting Help
Inside Claude Code:
/help
For documentation:
What are all the things you can do?
Practice Tasks
Try these to get comfortable:
- Explore: “What files are in this project?”
- Read: “Show me the main entry point”
- Explain: “How does [some feature] work?”
- Write: “Add a comment explaining this function”
- Run: “Run the linter and show any issues”
Common Beginner Mistakes
Being too vague
# Too vague
Fix the bug
# Better
Fix the null pointer error in the handleSubmit function in Form.tsx
Not providing context
# Missing context
Update the API
# Better
Update the /users endpoint to return pagination metadata
Forgetting to save work
Claude Code creates git checkpoints, but verify changes are saved:
Show me what files have been modified
Next Steps
Now that you’re set up:
- Create a CLAUDE.md for your project
- Learn keyboard shortcuts
- Try more complex tasks
- Explore slash commands
The more you use it, the more natural it becomes.