Quick Open / Go to File
VS CodeJump to any file in the project by typing part of its name — the fastest way to move around a codebase.
38 shortcuts every developer leans on — in VS Code, JetBrains IDEs, Vim, and the terminal. Each one in plain English, with the Mac and Windows/Linux keys side by side.
Last reviewed:
You don't need to memorise hundreds of bindings. A handful pays for itself within a day: Command Palette (when you forget anything), Quick Open (jump to any file), Go to Definition (read unfamiliar code), Rename Symbol (refactor safely), Select Next Occurrence (edit many spots at once), and Reverse History Search (stop retyping commands). Learn those six first; the rest stick naturally.
macOS vs Windows/Linux: the single biggest difference is the modifier. Where macOS uses ⌘ Cmd, Windows and Linux almost always use Ctrl. So ⌘ P becomes Ctrl + P. The ⌥ Option key on Mac maps to Alt elsewhere, and ⌃ Control on Mac is mostly reserved for terminal and Vim-style bindings (which are the same on every platform).
Comment or uncomment the current line (or selection). Works in any language.
Move the current line (or selected block) up or down without cut-and-paste.
Duplicate the current line above or below the original.
Remove the entire current line in one keystroke.
Re-indent and tidy the whole file using the configured formatter (Prettier, gofmt, etc.).
Write every modified file to disk at once.
Vim: delete the current line. Press twice — d then d.
💡 The deleted line goes into the register, so you can paste it back with p.
Vim: copy ("yank") the current line into the register.
Vim: paste whatever is in the register after the cursor.
💡 Uppercase P pastes before the cursor instead.
Vim: delete the word under the cursor and drop straight into insert mode to retype it.
Vim: save the file and close the editor. The legendary "how do I exit Vim" answer.
💡 :q! quits without saving; ZZ is a shorthand for write-and-quit.
Add the next match of the current word to your selection so you can edit several at once.
💡 Press repeatedly to grab more matches. ⌘⇧L / Ctrl+Shift+L selects every occurrence at once.
Stack extra cursors on the lines above or below to type the same thing on many lines.
Drop an additional cursor anywhere you click while holding the modifier.
Rename a variable, function, or class everywhere it is used — safely, across the project.
💡 This is rename-aware, not find-and-replace — it understands scope and won't touch unrelated strings.
Open the lightbulb menu of suggested fixes and refactorings for the code under the cursor.
Pull selected code out into its own method or variable. A JetBrains staple of clean refactoring.
💡 In JetBrains, ⌃T (Mac) opens the Refactor This menu; Ctrl+Alt+M extracts a method directly on Win/Linux.
Search the whole project for a string or pattern, with replace-in-files support.
Launch the debugger, or resume execution until the next breakpoint.
Set or clear a breakpoint on the current line so execution pauses there.
Run the current line and stop on the next one, without descending into function calls.
Descend into the function call on the current line to debug it line by line.
Finish the current function and return to the caller.
Show or hide the terminal panel inside the editor.
Stop the running command — send an interrupt signal to whatever is in the foreground.
Search backwards through your command history as you type. Saves retyping long commands.
💡 Press ⌃R again to cycle to older matches.
Jump the cursor to the beginning (Ctrl+A) or end (Ctrl+E) of the command line.
Wipe the terminal screen, keeping the current command line intact.
💡 Equivalent to typing clear, but instant and non-destructive to your typed line.
Complete a file name, command, or path. Press twice to list all matches.
Delete the word to the left of the cursor on the command line.
Rename Symbol is scope-aware: it understands that the thing under your cursor is a specific variable, function, or class, and only renames actual references to that symbol across the project. A plain find-and-replace matches text blindly, so it can rename unrelated identifiers that happen to share the same string, or miss references that are formatted differently — Rename Symbol will not.
Select Next Occurrence adds one more match to your selection each time you press it, so you can review and skip matches individually as you go. Select All Occurrences (Cmd+Shift+L on Mac, Ctrl+Shift+L on Windows/Linux) instead grabs every match in the file immediately, which is faster when you already know you want to edit all of them.
Step Over runs the current line and stops on the next one without descending into any function calls on that line. Step Into does the opposite — it follows execution down into a function call so you can debug it line by line. Step Out finishes executing the current function entirely and returns control to whichever line called it.
The Command Palette lets you search for and run any command the editor supports by typing its name, rather than requiring you to remember a specific key combination. It is most valuable as a fallback: if you forget a shortcut (or one has been rebound), the Command Palette is the fastest way to find and trigger it anyway.
`dd` deletes the current line, `yy` copies ("yanks") the current line into the register without deleting it, and `p` pastes whatever is currently in the register after the cursor. Because `dd` places the deleted line into the same register, you can immediately paste it back elsewhere with `p` — deletion in Vim doubles as cut.
`:wq` writes (saves) the file and then quits the editor. `:q!` quits without saving, discarding any unsaved changes — the `!` forces the quit even though Vim would otherwise warn you about losing edits. Mixing them up is a common source of accidentally lost changes.
The most common substitution is Cmd on macOS mapping to Ctrl on Windows/Linux — so Cmd+P becomes Ctrl+P. The Option key on Mac maps to Alt elsewhere. The Mac Control key is the exception: it does not map to Ctrl on Windows/Linux in the same way, since it is mostly reserved for terminal and Vim-style bindings, which are already identical across platforms.
Ctrl+R searches backward through your shell command history incrementally as you type, so you can recall a long command without retyping it — pressing Ctrl+R again cycles to older matches. It works in bash and zsh by default (via readline/zle), though the exact behaviour can differ slightly if you use a different shell or history search plugin.
Extract Method (or Extract Variable) takes a selected block of code and pulls it out into its own named method or variable, replacing the original code with a call to it. It is a refactoring, not just a text edit — the tool rewires the surrounding code so behaviour stays identical, which is why it's considered safer than manually cutting and pasting the code yourself.
Yes — every shortcut, tool mapping, and note on this page is free to read and reference across VS Code, JetBrains IDEs, Vim, and the terminal.