Claude Code
Claude Code VS Code extension: install, shortcuts, settings and /ide (works in Cursor too)
How do I install and use Claude Code in VS Code?
Open the Extensions view (Cmd+Shift+X or Ctrl+Shift+X), search for Claude Code, and click Install. It needs VS Code 1.94.0 or later and any paid Claude plan or a Claude Console account. If you prefer the terminal, run claude in VS Code's integrated terminal, or run /ide from an external terminal to connect it.
Install
- Requires VS Code 1.94.0 or later
- Sign in with a Pro, Max, Team or Enterprise subscription, or a Claude Console account. No API key is required
- The same extension installs in Cursor
- Or install from the VS Code Marketplace listing anthropic.claude-code
Installing the extension does not put claude on your shell PATH. For the terminal CLI, do the standalone install once.
Keyboard shortcuts
- Cmd+Esc / Ctrl+Esc: toggle focus between the editor and Claude
- Cmd+Shift+Esc / Ctrl+Shift+Esc: open a new conversation as an editor tab
- Option+K / Alt+K: insert an @-mention of the current file and selection, for example @app.ts#5-10
- Cmd+Shift+T / Ctrl+Shift+T: reopen the last closed Claude session tab
- Cmd+N / Ctrl+N: new conversation, only with enableNewConversationShortcut set to true
On macOS Tahoe and later, the system Game Overlay shortcut grabs Cmd+Esc. Rebind Claude Code: Focus input in the Keyboard Shortcuts editor (Cmd+K Cmd+S) if it does nothing.
Give Claude context
Type @ followed by a file or folder name to add it. Fuzzy matching works. Claude also sees your selected text and the file you have open. Turn off the Attach Open File setting to send only the selection.
Key extension settings
Open settings with Cmd+, or Ctrl+, and go to Extensions, then Claude Code.
- claudeCode.useTerminal (default false): launch Claude in terminal mode instead of the graphical panel
- claudeCode.initialPermissionMode: default, plan, acceptEdits or bypassPermissions for new conversations. Read from user settings only
- claudeCode.useCtrlEnterToSend (default false): send with Ctrl/Cmd+Enter instead of Enter
- claudeCode.enableNewConversationShortcut (default false)
VS Code settings.json
{
"claudeCode.useTerminal": false,
"claudeCode.initialPermissionMode": "plan"
}Use the CLI with VS Code
Open the integrated terminal (Ctrl+` or Cmd+`) and run claude. The CLI integrates with the IDE for diff viewing and diagnostics. From an external terminal, run /ide inside Claude Code to connect it to VS Code.
Inside Claude Code in an external terminal
/ide
Stop the extension from reinstalling
Running claude in a VS Code integrated terminal reinstalls the extension automatically. To prevent that, turn off Auto-install IDE extension in /config, set autoInstallIdeExtension to false, or set the environment variable below.
Shell
export CLAUDE_CODE_IDE_SKIP_AUTO_INSTALL=1
Sources
More on Claude Code
Other guides
Get the weekly agent stack update
New official MCP servers, spec changes and harness releases, checked against the source. One email a week, no fluff.
Reviewed Oct 13, 2026. Settings change often; the linked vendor docs are the source of truth.