Visual Studio Code (VS Code) is a free, lightweight, and extensible source code editor developed by Microsoft, available on Windows, macOS, and Linux. Since its 2015 release it has grown into the most widely used development environment, with built-in IntelliSense, Git integration, a debugging engine, and a rich extension marketplace. In 2025–2026 GitHub Copilot became a core, built-in feature of VS Code, bringing AI agents, multi-file editing, inline chat, custom agents, and fully autonomous agentic workflows directly into the editor. Mastering VS Code means understanding its keyboard shortcuts, command palette, multi-cursor editing, and the expanding set of Copilot AI features—together enabling developers to write, navigate, refactor, and automate code at a pace that traditional workflows cannot match.
What This Cheat Sheet Covers
This topic spans 23 focused tables and 285 indexed concepts, 117 flashcards. Below is a complete table-by-table outline of this topic, spanning foundational concepts through advanced details.
A jump-to index of every table row in this cheat sheet.
An interactive map of every table and concept in this topic.
Table 1: Essential Keyboard Shortcuts
These are the shortcuts that pay for themselves every single day — opening the command palette, jumping to any file or symbol, renaming across a project, and moving or commenting lines without ever reaching for the mouse. If you commit only a handful of VS Code keystrokes to muscle memory, make them these.
| Shortcut | Example | Description | |
|---|---|---|---|
Ctrl+Shift+P (Win/Linux)Cmd+Shift+P (Mac) | • Opens the command palette to access every VS Code command by name • the most important shortcut — use it for any feature you cannot recall. | ||
Ctrl+P (Win/Linux)Cmd+P (Mac) | • Opens the quick file picker to jump instantly to any file by name • supports @ for symbols, : for line numbers, # for workspace symbols. | ||
F12 | • Jumps to the symbol definition under the cursor • works across files when language support is available. | ||
F2 | • Renames the symbol under the cursor across all workspace files • updates all references intelligently. | ||
Ctrl+. (Win/Linux)Cmd+. (Mac) | Opens the code actions menu for errors, warnings, or suggestions at the cursor. | ||
Shift+Alt+F (Win/Linux)Shift+Option+F (Mac) | • Applies the configured code formatter to the entire document • requires a formatter extension. | ||
Ctrl+/ (Win/Linux)Cmd+/ (Mac) | Comments or uncomments the selected lines using the language's single-line comment syntax. | ||
Shift+Alt+A (Win/Linux)Shift+Option+A (Mac) | Comments or uncomments the selection using multi-line comment syntax (e.g., /* ... */). | ||
Alt+F12 (Win/Linux)Option+F12 (Mac) | Opens an inline peek window showing the definition without navigating away from the current file. | ||
Shift+F12 | Shows all references to the symbol across the workspace in a peek panel. | ||
Ctrl+G (Win/Linux)Cmd+G (Mac) | Opens a prompt to jump to a specific line number in the active file. | ||
Ctrl+B (Win/Linux)Cmd+B (Mac) | • Toggles the left sidebar visibility • hides Explorer, Search, Source Control, Extensions. | ||
Ctrl+` (Win/Linux) Cmd+` (Mac) | Opens or hides the integrated terminal at the bottom of the window. | ||
Ctrl+Shift+K (Win/Linux)Cmd+Shift+K (Mac) | Deletes the entire line at the cursor without needing to select it first. | ||
Alt+Up/Down (Win/Linux)Option+Up/Down (Mac) | Moves the current line or selected lines up or down, preserving indentation. | ||
Shift+Alt+Up/Down (Win/Linux)Shift+Option+Up/Down (Mac) | Duplicates the current line or selection above or below the original. | ||
Ctrl+Shift+[ or ] (Win/Linux)Cmd+Option+[ or ] (Mac) | Collapses or expands the code region at the cursor. | ||
Ctrl+K Ctrl+0 / Ctrl+K Ctrl+J (Win/Linux)Cmd+K Cmd+0 / Cmd+K Cmd+J (Mac) | • Folds or unfolds every region in the active file • 0 folds all, J unfolds all. | ||
Ctrl+K S (Win/Linux)Cmd+K S (Mac) | • Saves all open modified files at once • useful before builds or commits. | ||
Ctrl+W (Win/Linux)Cmd+W (Mac) | Closes the currently active editor tab. | ||
Ctrl+Shift+T (Win/Linux)Cmd+Shift+T (Mac) | • Reopens the most recently closed tab • press repeatedly to recover multiple tabs. |