Visual Studio Code (VS Code) Cheat Sheet
Ad
VS Code Cheat Sheet
The most useful VS Code shortcuts and commands in one place. (Mac: replace Ctrl with Cmd.)
General
| Action | Shortcut |
|---|---|
| Command Palette | Ctrl + Shift + P |
| Quick Open file | Ctrl + P |
| Settings | Ctrl + , |
| Toggle sidebar | Ctrl + B |
| Toggle terminal | Ctrl + ` |
Editing
| Action | Shortcut |
|---|---|
| Copy line up/down | Shift + Alt + ↑/↓ |
| Move line | Alt + ↑/↓ |
| Delete line | Ctrl + Shift + K |
| Comment | Ctrl + / |
| Format document | Shift + Alt + F |
Multi-Cursor & Selection
| Action | Shortcut |
|---|---|
| Add cursor | Ctrl + Alt + ↑/↓ |
| Select next match | Ctrl + D |
| Select all matches | Ctrl + Shift + L |
Navigation
| Action | Shortcut |
|---|---|
| Go to line | Ctrl + G |
| Go to definition | F12 |
| Go back | Alt + ← |
| Find in files | Ctrl + Shift + F |
FAQs
How do I see all shortcuts?
Ctrl + K, Ctrl + S. More in our cheat sheets and VS Code guides.
Can I customize these?
Yes — all shortcuts are remappable.
