VS Code

VS Code Shortcuts

Visual Studio Code keyboard shortcuts for Windows, macOS and Linux. v1.88

Source: Official documentation · Updated 2026-06

Shortcuts
10
Categories

Cheat sheet guide

VS Code shortcuts worth learning first

This page collects 81 searchable VS Code keyboard shortcuts across 10 categories. Start with the shortcuts for General, Editing, Multi-cursor & Selection, Search & Replace, then print the cheat sheet once the important ones are worth keeping nearby.

  • Show Command PaletteCtrlShiftP
  • Cut line (empty selection)CtrlX
  • Insert cursor above/belowAltCtrl↑/↓
  • FindCtrlF
  • Go to lineCtrlG
  • Close editorCtrlW

General

6 shortcuts
Show Command Palette
CtrlShiftP
Quick Open / Go to File
CtrlP
New Window
CtrlShiftN
Close Window
CtrlShiftW
User Settings
Ctrl,
Keyboard Shortcuts
CtrlKCtrlS

Editing

19 shortcuts
Cut line (empty selection)
CtrlX
Copy line (empty selection)
CtrlC
Move line up/down
Alt↑/↓
Copy line up/down
AltShift↑/↓
Delete line
CtrlShiftK
Insert line below
CtrlEnter
Insert line above
CtrlShiftEnter
Jump to matching bracket
CtrlShift\
Indent / outdent line
Ctrl]Ctrl[
Go to beginning of line
Home
Go to end of line
End
Go to beginning of file
CtrlHome
Go to end of file
CtrlEnd
Toggle line comment
Ctrl/
Toggle block comment
AltShiftA
Undo
CtrlZ
Redo
CtrlY
Format document
AltShiftF
Format selection
CtrlKCtrlF

Multi-cursor & Selection

7 shortcuts
Insert cursor above/below
AltCtrl↑/↓
Undo last cursor
CtrlU
Select all occurrences of current selection
CtrlShiftL
Select all occurrences of current word
CtrlF2
Add selection to next find match
CtrlD
Select current line
CtrlL
Column (box) selection
ShiftAltdrag

Search & Replace

8 shortcuts
Find
CtrlF
Replace
CtrlH
Find next/previous
F3ShiftF3
Toggle case-sensitive
AltC
Toggle regex
AltR
Toggle whole word
AltW
Search across files
CtrlShiftF
Replace across files
CtrlShiftH

Navigation

9 shortcuts
Go to line
CtrlG
Go to symbol in file
CtrlShiftO
Go to symbol in workspace
CtrlT
Go to definition
F12
Peek definition
AltF12
Open definition to side
CtrlKF12
Go back / forward
AltAlt
Go to next error/warning
F8
Show all references
AltShiftF12

Editor Management

6 shortcuts
Close editor
CtrlW
Close folder
CtrlKF
Split editor
Ctrl\
Focus 1st/2nd/3rd editor group
Ctrl1/2/3
Move editor left/right
CtrlShiftPgUp/PgDn
New editor group to the left/right
CtrlK←/→

File Management

7 shortcuts
New file
CtrlN
Open file
CtrlO
Save
CtrlS
Save as
CtrlShiftS
Save all
CtrlKS
Revert file
Close all editors
CtrlKCtrlW

Display

7 shortcuts
Toggle full screen
F11
Toggle sidebar
CtrlB
Toggle terminal
Ctrl`
Toggle problems panel
CtrlShiftM
Zoom in/out
Ctrl=Ctrl-
Reset zoom
Ctrl0
Zen mode
CtrlKZ

Debug

7 shortcuts
Toggle breakpoint
F9
Start / continue debug
F5
Stop debug
ShiftF5
Step over
F10
Step into
F11
Step out
ShiftF11
Show hover
CtrlKCtrlI

Integrated Terminal

5 shortcuts
Create new terminal
CtrlShift`
Copy selection
CtrlC
Scroll up/down
Ctrl↑/↓
Scroll page up/down
ShiftPgUp/PgDn
Scroll to top/bottom
CtrlHome/End

Frequently asked questions

What is the fastest way to find VS Code shortcuts on this page?

Use the search box or press /, then type an action such as show command palette.

Can I print this VS Code shortcut cheat sheet?

Yes. Use the Print / PDF button or your browser print command to save a compact cheat sheet.

Does this page include Windows and Mac shortcuts for VS Code?

Yes. Use the OS tabs to switch between Windows and macOS shortcuts. For example, Show Command Palette is Ctrl+Shift+P on Windows and ⌘⇧P on macOS where available.

See also

No shortcuts match your search.