If you’re using VS Code, mastering keyboard shortcuts can significantly enhance your workflow. Instead of relying on menus and mouse clicks, these VS Code shortcuts for Windows let you navigate, edit, and manage your code more efficiently. Below is a comprehensive list of essential VS Code shortcuts for Windows to help you boost productivity.
General Shortcuts
These shortcuts help with general navigation and quick access to essential features.
- Ctrl + Shift + P or F1: Is used to open the Command Palette, where you can search for and run different commands.
- Ctrl + P: Is used to quickly search for and open files by typing their name.
- Ctrl + Shift + N: Is used to open a new VS Code window.
- Ctrl + Shift + W: Is used to close the current VS Code window.
Basic Editing
Writing and editing code? These shortcuts will make your life easier.
- Ctrl + X: Is used to cut the entire line without needing to select anything.
- Ctrl + C: Is used to copy the entire line without needing to highlight.
- Ctrl + V: Is used to paste the copied or cut content.
- Ctrl + Z: Is used to undo your last action.
- Ctrl + Y: Is used to redo the action you just undid.
- Ctrl + Shift + K: Is used to delete the entire line.
- Ctrl + Enter: Is used to insert a new line directly below the current one.
- Ctrl + Shift + Enter: Is used to insert a new line above the current one.
- Ctrl + Shift + \: Is used to jump to the matching bracket, helpful for navigating code blocks.
- Ctrl + /: Is used to quickly comment or uncomment the current line.
- Shift + Alt + A: Is used to toggle a block comment around the selected code.
- Alt + Up/Down Arrow: Is used to move the current line up or down.
- Shift + Alt + Up/Down Arrow: Is used to duplicate the line and move the copy up or down.
- Ctrl + D: Is used to select the next occurrence of the highlighted word.
- Ctrl + L: Is used to highlight the entire current line.
- Ctrl + Shift + L: Is used to select all instances of the current selection.
- Ctrl + F2: Is used to select every occurrence of the word under the cursor.
Search and Replace
Finding and replacing text has never been easier.
- Ctrl + F: Is used to open the search bar to find text within the current file.
- Ctrl + H: Is used to open the replace bar to find and replace text within the file.
- F3 / Shift + F3: Is used to find the next or previous occurrence of your search term.
- Ctrl + Shift + F: Is used to search for text across all files in your project.
- Ctrl + Shift + H: Is used to replace text across all files in your project.
Multi-Cursor and Selection
Want to edit multiple lines at once? These shortcuts will help!
- Alt + Click: Is used to add a new cursor wherever you click, allowing you to type in multiple places at once.
- Ctrl + Alt + Up/Down Arrow: Is used to add a new cursor directly above or below the current one.
- Ctrl + Shift + Left/Right Arrow: Is used to select text one word at a time.
- Shift + Alt + Right/Left Arrow: Is used to expand or reduce the selected text.
Navigation
Jump around your code effortlessly with these shortcuts.
- Ctrl + T: Is used to show all symbols (like functions or variables) in the file so you can jump to them.
- Ctrl + G: Is used to jump to a specific line number.
- Ctrl + Shift + O: Is used to quickly navigate to any symbol in the current file.
- Ctrl + -: Is used to go back to the previous location of your cursor.
- Ctrl + Shift + -: Is used to move forward to the next location of your cursor.
- F12: Is used to jump directly to the definition of the symbol you’re focused on.
- Alt + F12: Is used to peek at the definition without leaving the current file.
- Ctrl + K, Ctrl + I: Is used to show a tooltip with more information about the symbol under your cursor.
- Ctrl + B: Is used to hide or show the sidebar.
- Ctrl + Shift + E: Is used to open the Explorer, which lets you browse files in your project.
- Ctrl + Shift + G: Is used to open the Source Control view for managing version control (like Git).
- Ctrl + Shift + D: Is used to open the Debug panel to manage and run debugging configurations.
- Ctrl + Shift + X: Is used to open the Extensions panel, where you can install and manage extensions.
- Ctrl + Shift + U: Is used to open the Output panel to see logs and output from running processes.
- Ctrl + `: Is used to open or hide the terminal at the bottom of VS Code.
File Management
Efficiently manage your files without using the mouse.
- Ctrl + N: Is used to create a new empty file.
- Ctrl + O: Is used to open an existing file.
- Ctrl + S: Is used to save the current file.
- Ctrl + Shift + S: Is used to save the current file with a new name.
- Ctrl + K, Ctrl + S: Is used to save all currently open files.
- Ctrl + W: Is used to close the current file.
- Ctrl + Shift + T: Is used to reopen the last closed file.
- Ctrl + K, Ctrl + W: Is used to close all open files.
Integrated Terminal
Handle your terminal like a pro.
- Ctrl + `: Is used to open or hide the integrated terminal.
- Ctrl + Shift + `: Is used to create a new terminal instance.
- Ctrl + C: Is used to copy the selected text in the terminal.
- Ctrl + V: Is used to paste text into the terminal.
- Ctrl + Arrow Up/Down: Is used to scroll through the terminal output history.
- Ctrl + K: Is used to clear the terminal output.
Debugging
Debug your code with precision.
- F9: Is used to add or remove a breakpoint on the current line, pausing execution during debugging.
- F5: Is used to start or resume the debugging process.
- Shift + F5: Is used to stop the debugging session.
- F11: Is used to step into the next function call during debugging.
- Shift + F11: Is used to step out of the current function during debugging.
- F10: Is used to step over the next function call.
Window Management
Organize your VS Code workspace effectively.
- Ctrl + `: Is used to open or hide the terminal window.
- Ctrl + 1 / 2 / 3: Is used to switch focus to editor group 1, 2, or 3.
- Ctrl + K, Ctrl + Left/Right Arrow: Is used to move between different editor groups.
- Ctrl + Shift + P: Is used to open the Command Palette to search for commands and execute them.


For more productivity tips and coding resources, visit my website DesignWithRehana or check out my YouTube channel for in-depth tutorials and demonstrations.