Lesson 02: Where Claude Code Runs
Claude Code is not a single app — it is an agentic coding engine that runs across multiple surfaces. You can use it in your terminal, inside your IDE, through a desktop app, on the web, or embedded in CI/CD pipelines. Every surface connects to the same underlying engine, so your CLAUDE.md files, settings, and MCP servers carry across all of them.
This lesson maps out the landscape so you can pick the right surface for your workflow.
The Six Surfaces
1. CLI (Terminal)
The terminal is the original and most full-featured way to run Claude Code. It works on macOS, Linux, Windows, and WSL. You install it once, navigate to your project, and type claude.
# Start Claude Code in any project
cd my-project
claudeThe CLI gives you everything: file system access, command execution, git integration, MCP servers, hooks, skills, headless mode for scripting, and the ability to pipe data in and out like any Unix tool.
# Pipe logs into Claude for analysis
tail -f app.log | claude -p "alert me if you see errors"
# Run Claude non-interactively for automation
claude -p "write tests for the auth module, run them, fix failures"Choose the CLI when:
- You live in the terminal and want maximum control
- You need scripting, piping, or automation
- You want access to every feature and flag (headless mode,
--print, worktrees) - You are connecting to third-party providers like Amazon Bedrock or Google Vertex AI
2. VS Code Extension
The VS Code extension wraps Claude Code in a graphical panel inside your editor. It shows inline diffs, supports @-mentions with autocomplete, lets you review and accept changes visually, and keeps conversation history in a sidebar.
Install it from the Extensions view — search for "Claude Code" — or use the Command Palette and select Claude Code: Open in New Tab.
# In the Claude Code panel inside VS Code
> Explain the logic in @auth.ts
> Add input validation to @signup-form.tsx#12-45The extension includes the CLI under the hood, so you can also open VS Code's integrated terminal and run claude directly for features that are CLI-only (like MCP server configuration or the ! bash shortcut).
Key capabilities:
- Inline side-by-side diffs for reviewing changes
@-mention files with line ranges from your selection- Multiple conversations in separate tabs
- Plan mode to review approach before execution
- Auto-accept mode for faster iteration
- Conversation history with search
Choose VS Code when:
- You already work in VS Code (or Cursor) and want Claude integrated into your editor
- You prefer visual diff review over terminal output
- You want to
@-mention files with autocomplete rather than typing paths
3. JetBrains Extension
The JetBrains plugin brings Claude Code to IntelliJ IDEA, PyCharm, WebStorm, GoLand, PhpStorm, Android Studio, and other JetBrains IDEs. It provides diff viewing in the native IDE diff viewer, selection context sharing, and keyboard shortcuts.
Install the Claude Code plugin from the JetBrains Marketplace and restart your IDE.
Key capabilities:
- Code changes displayed in the native JetBrains diff viewer
- Current selection and open tab automatically shared as context
- File reference shortcuts (
Cmd+Option+Kon Mac,Alt+Ctrl+Kon Windows/Linux) - IDE diagnostic errors (lint, syntax) automatically shared with Claude
- Quick launch with
Cmd+Esc/Ctrl+Esc
Choose JetBrains when:
- Your primary IDE is IntelliJ, PyCharm, WebStorm, or another JetBrains product
- You want Claude to see your IDE's diagnostics and selections automatically
- You prefer staying in your existing environment rather than switching to a terminal
4. Desktop App
The Claude Desktop app has a dedicated Code tab that runs the full Claude Code engine through a graphical interface. It is available on macOS and Windows.
The Desktop app adds capabilities that go beyond the CLI:
- Visual diff review with inline comments — click any line to leave feedback
- Live app preview — Claude starts your dev server and verifies changes in an embedded browser
- Parallel sessions with automatic Git worktree isolation
- GitHub PR monitoring with auto-fix for failing CI and auto-merge
- Connectors for Slack, GitHub, Linear, Google Calendar, and more
- Remote sessions that run on Anthropic's cloud and continue even if you close the app
# In the Desktop app's Code tab
> Build a login page with email/password auth, preview it, then create a PRYou can move sessions between surfaces: run /desktop in the CLI to hand off a terminal session to the Desktop app, or use the Desktop app's "Continue in" menu to move work to the web or your IDE.
Choose the Desktop app when:
- You want visual diff review with inline commenting
- You want live app preview to verify frontend changes
- You want to run parallel sessions with automatic Git isolation
- You want to kick off remote tasks that run while your laptop is closed
5. Claude Code on the Web
Claude Code on the web lets you start coding tasks from your browser at claude.ai/code or from the Claude iOS app. Tasks run on Anthropic's cloud infrastructure, so they keep running even if you close the tab or put your phone away.
This is different from the regular Claude.ai chat — it gives you the full Claude Code engine with file editing, command execution, and git integration, all running against your GitHub repositories.
# From the CLI, send a task to run on the web
& Fix the flaky test in auth.spec.ts
# Or start directly from the command line
claude --remote "Update the API documentation for v2 endpoints"You can pull web sessions back to your terminal with /teleport when you want to continue locally.
Choose the web when:
- You want to kick off tasks from your phone or a machine without Claude Code installed
- You need long-running tasks that continue while you step away
- You want to work on repositories you do not have cloned locally
- You want to run multiple tasks in parallel without tying up your terminal
6. Integrations (CI/CD, SDK, Headless)
Claude Code runs in automated pipelines too, not just interactive sessions.
GitHub Actions — Mention @claude in any PR or issue comment, and Claude analyzes code, implements features, and creates pull requests. Set it up with the /install-github-app command or manually with a workflow file.
# .github/workflows/claude.yml
name: Claude Code
on:
issue_comment:
types: [created]
jobs:
claude:
runs-on: ubuntu-latest
steps:
- uses: anthropics/claude-code-action@v1
with:
anthropic_api_key: ${{ secrets.ANTHROPIC_API_KEY }}GitLab CI/CD — Similar integration for GitLab-hosted repositories.
Headless / SDK — Use claude -p for non-interactive scripting, or build fully custom agents with the Agent SDK for programmatic control over orchestration, tool access, and permissions.
# Non-interactive: generate a commit message from staged changes
git diff --cached | claude -p "write a commit message for these changes"
# Non-interactive: bulk translate files
claude -p "translate src/i18n/en.json into French and Spanish"Choose integrations when:
- You want automated PR reviews and issue triage
- You need Claude in CI/CD pipelines without human interaction
- You are building custom agents or automation tools on top of Claude Code
Quick Comparison
| CLI | VS Code | JetBrains | Desktop App | Web | GitHub Actions | |
|---|---|---|---|---|---|---|
| File read/write | Yes | Yes | Yes | Yes | Yes | Yes |
| Command execution | Yes | Yes | Yes | Yes | Yes | Yes |
| Git integration | Yes | Yes | Yes | Yes | Yes | Yes |
| Visual diff review | No | Yes | Yes | Yes | Yes | No |
| Live app preview | No | No | No | Yes | No | No |
@-mention autocomplete |
No | Yes | Yes | Yes | No | No |
| Parallel sessions | Separate terminals | Tabs | Separate terminals | Sidebar tabs | Multiple tasks | Separate runs |
| Remote/cloud sessions | Via & prefix |
No | No | Yes | Yes | Yes |
| Third-party providers | Yes | Yes | No | No | No | Yes |
| Scripting & piping | Yes | No | No | No | No | Yes |
| Headless / non-interactive | Yes | No | No | No | No | Yes |
| Connectors (Slack, etc.) | Via MCP | Via MCP | Via MCP | Built-in UI | No | No |
| Platform | macOS, Linux, Windows | Any (with VS Code) | Any (with JetBrains) | macOS, Windows | Browser, iOS | GitHub runners |
What About Claude.ai (The Chat Interface)?
Claude.ai at claude.ai is the general-purpose chat interface — it is not Claude Code. It is great for brainstorming, writing, research, document analysis, and quick questions. It supports file uploads, artifacts, projects, and shared conversations.
The key difference: Claude.ai cannot read your codebase, run commands, or edit files in your project. If your task involves working inside a codebase, you want Claude Code. If you need to think through an architecture before implementing it, draft a design document, or ask a quick technical question, Claude.ai is a fine starting point.
Tip: Skills transfer between platforms. If you get good at prompting Claude Code, you will be good at prompting Claude everywhere. The prompting fundamentals you learn in this course — being specific, providing context, iterating — apply across all surfaces.
Choosing Your Starting Point
If you are new to Claude Code, here is a simple decision tree:
Do you use VS Code? Start with the VS Code extension. You get visual diffs and
@-mentions without leaving your editor, plus you can drop into the integrated terminal for CLI features anytime.Do you use a JetBrains IDE? Install the JetBrains plugin. Same idea — stay in your existing workflow.
Are you a terminal person? Start with the CLI. It is the most powerful surface and every feature is available.
Do you want a graphical experience without an IDE? Try the Desktop app. Visual diffs, live preview, and session management in a standalone window.
Do you want to try Claude Code without installing anything? Go to claude.ai/code and start a web session against a GitHub repository.
You do not have to pick just one. Many developers use the CLI for focused coding, the Desktop app for visual review, and web sessions for tasks they want to run in the background. Your settings, CLAUDE.md files, and MCP servers work everywhere.
API Access and Billing
Claude Code uses the Anthropic API (your own key) or a Claude subscription (Pro, Max, Teams, Enterprise), depending on how you set it up. The CLI and IDE extensions support both direct API access and third-party providers like Amazon Bedrock and Google Vertex AI. The Desktop app and web interface require a Claude subscription.
# Switch models in any interactive session
/model # Check docs.anthropic.com for latest model IDsHaiku is roughly 60x cheaper than Opus per token, with Sonnet in between. For this course, any model works — but Sonnet is a good default that balances capability and cost.
Key Takeaways
- Claude Code runs on six surfaces: CLI, VS Code, JetBrains, Desktop app, web, and CI/CD integrations
- All surfaces share the same engine — your CLAUDE.md, settings, and MCP servers carry across them
- The CLI is the most full-featured; IDE extensions add visual diffs and editor integration; the Desktop app adds live preview and parallel sessions; the web enables remote and mobile workflows; GitHub Actions automates PR reviews and issue triage
- Claude.ai (the chat interface) is separate from Claude Code — use it for brainstorming and research, not for working inside a codebase
- You do not have to choose one surface — mix and match based on what you are doing
- This course focuses on the CLI and IDE workflows, but the prompting fundamentals apply everywhere