Welcome to Claude Code!
You're about to discover the most powerful AI coding assistant available today. Claude Code isn't just another autocomplete toolβit's a full-fledged AI pair programmer that can understand your entire codebase, write complex features, debug issues, and even help with non-coding tasks like data analysis and documentation.
π New in Claude Code 2.0!
Huge updates just released! Check out what's new:
- π» VS Code Extension - Native IDE integration (finally!)
- π /rewind - Undo and explore different approaches
- β¨οΈ Keyboard Shortcuts - Tab for thinking, Ctrl+R for history
- π @-mentions - Quick file references with autocomplete
- π― Claude Skills - PDF, Excel, and more
- π€ Haiku 4.5 - 5x faster, 1/3 the cost
- π Web Search & Fetch - Access current info from the web
- πΎ Memory Tool - Persistent context across sessions
- π 1M Token Context - Analyze entire codebases (beta)
Getting Started
Getting Better
Advanced
What Makes Claude Code Different?
Understands Context
Claude Code can read and understand your entire codebase, not just the current file
Autonomous Actions
Can read, write, edit files, run commands, and search your codebase without constant prompting
Real Tools
Uses actual file operations, git commands, and shell accessβnot just text generation
Task-Oriented
Breaks down complex tasks, creates plans, and executes them step by step
Extensible
Connect to external services via MCP, customize with hooks, and create slash commands
Beyond Coding
Data analysis, report generation, documentation, and more
Your Learning Path
Phase 1: Getting Started (30 minutes)
Learn the basics: how to communicate with Claude Code, your first tasks, understanding the interface, and basic workflows.
Click to start β
Phase 2: Getting Better (1-2 hours)
Deep dive into tools, file operations, codebase understanding, and common development workflows.
Click to continue β
Phase 3: Advanced (Ongoing)
MCPs, hooks, custom commands, automation, and advanced integration patterns.
Click to explore β
β Your First Day with Claude Code
Complete these tasks to build a solid foundation. Your progress is automatically saved!
πΊ Watch & Learn
Official Learning Resources:
- Claude Code in Action (Interactive Course) - Comprehensive hands-on course from Anthropic
- Anthropic YouTube Channel - Official videos and conference talks
- Code with Claude 2025 Conference Videos - Developer conference recordings
- DeepLearning.AI Course - Claude Code fundamentals with Anthropic's team
What's New in Claude Code 2.0
Claude Code 2.0 brings a completely redesigned experience with native IDE integration, powerful workflow commands, enhanced keyboard shortcuts, and intelligent new features that make you even more productive.
π Major New Features
π» Native VS Code Extension
The #1 requested feature is here!
Claude Code now runs natively inside Visual Studio Code, bringing AI pair programming directly into your favorite editor.
Key Benefits:
- Seamless Integration: No more switching between terminal and editor
- Visual Diffs: See changes side-by-side with syntax highlighting
- Context Awareness: Claude knows your current file and selection
- One-Click Actions: Accept or reject changes with a single click
- Conversation History: Access past sessions right in VS Code
Getting Started with VS Code Extension
β‘ Powerful Workflow Commands
New commands that supercharge your development workflow:
π /rewind
Undo code changes and go back in conversation history
π /usage
Track your usage and plan limits in real-time
π€ /export
Export conversations to share with your team
π /statusline
Customize your prompt with custom status information
π /context
Debug context issues and see what Claude knows
π /memory
Manage persistent memory across sessions
β¨οΈ Keyboard Shortcuts
Master these shortcuts to work faster than ever:
Tab
Enable extended reasoning (sticky across sessions)
Ctrl+R
Search previous commands like bash/zsh
Ctrl+B
Run bash commands in background (dev servers, logs)
Ctrl+O
View full conversation transcript
Ctrl+G
Open prompt in your system text editor
Shift+Tab
Switch modes on Windows native install
π @-mentions for Quick References
Quickly reference files and directories in your prompts with @-mentions:
Using @-mentions
π― Claude Skills
Extend Claude Code with specialized skills for specific tasks:
π PDF Skill
Extract text, create PDFs, merge documents, handle forms
π Excel Skill
Read, write, and manipulate spreadsheet data
π¨ Canvas Design
Create visual designs and artwork programmatically
π§ Custom Skills
Build your own skills for specialized workflows
Using Skills
π€ Enhanced Models & Subagents
Haiku 4.5 - Fast & Cost-Effective
The newest addition to the Claude family is now available in Claude Code:
- 4-5x faster than Sonnet 4.5
- 73.3% on SWE-bench Verified - Sonnet 4-level coding at 1/3 the cost
- Perfect for: High-volume tasks, real-time applications, cost-sensitive workloads
- 200K context window (1M on Developer Platform)
SonnetPlan Mode
Get the best of both worlds with automatic model selection:
- Uses Sonnet 4.5 for planning (complex reasoning)
- Uses Haiku 4.5 for execution (fast, cost-effective implementation)
- Automatically enabled when you select Haiku 4.5
Enhanced Subagents
- Plan Subagent: Dedicated agent for creating detailed implementation plans
- Explore Subagent (Haiku-powered): Efficiently searches your codebase to save context
- Resumable Subagents: Claude can now resume and continue previous subagent sessions
- Dynamic Model Selection: Claude chooses the right model for each subagent task
β Interactive Question Tool
Claude can now ask you questions to clarify requirements and gather information:
How It Works
You: "Add authentication to the app"
Claude: "Which authentication method would you prefer?"
- OAuth 2.0 with social providers (Google, GitHub)
- JWT with email/password
- Magic link authentication
- Other (specify)
You select an option, and Claude proceeds with clarity!
π Web Search & Web Fetch
Released: May 7 & September 10, 2025
Claude Code now has built-in web access for current information:
Web Search
- Access current information - Get real-time data, news, and updates
- Research capabilities - Search the web for technical documentation, articles, and more
- Domain filtering - Include or block specific websites in search results
Web Fetch
- Retrieve full page content - Fetch complete web pages and PDFs from URLs
- Process web documents - Extract and analyze content from online sources
Using Web Features
πΎ Memory Tool - Persistent Context
Released: September 29, 2025
Claude can now remember information across conversations and sessions:
- Persistent memory - Store preferences, project context, and team conventions
- Cross-session recall - Information persists even when you restart Claude Code
- Manage with /memory - Edit and review what Claude remembers
- Automatic learning - Claude learns from your corrections and preferences
How Memory Works
π§ Advanced Context Management
Context Editing (September 29, 2025)
Claude now automatically manages conversation context for optimal performance:
- Automatic optimization - Claude removes unnecessary thinking blocks and old context
- Smarter context window use - Keep conversations going longer without hitting limits
- Seamless experience - Happens automatically in the background
Files API (May 22, 2025)
Upload and work with files more efficiently:
- Direct file uploads - Share files for analysis, processing, or reference
- Code execution context - Files available during code execution
- Multi-file operations - Work with multiple documents simultaneously
Interleaved Thinking (May 22, 2025)
Claude can now think between tool calls for better decision-making:
- Reasoning during execution - Think and adjust strategy as work progresses
- Better tool selection - Choose the right tools based on intermediate results
- Adaptive workflows - Adjust approach based on what's discovered
π 1M Token Context Window (Beta)
Released: August 12, 2025
Sonnet 4.5 now supports up to 1 million tokens of context in beta:
- Massive codebase support - Analyze entire repositories at once
- Long conversation threads - Work on complex projects without losing context
- Extended documentation - Include full API docs and specifications
- Beta access - Enable via API header on supported platforms
π Upgrading from 1.0
Already using Claude Code? Here's what you need to know:
- β
Automatic update: Run
npm install -g @anthropic-ai/claude-code@latest - β No breaking changes: All your existing workflows, hooks, and MCPs work as before
- β VS Code extension: Install separately for IDE experience
- β Settings preserved: Your configuration carries over automatically
π Learn More
How to Install Claude Code
Choose how you want to use Claude Code. The VS Code extension is the easiest way to get started!
π VS Code Extension (Recommended)
Why Choose VS Code Extension?
- β¨ Easiest to install - Works in seconds
- π» Native IDE integration - No terminal switching
- ποΈ Visual diffs - See changes side-by-side
- β‘ One-click actions - Accept/reject with a button
- π Conversation history - Built into VS Code
Step 1: Prerequisites
- Visual Studio Code installed (Download here)
- An Anthropic API key, Claude Pro, or Claude Max subscription
Step 2: Install the Extension
Option A: Install from VS Code
- Open VS Code
- Click the Extensions icon (or press
Cmd+Shift+X/Ctrl+Shift+X) - Search for "Claude Code"
- Click Install on the official Anthropic extension
Option B: Install via Command Line
code --install-extension anthropic.claude-code
Step 3: Get Your API Key (If Needed)
If you're using Anthropic API:
- Visit console.anthropic.com
- Sign in or create an account
- Navigate to "API Keys" in settings
- Click "Create Key" and copy it
If you have Claude Pro or Claude Max, you can sign in directly!
Step 4: Configure Authentication
When you first open the extension:
- Look for the Claude icon in your VS Code sidebar
- Click it to open Claude Code
- Follow the prompts to sign in or enter your API key
- Choose your preferred model (Sonnet 4.5 recommended)
Step 5: Start Using Claude Code!
- "Help me understand this project"
- "Add error handling to this function"
- "Refactor this code to be more readable"
Quick Tips:
- Right-click any file to ask Claude about it
- Select code and ask Claude to explain or improve it
- Use
Cmd+K/Ctrl+Kfor quick inline edits
Direct Install via Anthropic API
Step 1: Check Prerequisites
Ensure you have the following installed:
- Node.js version 18.0.0 or higher
- npm or yarn package manager
- An active Anthropic API account
Check your Node.js version:
node --version
Step 2: Get Your API Key
- Visit console.anthropic.com
- Sign in or create an account
- Navigate to "API Keys" in the settings
- Click "Create Key" and copy your new API key
- Store it securely - you'll need it in the next step
Step 3: Install Claude Code
Install globally using npm:
npm install -g @anthropic-ai/claude-code
Or using yarn:
yarn global add @anthropic-ai/claude-code
Step 4: Configure Your API Key
Set your API key as an environment variable:
On macOS/Linux:
export ANTHROPIC_API_KEY='your-api-key-here'
On Windows (PowerShell):
$env:ANTHROPIC_API_KEY='your-api-key-here'
Make it permanent (add to ~/.zshrc or ~/.bashrc):
echo 'export ANTHROPIC_API_KEY="your-api-key-here"' >> ~/.zshrc
Step 5: Verify Installation
Run Claude Code to verify everything is set up correctly:
claude --version
Start your first session:
claude
β You're ready to go! Claude Code should now be running.
Install via Google Vertex AI
Step 1: Check Prerequisites
- Node.js version 18.0.0 or higher
- npm or yarn package manager
- A Google Cloud Platform account with billing enabled
- gcloud CLI installed and configured
Step 2: Set Up Google Cloud Project
Create or select a GCP project:
gcloud projects create YOUR_PROJECT_ID
Set the project as default:
gcloud config set project YOUR_PROJECT_ID
Enable required APIs:
gcloud services enable aiplatform.googleapis.com
Step 3: Enable Vertex AI and Claude Access
- Visit the Vertex AI console
- Navigate to Model Garden
- Search for "Claude" models
- Request access to Claude models (if needed)
- Wait for approval (typically within 24 hours)
Step 4: Set Up Authentication
Create a service account:
gcloud iam service-accounts create claude-code-sa \
--display-name="Claude Code Service Account"
Grant necessary permissions:
gcloud projects add-iam-policy-binding YOUR_PROJECT_ID \
--member="serviceAccount:claude-code-sa@YOUR_PROJECT_ID.iam.gserviceaccount.com" \
--role="roles/aiplatform.user"
Create and download credentials:
gcloud iam service-accounts keys create ~/claude-key.json \
--iam-account=claude-code-sa@YOUR_PROJECT_ID.iam.gserviceaccount.com
Step 5: Install Claude Code
npm install -g @anthropic-ai/claude-code
Step 6: Configure Claude Code for Vertex AI
Set environment variables:
export GOOGLE_APPLICATION_CREDENTIALS="$HOME/claude-key.json"
export ANTHROPIC_VERTEX_PROJECT_ID="YOUR_PROJECT_ID"
export ANTHROPIC_VERTEX_REGION="us-central1"
Start Claude Code with Vertex AI:
claude --provider vertex
β Claude Code is now running via Google Vertex AI!
Step 7: Enable Telemetry (Optional but Recommended)
Enable telemetry to help Anthropic improve Claude Code and provide better support. This is particularly useful for enterprise deployments to track usage and performance.
Set telemetry environment variables:
export CLAUDE_TELEMETRY_ENABLED=true
export CLAUDE_TELEMETRY_ENDPOINT="your-org-telemetry-endpoint"
Configure telemetry in your .claude.json file:
{
"telemetry": {
"enabled": true,
"endpoint": "your-org-telemetry-endpoint",
"includeUsageMetrics": true,
"includePerformanceMetrics": true
}
}
Verify telemetry is enabled:
claude --show-config
Note:
Telemetry data is anonymized and helps improve Claude Code's performance, especially for Vertex AI deployments. No code content is transmitted, only usage patterns and performance metrics.
Additional Resources
Install via AWS Bedrock
Step 1: Check Prerequisites
- Node.js version 18.0.0 or higher
- npm or yarn package manager
- An AWS account with Bedrock access
- AWS CLI installed and configured
Step 2: Enable AWS Bedrock
Sign in to the AWS Console and:
- Navigate to AWS Bedrock service
- Select a supported region (us-east-1, us-west-2, etc.)
- Go to "Model access" in the left sidebar
- Request access to Claude models (Sonnet, Opus, Haiku)
- Wait for approval (typically instant or within minutes)
Step 3: Configure AWS Credentials
Set up AWS CLI credentials (if not already configured):
aws configure
You'll be prompted to enter:
- AWS Access Key ID
- AWS Secret Access Key
- Default region (e.g., us-east-1)
- Output format (json recommended)
Step 4: Set Up IAM Permissions
Ensure your IAM user/role has these permissions:
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"bedrock:InvokeModel",
"bedrock:InvokeModelWithResponseStream"
],
"Resource": "arn:aws:bedrock:*::foundation-model/anthropic.claude*"
}
]
}
Step 5: Install Claude Code
npm install -g @anthropic-ai/claude-code
Step 6: Configure Claude Code for Bedrock
Set your AWS region (if different from default):
export AWS_REGION="us-east-1"
Start Claude Code with Bedrock:
claude --provider bedrock
Or specify region directly:
claude --provider bedrock --region us-west-2
β Claude Code is now running via AWS Bedrock!
Additional Resources
Quick Tips
- Need help? Run
claude --helpfor all available commands - Update Claude Code: Run
npm update -g @anthropic-ai/claude-code - Switch providers: Use the
--providerflag when starting Claude - Troubleshooting? Check the Troubleshooting tab for common issues
Phase 1: Getting Started
Your First Conversation
Claude Code works through natural conversation. Simply type your request and Claude will break it down, create a plan, and execute it.
Example: Your First Task
You: "Can you help me understand what this project does?"
Example: Making Changes
You: "Add error handling to the login function"
β οΈ Common Mistake: Being Too Vague
β Less Effective: "Fix the code"
β
More Effective: "Add input validation to the email field in the registration form"
Why: Specific requests help Claude understand exactly what you need and provide better results faster.
Understanding the Interface
How Claude Communicates
- Text responses: Claude explains what it's doing and shares findings
- Tool usage: You'll see when Claude reads files, edits code, or runs commands
- Code blocks: Changes are shown clearly with syntax highlighting
- Thinking process: Claude shows its reasoning as it works
claude command, and you'll have a conversation-based interface where you can ask questions, request changes, and get work done.
Basic Commands & Workflows
Essential Commands
Productivity Shortcuts (New in 2.0!)
π‘ Pro Tip: Learn these shortcuts early - they'll save you tons of time!
@-mentions for Quick File References
Speed Up Your Workflow
Why it's awesome: Gives Claude immediate file context without waiting for searches!
Your First Real Tasks
Task 1: Explore a Codebase
Task 2: Fix a Bug
Task 3: Add a Feature
Task 4: Refactor Code
π‘ Pro Tip: Give Claude Time to Understand
Don't immediately jump into making changes. Let Claude read and analyze your codebase first.
β
Try this: "Help me understand this project before we make changes"
This helps Claude provide better context-aware suggestions and avoid misunderstandings.
How Claude Code Works: The Tools
Claude has access to several powerful tools that let it interact with your codebase:
π Read
Read any file in your project. Claude can read code, configs, docs, even images and PDFs.
βοΈ Edit
Make precise changes to files. Claude shows you exactly what's being changed.
π Write
Create new files. Usually Claude prefers to edit existing files when possible.
π Glob
Find files by pattern. Quick pattern matching for locating files.
π Grep
Search file contents. Find code patterns, function definitions, specific text.
βοΈ Bash
Run terminal commands. Git, npm, build tools, testsβanything you can run in terminal.
β οΈ Common Mistake: Not Reviewing Changes
Claude shows you all changes before they're applied. Always review them!
β Best practice: Read the changes carefully, ask questions if anything is unclear, then confirm.
You can always undo changes with git if something doesn't look right: git restore <file>
Best Practices for Beginners
β Be Clear and Specific
Good: "Add input validation to the email field in the registration form"
Less good: "Fix the form"
β Let Claude Explore First
Claude can read and understand your codebase. Let it explore before making changes.
β Review Changes
Claude shows you all changes. Review them before committing.
β Ask Questions
"Why did you make this change?" or "What does this function do?" - Claude loves explaining!
β Iterate and Refine
If something isn't quite right, just say so. "Can you make this more efficient?" or "Add comments to explain this logic"
π‘ Pro Tip: Don't Expect Instant Perfection
Claude is powerful but may need iteration. This is normal and expected!
β Try this:
β’ "Can you make this more efficient?"
β’ "Add comments to explain this logic"
β’ "Let's try a different approach"
Iteration leads to better results than trying to get everything perfect in one shot.
β οΈ Common Mistake: Information Overload
Don't try to give Claude your entire codebase context in one message.
β Better: Let Claude explore naturally through the conversation, then provide specific context when needed.
Claude can read files and search your codebaseβtrust it to find what it needs!
Phase 2: Getting Better
Mastering File Operations
Reading Files Strategically
Understanding Project Structure
You: "Show me all the React components in this project"
Finding Specific Code
You: "Where is the database connection configured?"
Making Complex Edits
Refactoring Across Multiple Files
You: "Rename the 'getUserData' function to 'fetchUserProfile' everywhere"
Working with Git
Creating Commits
You: "Commit these changes with a good message"
Creating Pull Requests
You: "Create a pull request for this feature"
Powerful Workflow Commands (2.0 Features)
Master these game-changing commands introduced in Claude Code 2.0:
π /rewind
Undo and explore alternatives
Perfect when you want to try a different approach or step back through changes. Like git reset but for your conversation!
π /usage
Monitor your token usage
Track tokens consumed, estimated costs, and your plan limits in real-time. Great for staying within budget!
π€ /export
Share conversations
Export full conversation history to share solutions with your team or document your work.
π /context
Debug context usage
See exactly what's in Claude's context window and optimize your token usage.
π /memory
Manage persistent memory
Edit what Claude remembers across sessions. Perfect for project-specific conventions!
π /statusline
Customize your prompt
Add git branch, timestamp, or custom info to your terminal prompt.
Real-World Workflow Example
π‘ Pro Workflow Tips
- /rewind + experiment: Don't be afraid to try different approaches - you can always rewind!
- /context regularly: Check context usage periodically to avoid hitting limits
- /export after breakthroughs: Document successful solutions for future reference
- /memory for conventions: Store coding standards, naming patterns, or project-specific rules
Development Workflows
π Test-Driven Development
π Debugging Workflow
π¦ Dependency Management
ποΈ Code Architecture
Advanced Communication Patterns
Giving Context
Better: Provide Context
Breaking Down Complex Tasks
Complex Feature Request
Iterative Refinement
Refining Output
Initial: "Create a login form"
Refine: "Add form validation"
Refine: "Add a 'Remember Me' checkbox"
Refine: "Add 'Forgot Password' link"
Refine: "Make it mobile responsive"
Advanced Prompting Techniques
Unlock more powerful responses from Claude by using these specialized prompting techniques.
Extended Thinking (Deep Analysis)
β‘ Quick Tip: Press Tab to Enable Thinking!
The easiest way to activate extended thinking is to press Tab in the input. The setting is stickyβit stays enabled until you press Tab again!
When you need Claude to think deeply about complex problems, you can request extended reasoning. Claude will break down the problem step-by-step before providing a solution.
When to use thinking mode:
- Complex architectural decisions
- Debugging difficult issues
- Algorithm design
- Comprehensive code reviews
- Performance optimization analysis
Example: Request Deep Thinking via Prompt
Example: Architecture Decision with Reasoning
Step-by-Step Problem Solving
Requesting Methodical Approach
Comparative Analysis
Example: Comparing Approaches
Plan Mode for Large Tasks
For very large or complex tasks, Claude Code has a "plan mode" that creates a detailed plan before executing. This helps with:
- Multi-file refactoring
- Large feature implementations
- System-wide changes
- Migration projects
How to use: Simply ask Claude to create a plan first, or ask about complex tasks that benefit from planning.
Example: Request Planning
Prompting Best Practices
π― Be Specific About Reasoning
Ask Claude to "show your reasoning" or "explain your thinking" for transparency
π Request Structure
Ask for "step-by-step" or "structured analysis" for organized output
π Request Analysis First
For complex tasks: "Analyze first, then implement" gets better results
βοΈ Ask for Tradeoffs
"What are the pros and cons?" or "What are the tradeoffs?" for balanced decisions
π¨ Specify Constraints
Mention team size, expertise, timeline, or other constraints for realistic solutions
π Encourage Iteration
"Let's refine this..." or "What if we tried..." for collaborative problem-solving
Understanding Claude's Capabilities
π Multi-file Understanding
Claude can understand relationships between files, trace imports, and see how components interact.
π Context Awareness
Claude remembers the conversation. Reference previous changes or discussions naturally.
π― Pattern Recognition
Claude learns your coding patterns and can apply them consistently across your project.
π§ͺ Testing
Claude can write, run, and debug tests for your code automatically.
π Documentation
Generate docs, add comments, create README filesβClaude understands documentation best practices.
π Code Review
Ask Claude to review code for bugs, performance issues, security concerns, or best practices.
Real-World Workflow Examples
Morning Workflow: Catch Up on Changes
Feature Development Workflow
Bug Fix Workflow
πΊ Advanced Learning
Deep Dive Resources:
- Claude Code Best Practices - Official engineering blog post
- Interactive Video Course - Comprehensive hands-on training
- Official Tutorials - Step-by-step guides
Phase 3: Advanced
Model Context Protocol (MCP)
MCPs allow Claude Code to connect to external services and data sources, dramatically expanding its capabilities.
What is MCP?
MCP is a protocol that lets Claude Code interact with external systems like databases, APIs, cloud services, and more. Think of it as giving Claude superpowers to access data and services beyond your local filesystem.
Popular MCP Servers
ποΈ Database MCPs
PostgreSQL, MySQL, MongoDB, SQLite
Use case: Query databases, analyze data, run migrations
βοΈ Cloud Provider MCPs
AWS, Google Cloud, Azure
Use case: Manage cloud resources, deploy applications, monitor services
π Data Source MCPs
Google Drive, Notion, Airtable
Use case: Access documents, sync data, generate reports
π§ Development Tool MCPs
GitHub, GitLab, Jira, Linear
Use case: Manage issues, review PRs, track projects
π API MCPs
REST APIs, GraphQL endpoints
Use case: Integrate with third-party services
π Analytics MCPs
Google Analytics, Mixpanel, custom metrics
Use case: Analyze usage, generate insights, create dashboards
Setting Up an MCP Server
Example: PostgreSQL MCP
Example: Google Drive MCP
π― Real-World MCP Use Cases
- Data Analysis: "Compare sales data from our PostgreSQL database with the projections in Google Sheets"
- DevOps: "Check the status of all our AWS EC2 instances and alert me if any are overutilized"
- Project Management: "Show me all high-priority bugs from Jira and create a summary report"
- Documentation: "Pull all our API docs from Notion and generate a unified developer guide"
Hooks: Customizing Claude's Behavior
Hooks let you run shell commands in response to events, allowing you to customize Claude Code's workflow.
Types of Hooks
π― user-prompt-submit-hook
Runs after you submit a message. Perfect for:
- Running linters before Claude edits code
- Checking git status
- Validating environment setup
β‘ tool-call-hook
Runs before specific tool calls. Use to:
- Backup files before edits
- Run formatters after writes
- Validate changes
Setting Up Hooks
Example: Run Prettier After File Edits
Example: Git Status Before Each Prompt
Example: Run Tests Before Commits
Custom Slash Commands
Create custom commands that expand into detailed prompts, perfect for repeated workflows.
Creating Slash Commands
Example: Code Review Command
Example: Documentation Generator
Example: Performance Audit
Powerful Slash Command Ideas
/onboard
Generate comprehensive onboarding docs for new team members
/security-check
Audit code for security vulnerabilities
/deploy-prep
Pre-deployment checklist and verification
/api-test
Generate comprehensive API test suite
/refactor-plan
Create detailed refactoring plan for a module
/dependency-audit
Check for outdated/vulnerable dependencies
Plugins
Plugins allow you to extend Claude Code with custom functionality that can be shared across projects and teams. They can add custom commands, agents, hooks, and MCP servers all in one package.
What Are Plugins?
Think of plugins as pre-packaged extensions that bundle together:
- Custom Commands: Slash commands for specific workflows
- Agents: Specialized AI agents for particular tasks
- Hooks: Automated event handlers
- MCP Servers: Connections to external tools and services
Plugins make it easy to share best practices and tooling across your entire team or organization.
Plugin Structure
Basic Plugin Layout
Plugin Manifest (plugin.json)
Installing Plugins
Method 1: Interactive Menu (Recommended)
Method 2: Direct Installation
Creating Your First Plugin
Step-by-Step Plugin Creation
Real-World Plugin Examples
π Code Review Plugin
Includes:
- /review command
- Pre-commit hook for linting
- Code reviewer agent
π Deployment Plugin
Includes:
- /deploy command
- Pre-deploy checklist
- Deployment agent
- Cloud provider MCP
π§ͺ Testing Plugin
Includes:
- /test command
- Test generator agent
- Post-commit test hook
π Analytics Plugin
Includes:
- /report command
- Database MCP server
- Analytics agent
Team Plugin Workflows
Organization-Wide Plugin Distribution
Plugin Best Practices
π Document Everything
Include a README.md explaining what your plugin does and how to use it
π’ Version Properly
Use semantic versioning (1.0.0) so teams know when updates are breaking
π§ͺ Test Components
Test each command, agent, and hook individually before packaging
π¦ Keep It Focused
Each plugin should solve one problem well, not everything
π Security Review
Review all code in plugins, especially those from third parties
π Update Regularly
Keep plugins updated with latest Claude Code features
π Learn More About Plugins
For detailed technical documentation, see:
- Plugins Guide - Complete documentation
- Plugins Reference - API and configuration reference
Advanced Workflows
π Automated Code Migration
π― Multi-Repository Operations
π Automated Reporting
ποΈ Project Scaffolding
Power User Tips
Create a
.claude/CLAUDE.md file with project-specific instructions that Claude will always follow. Perfect for coding standards, architectural decisions, and team preferences.
"Use our PostgreSQL MCP to analyze user behavior, then update the dashboard components to display the insights." - Claude can chain operations seamlessly.
For complex tasks, Claude can spawn sub-agents to work in parallel. "Research the best approach for implementing real-time notifications while I continue working on the auth system."
"Apply this refactoring pattern to all files in the /services directory" - Claude can handle bulk operations efficiently.
"Look at how we implemented caching in the user service, then apply the same pattern to the product service" - Claude learns from your codebase.
Real-World Use Cases
ποΈ Software Development Use Cases
1. Understanding a New Codebase
Scenario: You've joined a new team and need to understand a large, unfamiliar codebase.
Workflow
Result: Comprehensive understanding in hours instead of weeks.
2. Building a Complete Feature
Scenario: Add a complex new feature from scratch.
Example: Real-Time Chat Feature
Result: Complete, production-ready feature with tests and docs.
3. Debugging Complex Issues
Scenario: Intermittent bug that's hard to reproduce.
Example: Memory Leak Investigation
Result: Root cause identified and fixed with preventive measures.
4. Legacy Code Modernization
Scenario: Modernize old codebase to current standards.
Example: Modernizing a jQuery App
Result: Systematic, safe migration to modern framework.
5. Performance Optimization
Scenario: Application is slow and needs optimization.
Example: React App Performance
Result: Significantly faster application with measurable improvements.
6. API Development
Scenario: Build a complete REST API from scratch.
Example: E-commerce API
Result: Complete API with auth, tests, docs, and error handling.
π Data Analysis Use Cases
7. Data Pipeline Creation
Scenario: Build automated data processing pipeline.
Example: User Analytics Pipeline
Result: Automated daily analytics reporting.
8. Data Cleaning & Transformation
Scenario: Clean messy data from multiple sources.
Example: Merge Customer Data
Result: Clean, normalized data ready for analysis.
9. Exploratory Data Analysis
Scenario: Understand a new dataset.
Example: Sales Data Analysis
Result: Comprehensive analysis with actionable insights.
10. SQL Query Generation & Optimization
Scenario: Complex database queries needed.
Example: Business Intelligence Queries
Result: Optimized queries with performance insights.
π Documentation & Reporting
11. Comprehensive Documentation
Scenario: Project has minimal documentation.
Automated Documentation Generation
Result: Professional, comprehensive documentation suite.
12. Technical Report Generation
Scenario: Need to report on project status to stakeholders.
Executive Summary Creation
Result: Professional report ready for stakeholders.
13. Knowledge Base Creation
Scenario: Create internal documentation from tribal knowledge.
Example: Internal Wiki
Result: Comprehensive onboarding documentation.
π§ͺ Testing & Quality Assurance
14. Test Suite Generation
Scenario: Code has insufficient test coverage.
Comprehensive Testing
Result: Complete test suite with high coverage.
15. Automated Testing Workflow
Scenario: Set up continuous testing.
CI/CD Test Integration
Result: Automated testing pipeline ensuring quality.
π§ DevOps & Infrastructure
16. Docker & Kubernetes Setup
Scenario: Containerize application.
Complete Containerization
Result: Production-ready containerized application.
17. Infrastructure as Code
Scenario: Define infrastructure programmatically.
Terraform Setup
Result: Complete IaC setup for reproducible infrastructure.
π¨ Creative & Non-Traditional Uses
18. Configuration Management
19. Dependency Analysis
20. Code Archaeology
Resources & Learning
π Official Documentation
π₯ Video & Interactive Learning
π Interactive Course
Claude Code in Action
Official Anthropic course with hands-on labs covering architecture, implementation techniques, and MCP integration.
β Self-paced β’ β Certificate available
Start Courseπ DeepLearning.AI
Claude Code: A Highly Agentic Coding Assistant
Free course with Anthropic's Elie Schoppik. Learn fundamentals, context management, and advanced patterns.
β Beginner-friendly β’ β 2-3 hours
Take CourseπΊ YouTube Channel
@anthropic-ai
Latest conference talks, product demos, and technical deep dives from the Anthropic team.
β New content regularly
Subscribe㪠Code with Claude 2025
Anthropic's first developer conference
Watch talks from Anthropic engineers covering:
- Building production agents with MCP
- Advanced Claude Code workflows
- Real-world implementation patterns
- Tool use & API best practices
π Documentation
Official Claude Code Docs
Complete reference covering installation, configuration, tools, MCPs, hooks, and troubleshooting.
β Searchable β’ β Code examples
Browse Docsβ‘ Best Practices
Engineering Blog Post
Tips and tricks from Anthropic engineers for using Claude Code across different codebases and languages.
β Real examples β’ β 10 min read
Read Postπ Essential Reading for Teams
Scaling Agentic Coding Across Your Organization
Comprehensive guide from Anthropic covering:
- Change management strategies for AI adoption
- Security and governance considerations
- Measuring ROI and productivity gains
- Best practices from enterprise deployments
Perfect for engineering leaders, CTOs, and team leads
Download Free PDF Guideπ§ MCP Servers
π‘ Example Projects
Starter Templates
- React + TypeScript: Modern React app with best practices
- Node.js API: REST API with Express and PostgreSQL
- Python Data Science: Jupyter notebooks with pandas and visualization
- Fullstack Next.js: Complete Next.js app with authentication
Ask Claude: "Create a [template name] project with all best practices"
Example Workflows
- Daily Standup Automation: Generate standup notes from git commits
- Code Review Checklist: Automated code review based on team standards
- Performance Dashboard: Track and visualize app performance metrics
- Documentation Generator: Auto-generate docs from code
π― Quick Reference
Common Commands
File Locations
Useful Prompts
"Explain how this codebase works""Find and fix this bug: [description]""Refactor [function/module] to be more efficient""Add comprehensive tests for [feature]""Generate documentation for this project""Review my changes and suggest improvements""Help me debug why [issue] is happening"
π€ Community & Support
π Recommended Reading
Anthropic Blog Posts
External Resources
- Prompt Engineering Guide: Learn effective prompting techniques
- AI-Assisted Development: Patterns and practices
- Code Quality with AI: Maintaining standards
π§ Troubleshooting & FAQ
Running into issues? You're not alone! Here are solutions to the most common problems users encounter.
π Getting Started Issues
β Claude won't start / "Command not found"
Problem: When I type claude, I get "command not found"
Solutions:
- Verify installation:
which claude - Reinstall:
npm install -g @anthropic-ai/claude-code - Check your PATH environment variable
- Try with npx:
npx @anthropic-ai/claude-code - Restart your terminal after installation
π API Key / Authentication Issues
Problem: "Authentication failed" or "Invalid API key"
Solutions:
- Verify key is set:
echo $ANTHROPIC_API_KEY - Set key:
export ANTHROPIC_API_KEY=your-key - Add to your shell profile (~/.zshrc or ~/.bashrc) to make it permanent
- Check key is valid in Anthropic Console
- Regenerate key if needed
π Permission Errors
Problem: "Permission denied" when reading/writing files
Solutions:
- Check file permissions:
ls -la filename - Make sure you're running Claude Code from the correct directory
- Check that .gitignore isn't blocking the files
- Verify you have write access to the project directory
- Don't use sudo unless absolutely necessary (not recommended)
π¬ Usage Issues
π€ Claude Isn't Responding
Problem: Claude started but isn't responding to my messages
Solutions:
- Check your internet connection
- Verify you haven't hit API rate limits
- Try
/clearto reset the conversation - Restart Claude Code completely
- Check Anthropic status page
- Look for error messages in your terminal
π Claude Made a Mistake
Problem: The code Claude wrote has bugs or isn't what I wanted
Solutions:
- Be more specific in your request and provide more context
- Ask Claude to fix it:
"This has a bug in line 42 where..." - Iterate:
"Can you try a different approach?" - Provide examples of what you want
- Undo with git:
git restore <file> - Ask Claude to explain its reasoning:
"Why did you choose this approach?"
β©οΈ How Do I Undo Changes?
Problem: I want to revert Claude's changes
Solutions:
- Single file:
git restore <file> - All changes:
git restore . - Hard reset:
git reset --hard HEAD(careful!) - Pro tip: Always review changes before accepting
- Pro tip: Work in a branch:
git checkout -b feature-name - Pro tip: Commit frequently so you can easily revert
π Performance Is Slow
Problem: Claude is taking a long time to respond
Solutions:
- Large codebases (>100k lines) may be slowerβthis is normal
- Be specific to reduce scope:
"Fix the login function"vs"Fix everything" - Check your internet connection speed
- Try smaller, focused questions
- Use agents for long-running tasks that can work in the background
- Break complex tasks into smaller steps
π Claude Can't Find My Files
Problem: Claude says it can't find a file that exists
Solutions:
- Check the file path is correct:
ls path/to/file - Make sure you're in the right directory:
pwd - Check if the file is in .gitignore (Claude respects .gitignore)
- Try using the full path instead of a relative path
- Ask Claude to search:
"Find all files named X"
βοΈ Configuration Issues
π MCPs Not Working
Problem: My MCP server isn't connecting
Solutions:
- Check ~/.mcp.json formatting (must be valid JSON)
- Verify the MCP server is installed:
npm list -g - Check logs for error messages
- Try a simple test MCP first (like filesystem)
- Restart Claude Code after changing MCP config
- Verify the server path is correct
πͺ Hooks Not Firing
Problem: My hooks aren't running
Solutions:
- Check .claude/config.json syntax (must be valid JSON)
- Verify hook commands work independently in terminal
- Check file permissions on hook scripts:
chmod +x script.sh - Look for error messages in Claude Code output
- Try a simpler hook first to test the system
- Make sure the hook path is absolute or relative to project root
β Custom Commands Not Working
Problem: My custom slash command doesn't show up
Solutions:
- Check command file location:
.claude/commands/commandname.md - Verify file name matches:
/commandnameβcommandname.md - Restart Claude Code after adding new commands
- Check file has content (can't be empty)
- Try
/helpto see if your command is listed
π Plugins Not Working
Problem: My installed plugin isn't working or showing up
Solutions:
- Verify plugin is installed:
/plugin list - Check plugin is enabled:
/plugin enable plugin-name - Restart Claude Code after installing plugins
- Verify plugin marketplace URL is correct:
/plugin marketplace - Check plugin manifest (.claude-plugin/plugin.json) is valid JSON
- Try reinstalling:
/plugin uninstall plugin-namethen reinstall - Check plugin documentation for specific requirements
π€ Common Questions
π° How much does Claude Code cost?
Claude Code uses your Anthropic API key, which is billed based on usage. You can check pricing at anthropic.com/pricing. You only pay for what you use.
π Is my code secure?
Your code is sent to Anthropic's API for processing. Anthropic does not train models on your API data. Review Anthropic's privacy policy for full details.
π Can I use Claude Code offline?
No, Claude Code requires an internet connection to communicate with Anthropic's API. All the AI processing happens in the cloud.
π₯ Can multiple people use Claude Code on the same project?
Yes! Each person needs their own API key. Claude Code works great in team environments. Just make sure to use git branches to avoid conflicts.
π¦ What languages/frameworks does Claude Code support?
Claude Code works with all programming languages and frameworks. It's especially good with popular languages like Python, JavaScript/TypeScript, Java, Go, Rust, and more.
π Claude Code vs claude.ai - What's the difference?
Claude Code: CLI tool integrated with your terminal, has direct file system access, can run commands, optimized for development workflows.
claude.ai: Web interface, great for general conversations and non-coding tasks, requires copy-pasting code.
Use Claude Code for software development, use claude.ai for other tasks.
π Still Stuck?
Can't find your issue? Here's how to get help:
- Search Documentation: Official Claude Code Docs
- Check GitHub Issues: Known issues and feature requests
- Ask the Community: Anthropic Discord
- Contact Support: Anthropic Support
When asking for help, include:
- The exact error message (copy the full text)
- What you were trying to do
- Your operating system and version
- Claude Code version:
claude --version - Steps to reproduce the issue