Search and replace
Keyboard shortcuts for Mac
General
Close
K W
Close All
Find
Replace
Reopen closed editor
K Enter
G / G
Find next/previous
Keep Open
Tab / Tab
Enter
Select all occurrences of Find match
Open next / previous
K P
Add selection to next Find match
Copy path of active file
K R
K D
Move last selection to next Find match
Reveal active file in Explorer
K O
Show active file in new window/instance
P, F1
Show Command Palette
Quick Open
New window/instance
Rich languages editing
Close window/instance
Space
Trigger suggestion
Space
Trigger parameter hints
Toggle full screen
Tab
Emmet expand abbreviation
Toggle editor layout
= / -
Format document
Zoom in/out
K F
Format selection
Toggle Sidebar visibility
F12
Go to Definition
Show Explorer / Toggle focus
F12
Peek Definition
Show Search
K F12
Open Definition to the side
Show Git
Quick Fix
Show Debug
F12
Show References
Show Extensions
F2
Rename Symbol
Replace in files
. / ,
Replace with next/previous value
Toggle Search details
K X
Trim trailing whitespace
Open new command prompt/terminal
K M
Change file language
Show Output panel
Toggle Markdown preview
K V
Open Markdown preview to the side
Basic editing
Display
Cut line (empty selection)
Copy line (empty selection)
Move line down/up
Copy line down/up
Delete line
Enter / Enter
Insert line below/above
Jump to matching bracket
] / [
Indent/outdent line
Home / End
Go to beginning/end of line
Go to beginning/end of file
PgUp
Scroll line up
PgDown
Scroll line down
PgUp /PgDown
Scroll page up/down
Navigation
[ / ]
Fold/unfold region
Fold/unfold all subregions
Show all Symbols
Debug
K [ / K ]
K 0 / K J
Fold/unfold all regions
Go to Line...
F9
Add line comment
Go to File...
Toggle breakpoint
K C
F5
Start/Continue
K U
Remove line comment
Go to Symbol...
F11 / F11
Toggle line comment
Show Problems panel
Step into/ out
F10
Toggle block comment
Go to next/previous error or warning
Step over
F8 / F8
F5
Toggle word wrap
Navigate editor group history
Stop
Tab
K I
- / -
Go back/forward
Show hover
Toggle Tab moves focus
Multi-cursor and selection
Alt+Click
U
I
I
L
F2
Shift+Alt + drag
mouse
PgUp
PgDown
Insert cursor
Insert cursor above
Insert cursor below
Undo last cursor operation
Insert cursor at end of each line selected
Select current line
Select all occurrences of current selection
Select all occurrences of current word
Expand selection
Shrink selection
Column (box) selection
Column
Column
Column
Column
Column
Column
(box)
(box)
(box)
(box)
(box)
(box)
selection
selection
selection
selection
selection
selection
up
down
left
right
page up
page down
Editor management
W
Close editor
K F
Close folder
Split editor
st
nd
rd
Integrated terminal
`
Show integrated terminal
Create new terminal
unassigned
Copy selection
unassigned
Paste into active terminal
Scroll up
1 / 2 / 3
Focus into 1 , 2 , 3 editor group
K / K
Focus into previous/next editor group
Scroll down
PgUp
Scroll page up
PgDown
Scroll page down
Home
Scroll to top
End
Scroll to bottom
K / K Move editor left/right
K / K
Move active editor group
File management
New File
Open File...
Save
Save As...
Save All
Other operating systems keyboard shortcuts and additional
unassigned shortcuts available at aka.ms/vscodekeybindings