setup

How to Use Claude Code in VS Code

2 min · updated June 13, 2026

Claude Code runs in any terminal, but inside VS Code it shows edits as inline diffs and can see the files you have open. Here’s the one-minute setup.

1. Install Claude Code

If you haven’t already:

npm install -g @anthropic-ai/claude-code

(Platform-specific guides: Windows · macOS & Linux.)

2. Open the integrated terminal

Open your project folder in VS Code, then open the integrated terminal: View → Terminal.

3. Run claude

claude

The first time you run it inside VS Code, Claude Code detects the editor and installs its companion extension automatically. No marketplace hunting needed.

4. Work with diffs and selections

Now when Claude edits a file, the change appears as a diff in the editor to accept or reject. Select code before you ask a question and Claude uses that selection as context.


Tips

← All guides