VS Code Keyboard Shortcuts: 30+ Time-Savers Every Developer Should Know

If you write code for a living — or just tinker on weekends — you probably spend more waking hours inside your code editor than almost anywhere else. Yet most of us lean on the same five shortcuts and reach for the mouse for everything else. Today that changes. This guide covers the VS Code keyboard shortcuts that genuinely speed up real work: moving lines without selecting them, editing in several places at once, and jumping between files without ever touching the trackpad. The shortcuts below use Ctrl; if your keyboard has a Cmd key, use that instead — and Option wherever you see Alt.

Why Learn VS Code Shortcuts at All?

It comes down to flow. Every time you leave the keyboard to hunt through menus, your brain switches modes: find the cursor, scan the menu, click, find your place again. Each trip feels tiny, but multiply it by a few hundred repetitions a day and you are losing real time and real momentum. Keyboard shortcuts keep your hands where the work actually happens. The payoff:

  • Fewer context switches. Your eyes never leave the code.
  • Faster refactoring. Multi-cursor editing turns ten careful edits into one.
  • Less physical fatigue. Hundreds of mouse trips a day add up.
  • Reliable muscle memory. Fingers on autopilot beat menu-hunting every time.

Start Here: The Command Palette and Quick Open

If you memorize only two shortcuts from this entire post, make it these two:

  • Ctrl+Shift+P — opens the Command Palette, a searchable list of every command in the editor. Settings, formatting, version-control actions, extension commands: if the editor can do it, you can type its name and hit Enter.
  • Ctrl+P — Quick Open. Start typing a file name and jump straight to it. No sidebar scrolling, no folder digging.

Here is the pro move: Quick Open accepts prefixes. Type @ to jump to a symbol in the current file, : plus a number to jump to a line, or > to flip Quick Open into the Command Palette. One shortcut, four superpowers.

Editing Shortcuts That Do the Heavy Lifting

These are the daily workhorses. Use them for a week and they will feel like breathing:

  • Alt+Up / Alt+Down — move the current line or selection up or down. Perfect for reordering code, list items, or config blocks.
  • Shift+Alt+Up / Shift+Alt+Down — duplicate the current line instantly.
  • Ctrl+Shift+K — delete the entire line, no selecting required.
  • Ctrl+Enter — insert a new line below no matter where the cursor sits in the line. Add Shift to insert above.
  • Ctrl+/ — toggle a line comment. Shift+Alt+A — toggle a block comment.
  • Ctrl+[ / Ctrl+] — indent or outdent the current line or selection.
  • Shift+Alt+F — format the whole document in one shot.

Multi-Cursor Magic: Edit Many Places at Once

This is the feature that converts people. Instead of making the same edit ten times, you place ten cursors and make it once:

  • Ctrl+D — selects the word under the cursor. Press it again to add the next occurrence of that word to your selection. Keep tapping until you have them all, then type your replacement a single time.
  • Ctrl+Shift+L — select every occurrence of the current selection in one move.
  • Ctrl+Alt+Up / Ctrl+Alt+Down — add a cursor directly above or below. Ideal for editing a column of similar values.
  • Alt+Click — drop a cursor anywhere you click.
  • Ctrl+U — undo the last cursor when you add one too many.

Real-world example: you have named a variable userEmail in twelve places and the spec changes. Select it, hit Ctrl+Shift+L, type customerEmail, done — with no find-and-replace anxiety about matching the wrong thing.

Navigate Like You Mean It

  • Ctrl+G — jump straight to a line number.
  • Ctrl+Shift+O — jump to a symbol (function, class, or heading) in the current file.
  • F12 — go to a function’s definition. Alt+F12 — peek at it in a popup without leaving your spot.
  • F2 — rename a symbol everywhere it is used, safely, across the file.
  • Ctrl+Tab — cycle through your open editors like browser tabs.
  • Ctrl+Shift+F — search across your entire project, with results grouped by file.

Panels, Terminals, and Split Screens

Once your editing is fast, stop letting window management slow you down:

  • Ctrl+` (the backtick above Tab) — toggle the integrated terminal. This one shortcut alone saves thousands of window switches a year.
  • Ctrl+B — show or hide the sidebar.
  • Ctrl+\ — split the editor side by side.
  • Ctrl+1 / Ctrl+2 / Ctrl+3 — jump between editor groups.
  • Ctrl+Shift+E — focus the file explorer. Ctrl+Shift+G — source control. Ctrl+Shift+X — extensions.
  • Ctrl+K, then Z — Zen Mode, for when you need the whole screen and nothing else.

Build Your Own Shortcuts

The best shortcut is the one that fits your workflow. Press Ctrl+K Ctrl+S to open the keyboard shortcuts editor — a searchable list of every command, where you can:

  • Double-click any action to assign it a new keybinding.
  • Search by the keys you already use to spot conflicts before they bite.
  • Bind commands from your favorite extensions, so plugins get hotkeys too.

A good rule of thumb: if you have done something more than three times today, give it a shortcut.

Do Not Memorize — Build Muscle Memory

Here is the honest truth: reading a list of shortcuts changes nothing. Doing changes everything. Pick three from this post — I would suggest Ctrl+D, Alt+Up/Down, and Ctrl+` — and force yourself to use them for one week. Ban the mouse for those specific actions, even when it feels slower at first. Once they are automatic, come back and grab three more.

When you are ready for the next batch, head over to ShortcutKings.com. We have shortcut guides, printable cheat sheets, and app-by-app tutorials for everything from spreadsheets to design tools. Bookmark us, and make the mouse work for you — instead of the other way around.