Visual Studio Code Keyboard Shortcuts

Visual Studio Code

Basic Editing

command + xCut line (empty selection)
command + cCopy line (empty selection)
shift + command + kDelete Line
command + enterInsert Line Below
shift + command + enterInsert Line Above
option + downMove Line Down
option + upMove Line Up
shift + option + downCopy Line Down
shift + option + upCopy Line Up
command + dAdd Selection To Next Find Match
command + dMove Last Selection To Next Find Match
command + uUndo last cursor operation
shift + option + iInsert cursor at end of each line selected
shift + command + lSelect all occurrences of current selection
command + f2Select all occurrences of current word
command + lSelect current line
option + command + downInsert Cursor Below
option + command + upInsert Cursor Above
shift + command + \Jump to matching bracket
command + ]Indent Line
command + [Outdent Line
homeGo to Beginning of Line
endGo to End of Line
command + downGo to End of File
command + upGo to Beginning of File
control + page downScroll Line Down
control + page upScroll Line Up
command + page downScroll Page Down
command + page upScroll Page Up
option + command + [Fold (collapse) region
option + command + ]Unfold (uncollapse) region
command + [Fold (collapse) all subregions
command + ]Unfold (uncollapse) all subregions
command + 0Fold (collapse) all regions
command + jUnfold (uncollapse) all regions
command + cAdd Line Comment
command + uRemove Line Comment
command + /Toggle Line Comment
shift + option + aToggle Block Comment
command + fFind
option + command + fReplace
command + gFind Next
shift + command + gFind Previous
option + enterSelect All Occurrences of Find Match
option + command + cToggle Find Case Sensitive
option + command + rToggle Find Regex
option + command + wToggle Find Whole Word
control + shift + mToggle Use of Tab Key for Setting Focus
option + zToggle Word Wrap

Rich Languages Editing

control + spaceTrigger Suggest
shift + command + spaceTrigger Parameter Hints
shift + option + fFormat Document
command + fFormat Selection
f12Go to Definition
command + iShow Hover
option + f12Peek Definition
command + k then f12Open Definition to the Side
command + .Quick Fix
shift + f12Peek References
f2Rename Symbol
shift + command + .Replace with Next Value
shift + command + ,Replace with Previous Value
control + shift + command + rightExpand AST Selection
control + shift + command + leftShrink AST Selection
command + xTrim Trailing Whitespace
command + k then mChange Language Mode

Navigation

command + tShow All Symbols
control + gGo to Line...
command + pGo to File..., Quick Open
shift + command + oGo to Symbol...
shift + command + mShow Problems
f8Go to Next Error or Warning
shift + f8Go to Previous Error or Warning
shift + command + p or f1Show All Commands
control + shift + tabNavigate Editor Group History
control + -Go Back
control + -Go back in Quick Input
control + shift + -Go Forward

Editor/Window Management

shift + command + nNew Window
shift + command + wClose Window
command + wClose Editor
command + k then fClose Folder
command + \Split Editor
command + 1Focus into First Editor Group
command + 2Focus into Second Editor Group
command + 3Focus into Third Editor Group
command + leftMove Editor Left
command + rightMove Editor Right
command + k then leftMove Active Editor Group Left
command + k then rightMove Active Editor Group Right
control + command + rightMove Editor into Next Group
control + command + leftMove Editor into Previous Group

File Management

command + nNew File
command + sSave
option + command + sSave All
shift + command + sSave As...
command + wClose
option + command + tClose Others
command + k then wClose Group
command + k then command + wClose All
shift + command + tReopen Closed Editor
command + k then enterKeep Open
control + tabOpen Next
control + shift + tabOpen Previous
command + k then pCopy Path of Active File
command + k then rReveal Active File in Windows
command + k then oShow Opened File in New Window

Display

control + command + fToggle Full Screen
command + k then zToggle Zen Mode
escape then escapeLeave Zen Mode
command + =Zoom in
command + -Zoom out
command + 0Reset Zoom
command + bToggle Sidebar Visibility
shift + command + eShow Explorer / Toggle Focus
shift + command + fShow Search
control + shift + gShow Source Control
shift + command + dShow Debug
shift + command + xShow Extensions
shift + command + uShow Output
control + qQuick Open View
shift + command + cOpen New Command Prompt
shift + command + vToggle Markdown Preview
command + k then vOpen Preview to the Side
control + `Toggle Integrated Terminal

Search

shift + command + fShow Search
shift + command + hReplace in Files
option + command + cToggle Match Case
option + command + wToggle Match Whole Word
option + command + rToggle Use Regular Expression
shift + command + jToggle Search Details
f4Focus Next Search Result
shift + f4Focus Previous Search Result
downShow Next Search Term
upShow Previous Search Term

Preferences

command + ,Open Settings
command + k then command + sOpen Keyboard Shortcuts
command + k then command + tSelect Color Theme

Debug

f9Toggle Breakpoint
f5Start
f5Continue
control + f5Start (without debugging)
f6Pause
f11Step Into
shift + f11Step Out
f10Step Over
shift + f5Stop
command + iShow Hover

Tasks

shift + command + bRun Build Task