Visual Studio Code

Keyboard shortcuts for Visual Studio Code

Navigation
10 shortcuts
Show all Symbols
  • CtrlT
Go to Line...
  • CtrlG
Go to File...
  • CtrlP
Go to Symbol...
  • CtrlShiftO
Show Problems panel
  • CtrlShiftM
Go to next error or warning
  • F8
Go to previous error or warning
  • ShiftF8
Navigate editor group history
  • CtrlShiftTab
Go back/forward
  • Alt
  • or
    Alt
Toggle Tab moves focus
  • CtrlM
General
6 shortcuts
Show Command Palette
  • CtrlShiftP
Quick Open, Go to File...
  • CtrlP
New window/instance
  • CtrlShiftN
Close window/instance
  • CtrlShiftW
User Settings
  • Ctrl,
Keyboard Shortcuts
  • CtrlKCtrlS
Basic Editing
25 shortcuts
Cut line (empty selection)
  • CtrlX
Copy line (empty selection)
  • CtrlC
Move line up/down
  • Alt
  • or
    Alt
Copy line up/down
  • ShiftAlt
  • or
    ShiftAlt
Delete line
  • CtrlShiftK
Insert line below
  • CtrlEnter
Insert line above
  • CtrlShiftEnter
Jump to matching bracket
  • CtrlShift\
Indent/outdent line
  • Ctrl]
  • or
    Ctrl[
Go to beginning/end of line
  • Home
  • or
    End
Go to beginning of file
  • CtrlHome
Go to end of file
  • CtrlEnd
Scroll line up/down
  • Ctrl
  • or
    Ctrl
Scroll page up/down
  • AltPgUp
  • or
    AltPgDn
Fold (collapse) region
  • CtrlShift[
Unfold (uncollapse) region
  • CtrlShift]
Fold (collapse) all subregions
  • CtrlKCtrl[
Unfold (uncollapse) all subregions
  • CtrlKCtrl]
Fold (collapse) all regions
  • CtrlKCtrl0
Unfold (uncollapse) all regions
  • CtrlKCtrlJ
Add line comment
  • CtrlKCtrlC
Remove line comment
  • CtrlKCtrlU
Toggle line comment
  • Ctrl/
Toggle block comment
  • ShiftAltA
Toggle word wrap
  • AltZ
Debug
7 shortcuts
Toggle breakpoint
  • F9
Start/Continue
  • F5
Stop
  • ShiftF5
Step into
  • F11
Step out
  • ShiftF11
Step over
  • F10
Show hover
  • CtrlKCtrlI
Display
15 shortcuts
Toggle full screen
  • F11
Toggle editor layout (horizontal/vertical)
  • ShiftAlt0
Zoom in/out
  • Ctrl=
  • or
    Ctrl-
Toggle Sidebar visibility
  • CtrlB
Show Explorer/Toggle focus
  • CtrlShiftE
Show Search
  • CtrlShiftF
Show Source Control
  • CtrlShiftG
Show Debug
  • CtrlShiftD
Show Extensions
  • CtrlShiftX
Replace in files
  • CtrlShiftH
Toggle Search details
  • CtrlShiftJ
Show Output panel
  • CtrlShiftU
Open Markdown preview
  • CtrlShiftV
Open Markdown preview to the side
  • CtrlKV
Zen Mode (Esc Esc to exit)
  • CtrlKZ
File management
14 shortcuts
New File
  • CtrlN
Open File...
  • CtrlO
Save
  • CtrlS
Save As...
  • CtrlShiftS
Save All
  • CtrlKS
Close
  • CtrlF4
Close All
  • CtrlKCtrlW
Reopen closed editor
  • CtrlShiftT
Keep preview mode editor open
  • CtrlKEnter
Open next
  • CtrlTab
Open previous
  • CtrlShiftTab
Copy path of active file
  • CtrlKP
Reveal active file in Explorer
  • CtrlKR
Show active file in new window/instance
  • CtrlKO
Integrated terminal
7 shortcuts
Show integrated terminal
  • Ctrl`
Create new terminal
  • CtrlShift`
Copy selection
  • CtrlC
Paste into active terminal
  • CtrlV
Scroll up/down
  • Ctrl
  • or
    Ctrl
Scroll page up/down
  • ShiftPgUp
  • or
    ShiftPgDn
Scroll to top/bottom
  • CtrlHome
  • or
    CtrlEnd
Rich languages editing
12 shortcuts
Trigger suggestion
  • CtrlSpace
Trigger parameter hints
  • CtrlShiftSpace
Format document
  • ShiftAltF
Format selection
  • CtrlKCtrlF
Go to Definition
  • F12
Peek Definition
  • AltF12
Open Definition to the side
  • CtrlKF12
Quick Fix
  • Ctrl.
Show References
  • ShiftF12
Rename Symbol
  • F2
Trim trailing whitespace
  • CtrlKCtrlX
Change file language
  • CtrlKM
Search and replace
8 shortcuts
Find
  • CtrlF
Replace
  • CtrlH
Find next
  • F3
Find previous
  • ShiftF3
Select all occurences of Find match
  • AltEnter
Add selection to next Find match
  • CtrlD
Move last selection to next Find match
  • CtrlKCtrlD
Toggle case-sensitive/regex/whole word
  • AltC
  • or
    AltR
  • or
    AltW
Editor management
7 shortcuts
Close editor
  • CtrlF4W
Close folder
  • CtrlKF
Split editor
  • Ctrl\
Focus into 1st, 2nd, or 3rd editor group
  • Ctrl1
  • or
    Ctrl2
  • or
    Ctrl3
Focus into previous/next editor group
  • CtrlKCtrl
  • or
    CtrlKCtrl
Move editor left/right
  • CtrlShiftPgUp
  • or
    CtrlShiftPgDn
Move active editor group
  • CtrlK
  • or
    CtrlK
Multi-cursor and selection
9 shortcuts
Insert cursor above/below
  • CtrlAlt
  • or
    CtrlAlt
Undo last cursor operation
  • CtrlU
Insert cursor at end of each line selected
  • ShiftAltI
Select current line
  • CtrlI
Select all occurrences of current selection
  • CtrlShiftL
Select all occurrences of current word
  • CtrlF2
Expand selection
  • ShiftAlt
Shrink selection
  • ShiftAlt
Column (box) selection page up/down
  • CtrlShiftAltPgUp
  • or
    CtrlShiftAltPgDn

Want to learn Visual Studio Code shortcuts quickly?

Sign up to get notified when Keyhero is ready.