Visual Studio Code (VS Code) is a powerful and versatile code editor, and mastering its shortcuts can greatly enhance your coding efficiency. Here are 50 essential VS Code shortcuts that every developer should know.
General Shortcuts
-
Open Command Palette:
Ctrl+Shift+P
orF1
🎨 -
Quick Open:
Ctrl+P
🔍 -
New Window:
Ctrl+Shift+N
🆕 -
Close Window:
Ctrl+Shift+W
❌
Basic Editing
-
Cut Line:
Ctrl+X
✂️ -
Copy Line:
Ctrl+C
📋 -
Move Line Up/Down:
Alt+Up/Down
🔼🔽 -
Duplicate Line:
Shift+Alt+Up/Down
📑 -
Delete Line:
Ctrl+Shift+K
🗑️ -
Undo:
Ctrl+Z
↩️ -
Redo:
Ctrl+Y
↪️
Navigation
-
Go to File:
Ctrl+P
📁 -
Go to Line:
Ctrl+G
📏 -
Go to Symbol:
Ctrl+Shift+O
🔣 -
Show Problems Panel:
Ctrl+Shift+M
❗ -
Toggle Terminal:
Ctrl+`
⌨️
Search and Replace
-
Find:
Ctrl+F
🔎 -
Replace:
Ctrl+H
🔄 -
Find in Files:
Ctrl+Shift+F
📂 -
Replace in Files:
Ctrl+Shift+H
🗃️
Multi-Cursor and Selection
-
Add Cursor Above/Below:
Ctrl+Alt+Up/Down
⬆️⬇️ -
Select All Occurrences of Current Selection:
Ctrl+Shift+L
🔄 -
Select All Occurrences of Current Word:
Ctrl+F2
💬
File Management
-
New File:
Ctrl+N
🆕 -
Open File:
Ctrl+O
📂 -
Save:
Ctrl+S
💾 -
Save As:
Ctrl+Shift+S
🖫 -
Save All:
Ctrl+K S
🖧 -
Close:
Ctrl+W
❌ -
Close All:
Ctrl+K W
🚪
Code Editing
-
Format Document:
Shift+Alt+F
🖊️ -
Format Selection:
Ctrl+K Ctrl+F
✏️ -
Comment Line:
Ctrl+/
💬 -
Block Comment:
Shift+Alt+A
🗯️
Version Control
-
Open Git:
Ctrl+Shift+G
🗃️ -
Stage Changes:
Ctrl+Shift+S
📝 -
Commit:
Ctrl+Enter
✅
Debugging
-
Start Debugging:
F5
🐞 -
Stop Debugging:
Shift+F5
🛑 -
Step Over:
F10
🔄 -
Step Into:
F11
⬇️ -
Step Out:
Shift+F11
⬆️ -
Toggle Breakpoint:
F9
⛔ -
Show Debug Console:
Ctrl+Shift+Y
🖥️
Integrated Terminal
-
Create New Terminal:
Ctrl+`
➕ -
Kill Terminal:
Ctrl+Shift+`
❌ -
Toggle Terminal:
Ctrl+`
↔️
Extension Management
-
Show Extensions:
Ctrl+Shift+X
🔧 -
Install Extension:
Ctrl+P
, then typeext install
📦 -
Uninstall Extension:
Ctrl+P
, then typeext uninstall
🗑️
Conclusion
Knowing these shortcuts can make your coding experience in VS Code much smoother and more efficient. Start integrating them into your daily workflow and watch your productivity soar! 🚀
Top comments (0)