← Back to Blog

Claude Code: Complete Guide (2026)

Build entire production apps with Claude Code. From agentic loops to deployment — the guide we wish existed when we started.


Claude Code shipped in early 2025. Over a year later, it's the backbone of how we build software at Like One.

Not as a copilot. Not as an autocomplete. As the primary developer — writing production code, running tests, managing deployments, and maintaining a codebase with 619 pages and 62 tests across six Swift packages.

This isn't a feature overview. Anthropic's docs cover that. This is what we learned building a real company on Claude Code — the workflows that compound, the patterns that break, and the configuration that separates a toy experience from a production-grade development environment.

What Claude Code Actually Is (And Isn't)

Claude Code is a terminal-native AI agent that lives in your development environment. It reads your files, runs your commands, edits your code, and executes multi-step tasks autonomously.

What it is NOT:

  • An IDE plugin that suggests completions (that's GitHub Copilot)
  • A chat interface that generates snippets (that's Claude.ai)
  • A code reviewer that comments on PRs (that's a feature, not the product)

Claude Code is an agent. You describe what you want built. It reads your codebase, makes a plan, writes the code, runs the tests, and iterates until it works. You review the result, not the process.

The mental shift matters. Stop thinking "AI helps me code." Start thinking "AI codes while I architect."

Setup That Actually Matters

Most guides walk you through installation. That's one command. Here's the setup that actually determines whether Claude Code is useful or frustrating:

CLAUDE.md — Your Agent's Constitution

The most important file in your project. CLAUDE.md sits in your project root and tells Claude Code how to behave in your codebase. Without it, you're relying on the model's generic behavior. With it, you have a developer who knows your conventions, your architecture, and your preferences.


# CLAUDE.md

## Architecture
- Swift Package Manager monorepo with 6 packages
- LOCore: shared models. LOContent: data providers. LOServer: Vapor routes.
- Vapor 4 + Leaf templates + HTMX for interactivity
- All routes return HTML. No JSON API unless explicitly requested.

## Conventions
- Tests go in Tests/{PackageName}Tests/
- Every public model must be Codable, Identifiable, Sendable
- Use guard-let for unwrapping, never force-unwrap
- Leaf templates live in Resources/Views/
- Static assets in Public/

## Commands
- Build: swift build
- Test: swift test
- Run: swift run LOServer
- Deploy: swift build -c release && launchctl kickstart -k gui/$(id -u)/ai.likeone.loserver

This file is worth more than any prompt engineering. Claude Code reads it on every session start. It's the difference between "make a route" (generic) and "make a Vapor route that returns a Leaf template following our existing patterns" (useful).

Pro tip: Add a .claude/ directory with additional context files. We keep architecture diagrams, deployment SOPs, and API reference docs there. Claude Code reads them when relevant.

Permission Modes

Claude Code has three permission modes:

  • Ask mode — confirms every file edit and command. Safe but slow. Use this when onboarding.
  • Auto-approve mode — approves reads and edits automatically, still confirms shell commands. The sweet spot for daily development.
  • Full auto — approves everything including shell commands. Use this for trusted workflows like test runs and deployments on your own machine.

Start with ask mode for the first session on a new project. Once you trust the agent's behavior in your codebase, move to auto-approve. Full auto is for established projects where you've set up guardrails in CLAUDE.md.

MCP Servers — Extending the Agent

Claude Code supports MCP (Model Context Protocol) servers, which give it superpowers beyond file editing:

  • Browser automation — take screenshots, navigate pages, test UI
  • Database access — query Supabase, run SQL
  • Deployment — trigger Vercel deploys, check build logs
  • Design auditing — check against Apple HIG guidelines

We run 15+ MCP servers in our Claude Code environment. The agent can check revenue in Stripe, read emails in Gmail, deploy to production, and post to Slack — all from the same terminal session.

Configure them in ~/.claude/settings.json or your project's .mcp.json. Start with one or two that match your workflow, then expand.

Not sure which Claude model to use? See our Claude Sonnet vs Opus comparison for a practical breakdown of speed, cost, and quality tradeoffs.

The Workflows That Compound

After hundreds of sessions, these are the patterns that deliver the most value:

1. The Full-Feature Sprint

This is Claude Code's killer use case. Instead of asking for a function or a component, describe an entire feature:


"Add a newsletter subscription system. I need:
- A /api/subscribe POST endpoint that accepts email
- Email validation and duplicate checking
- Storage in the existing SQLite database
- A subscribe form component in the site footer
- A success/error toast notification
- Tests for the endpoint"

Claude Code will read your existing codebase to understand patterns, then implement across multiple files — the model, the route, the template, the tests — in a single session. It maintains consistency because it sees everything at once.

This is where the 1M token context window matters. Claude Code holds your entire codebase in context while implementing. No "I lost track of the database schema" halfway through. No inconsistencies between the model definition and the route handler.

2. The Codebase Migration

We migrated from Next.js to Swift/Vapor using Claude Code. Not a rewrite-from-scratch — a systematic migration that preserved functionality while changing the entire tech stack.

The approach:

  1. Have Claude Code read the existing implementation
  2. Describe the target architecture in CLAUDE.md
  3. Migrate route by route, testing each one
  4. Let Claude Code handle the tedious parts — converting JSX to Leaf templates, rewriting API handlers, migrating data models

What would have taken a team of three engineers a month took one person and Claude Code two weeks. The result had better test coverage than the original.

3. The Debug Session

Claude Code is an exceptional debugger because it can read, execute, and iterate in a tight loop:


"The /pricing page returns a 500 error in production.
Check the route handler, the Leaf template, and the
Stripe integration. Run the server locally and verify."

It reads the route. Reads the template. Spots the issue — maybe a nil-unwrap on a Stripe product that doesn't exist in the test environment. Adds a guard clause. Runs the server. Hits the endpoint. Confirms the fix. Writes a test to prevent regression.

That entire loop happens in under two minutes. No context switching. No "can you share the error log." The agent has access to everything.

4. The QA Sweep

After a major feature push, we run a full QA sweep:


"Test every route on the site. Check for 200 status codes,
verify the HTML renders correctly, check mobile responsiveness
via the CSS, and flag any broken links or missing assets."

Claude Code systematically hits every endpoint, reads every template, checks every static asset reference, and produces a structured report. In our last session, it QA'd 619 URLs and caught three issues we would have missed manually.

Advanced Patterns

Persistent Memory via Brain

Claude Code forgets between sessions by default. We solved this with a persistent brain — a local SQLite database that stores project state, decisions, and patterns across sessions.

At the start of each session, Claude Code reads the brain state. At the end, it writes what it learned. Over 230+ sessions, the brain has accumulated 880+ entries covering everything from "Safari doesn't support CSS subgrid in our build" to "the Stripe webhook secret is in faye_config.json."

The agent gets smarter every session. Not because the model improves — because the context improves.

Multi-Agent Orchestration

Claude Code can spawn sub-agents for parallel work. When we need to research a topic, build a feature, AND update documentation simultaneously, the main agent delegates:

  • Sub-agent 1: Research API docs and summarize
  • Sub-agent 2: Implement the feature
  • Main agent: Coordinate and handle integration

This cuts development time significantly for complex features. The sub-agents share context through the file system — one writes a data model, the other reads it to build the route handler.

CLAUDE.md Layering

You can have multiple CLAUDE.md files at different directory levels:


~/CLAUDE.md                    # Global preferences
~/project/CLAUDE.md            # Project architecture
~/project/.claude/CLAUDE.md    # Session-specific context

The agent reads all of them, with more specific files taking priority. We use this to keep global conventions ("never use force-unwrap") separate from project-specific rules ("this project uses Vapor 4").

The Mistakes That Cost Hours

1. Being Too Vague

Bad: "Make the site look better."

Good: "The /pricing page needs a comparison table with three tiers. Use our existing card component and spacing tokens from styles.css. Mobile should stack vertically."

Claude Code is brilliant but not psychic. Specificity in inputs produces quality in outputs. The more architectural context you provide, the less iteration you need.

2. Not Reading First

If you ask Claude Code to modify a file it hasn't read, it will write generic code that might not match your patterns. Always structure requests as "read X, then modify it to do Y." Or better — put the conventions in CLAUDE.md so the agent always knows.

3. Skipping Tests

Claude Code writes excellent tests — but only if you ask. Make it a habit: every feature request ends with "and write tests." Better yet, put it in your CLAUDE.md: "Every new function must have corresponding test coverage."

4. Ignoring the Diff

Claude Code shows you every change it makes. Read the diffs. Not because the code is wrong — it usually isn't — but because understanding what changed is how you maintain architectural knowledge of your own codebase.

The trap: letting Claude Code become a black box. The agent is your most productive developer, but you're still the architect. If you can't explain why a change was made, you've lost control.

5. Fighting the Model

If Claude Code suggests an approach different from what you had in mind, pause before overriding. The model has read your entire codebase. It might see a pattern conflict or an edge case you missed. The best sessions happen when you treat Claude Code as a senior colleague, not a typing assistant.

Performance: Real Numbers

From our last major session (S231):

  • 18 commits in a single session
  • 62 tests passing across 6 test suites
  • 619 URLs in the sitemap, all verified
  • Features shipped: newsletter system, footer redesign, legal pages, pricing overhaul, auth flow, mobile CSS, session management, progress sync, track pages, open source links
  • Bugs caught: 3 (Safari CSS, missing auth cookie path, broken Stripe webhook)

That's not cherry-picked. That's a Wednesday. The compound effect of a well-configured CLAUDE.md, persistent brain state, and established codebase patterns means Claude Code operates at a level that would require a 3-4 person engineering team.

Who Should Use Claude Code

Solo founders and small teams. If you're building a product with limited engineering resources, Claude Code is the highest-leverage tool available. It won't replace architectural thinking, but it will handle 80% of the implementation work.

Senior developers. If you know what good code looks like but spend too much time writing boilerplate, Claude Code handles the tedious parts while you focus on design decisions.

Teams doing large migrations. Converting between frameworks, languages, or architectures is where Claude Code's ability to read and rewrite entire codebases shines.

Anyone with accessibility needs. Claude Code is voice-friendly, terminal-native, and doesn't require mouse precision. For developers with motor disabilities, it removes physical barriers from software engineering.

Who Shouldn't (Yet)

Complete beginners. If you can't read the code Claude writes, you can't verify it. Learn the fundamentals first. Use Claude Code to accelerate learning, not replace it.

Teams with strict compliance requirements. If your code can't touch external APIs or cloud services, the default Claude Code setup sends code to Anthropic's API. Check your compliance requirements. The model processes your code to generate responses — understand what that means for your codebase's confidentiality.

Getting Started Today

Five steps to productive Claude Code usage:

  1. Install: npm install -g @anthropic-ai/claude-code
  2. Write CLAUDE.md: Document your project architecture, conventions, and commands. Spend 30 minutes on this. It pays back thousands of times.
  3. Start small: Ask Claude Code to add a test for an existing function. Read the diff. Understand its approach.
  4. Expand: Try a full feature. Describe the inputs, outputs, and constraints. Let it implement across files.
  5. Configure MCP: Add one MCP server that matches your workflow — Supabase for database work, Vercel for deployments, whatever you touch daily. (Review our MCP security checklist before deploying to production.)

The first session feels unfamiliar. By session five, you'll wonder how you built software without it. By session fifty, your codebase will have patterns and test coverage that would make a 10-person team jealous.

The best developer tool isn't the one with the most features. It's the one that disappears into your workflow. Claude Code disappears faster than anything else we've used.

Claude Code vs Cursor vs GitHub Copilot

These tools get compared constantly, but they solve different problems:

GitHub Copilot is an autocomplete engine. It suggests the next line of code as you type. Excellent for boilerplate and common patterns. Limited to single-file context. It accelerates typing, not thinking.

Cursor is an AI-enhanced IDE. It integrates code generation into a VS Code fork with inline editing, chat, and multi-file awareness. Good for developers who want AI assistance without leaving their editor. Stronger than Copilot, but still operates within the IDE paradigm.

Claude Code is an autonomous agent. It reads your entire codebase, plans multi-file changes, runs commands, executes tests, and iterates on failures. It operates in the terminal, not an IDE. The mental model is fundamentally different — you describe outcomes, not implementations.

The practical difference: Copilot saves you keystrokes. Cursor saves you editing time. Claude Code saves you engineering hours. They're not competing — they operate at different levels of abstraction. Many developers use Copilot for inline completions AND Claude Code for larger tasks.

Claude Code Pricing and Usage Limits

Claude Code requires an Anthropic API key or a Claude Pro/Max subscription. Here's the actual cost breakdown:

API usage (pay-per-token): Claude Code uses Sonnet 4.6 by default, with Opus 4.6 available for complex tasks. At current API pricing, a typical development session (reading files, writing code, running tests) costs $2-10 depending on codebase size and task complexity. Heavy sessions with large codebases can reach $20-30. You control costs by choosing which model to use — Sonnet 4.6 is significantly cheaper for routine tasks.

Claude Pro ($20/month): Includes Claude Code with usage limits. Sufficient for casual development — a few sessions per day. You'll hit rate limits on heavy coding days.

Claude Max ($100-200/month): Higher usage limits for professional developers who use Claude Code as their primary development tool. The unlimited context and extended thinking features are where Max earns its price.

Cost optimization tips: Use Sonnet for routine edits and test runs. Reserve Opus for complex architecture decisions and multi-file refactors. Set --model flags in your workflow to control which model handles which tasks. A well-configured CLAUDE.md reduces token usage by preventing the agent from exploring your codebase blindly.

Deciding between ChatGPT and Claude for your workflow? See our detailed Custom GPTs vs Claude Projects comparison to understand which platform serves your needs better.

Ready to build your first autonomous agent? Follow our step-by-step Claude Agent SDK tutorial to go from zero to a working AI agent in Python.

Keep Reading

Accelerate Your Team

Want to deploy Claude Code workflows across your engineering team? Our consulting services help organizations build AI-native development practices.

---

Like One's entire platform — 619 pages, 52 courses, 6 Swift packages — was built with Claude Code. Our free AI Academy teaches the engineering patterns behind it, from agent architecture to production deployment.


Free: Claude custom instructions template pack

Eight copy-paste templates — developer, writer, analyst, CLAUDE.md starter, and more. Plus new guides in your inbox. No spam, unsubscribe anytime.

Or grab the templates directly — no email needed

Keep learning — for free

50+ AI courses. 590+ lessons. No paywall for starters.

Need help building this?

We build MCP servers, Claude workflows, and AI agents for teams. Strategy calls start at $150/hr.