
Shortcut Key Assignments for Zed Editor
Here is a summary of the shortcut key assignments for "Zed Editor," a new editor being developed by the creator of Atom.
Posted at: 2024.7.23
Table Of Contents
Common Shortcuts
First are the common shortcut key assignments.
Basic editor operations are supplemented with Emacs-style shortcuts, making these assignments familiar to users of Atom, Visual Studio Code, and similar editors.
| Command | Shortcut Key Assignment |
|---|---|
| Add selection above | ⌘ + Alt + Up |
| Add selection above | ⌘ + Control + P |
| Add selection below | ⌘ + Alt + Down |
| Add selection below | ⌘ + Control + N |
| Backspace | Backspace |
| Backspace | Control + H |
| Backspace | Shift + Backspace |
| Cancel | Escape |
| Show code actions | Enter |
| Confirm completion | Enter |
| Confirm completion | Tab |
| Confirm rename | Enter |
| First in context menu | Page Up |
| Last in context menu | Page Down |
| Next in context menu | Control + N |
| Next in context menu | Down |
| Previous in context menu | Control + P |
| Previous in context menu | Up |
| Copy | ⌘ + C |
| Cut | ⌘ + X |
| Cut to end of line | Control + K |
| Delete | Control + D |
| Delete | Delete |
| Delete line | ⌘ + Shift + K |
| Delete to start of line | ⌘ + Backspace |
| Delete to end of line | ⌘ + Delete |
| Delete to end of next subword | Control + Alt + D |
| Delete to end of next subword | Control + Alt + Delete |
| Delete to end of next word | Alt + D |
| Delete to end of next word | Alt + Delete |
| Delete to start of previous subword | Control + Alt + Backspace |
| Delete to start of previous subword | Control + Alt + H |
| Delete to start of previous word | Alt + Backspace |
| Delete to start of previous word | Alt + H |
| Delete to start of previous word | Control + W |
| Show cursor name | Control + ⌘ + C |
| Duplicate line below | Alt + Shift + Down |
| Duplicate line above | Alt + Shift + Up |
| Find all references | Alt + Shift + F12 |
| Fold | Alt + ⌘ + [ |
| Format | ⌘ + Shift + I |
| Go to definition | F12 |
| Split and show definition | Alt + F12 |
| Go to diagnostic | F8 |
| Go to implementation | Shift + F12 |
| Go to previous diagnostic | Shift + F8 |
| Go to type definition | ⌘ + F12 |
| Split and show type definition | Alt + ⌘ + F12 |
| Hover | ⌘ + K, ⌘ + I |
| Indent | ⌘ + ] |
| Join lines | Control + J |
| Move down | Control + N |
| Move down | Down |
| Move left | Control + B |
| Move left | Left |
| Move line down | Alt + Down |
| Move line up | Alt + Up |
| Move page down | Control + V |
| Move page down | Shift + Page Down |
| Move page up | Alt + V |
| Move page up | Shift + Page Up |
| Move right | Control + F |
| Move right | Right |
| Move to beginning of line | ⌘ + Up |
| Move to line start | Control + A |
| Move to line start | Home |
| Move to line start | ⌘ + Left |
| Move to matching bracket | Control + M |
| Move to end of line | ⌘ + Down |
| Move to end of line | Control + E |
| Move to end of line | End |
| Move to end of line | ⌘ + Right |
| Move to end of paragraph | Control + Down |
| Move to end of next subword | Control + Alt + F |
| Move to end of next subword | Control + Alt + Right |
| Move to end of next word | Alt + F |
| Move to end of next word | Alt + Right |
| Move to start of previous subword | Control + Alt + B |
| Move to start of previous subword | Control + Alt + Left |
| Move to start of previous word | Alt + B |
| Move to start of previous word | Alt + Left |
| Move to start of paragraph | Control + Up |
| Move up | Control + P |
| Move up | Up |
| Next screen | Control + L |
| Outdent | ⌘ + [ |
| Page down | Page Down |
| Page up | Page Up |
| Paste | ⌘ + V |
| Redo | ⌘ + Shift + Z |
| Redo selection | ⌘ + Shift + U |
| Rename | F2 |
| Reveal in file manager | Alt + ⌘ + R |
| Toggle hunk diff | ⌘ + ' |
| Expand all hunk diffs | ⌘ + " |
| Revert selected hunk | ⌘ + Alt + Z |
| Select all | ⌘ + A |
| Select all matches | ⌘ + Shift + L |
| Select down | Control + Shift + N |
| Select down | Shift + Down |
| Select larger syntax node | Control + Shift + Right |
| Select left | Control + Shift + B |
| Select left | Shift + Left |
| Select line | ⌘ + L |
| Select next | ⌘ + D |
| Select next | ⌘ + K, ⌘ + D |
| Select previous | Control + ⌘ + D |
| Select previous | ⌘ + K, Control + ⌘ + D |
| Select right | Control + Shift + F |
| Select right | Shift + Right |
| Select smaller syntax node | Control + Shift + Left |
| Select to beginning of document | ⌘ + Shift + Up |
| Select to line start | Control + Shift + A |
| Select to line start | Shift + Home |
| Select to line start | ⌘ + Shift + Left |
| Select to line end | ⌘ + Shift + Down |
| Select to line end | Control + Shift + E |
| Select to line end | Shift + End |
| Select to line end | ⌘ + Shift + Right |
| Select to end of paragraph | Control + Shift + Down |
| Select to end of next subword | Control + Alt + Shift + F |
| Select to end of next subword | Control + Alt + Shift + Right |
| Select to end of next word | Alt + Shift + F |
| Select to end of next word | Alt + Shift + Right |
| Select to start of previous subword | Control + Alt + Shift + B |
| Select to start of previous subword | Control + Alt + Shift + Left |
| Select to start of previous word | Alt + Shift + B |
| Select to start of previous word | Alt + Shift + Left |
| Select to start of paragraph | Control + Shift + Up |
| Select up | Control + Shift + P |
| Select up | Shift + Up |
| Show character palette | Control + ⌘ + Space |
| Show completion | Control + Space |
| Show inline completion | Alt + \ |
| Tab | Tab |
| Previous Tab | Shift + Tab |
| Toggle code actions | ⌘ + . |
| Toggle comment | ⌘ + / |
| Toggle Git Blame | ⌘ + Alt + G, B |
| Toggle line numbers | ⌘ + ; |
| Transpose | Control + T |
| Undo | ⌘ + Z |
| Undo selection | ⌘ + U |
| Unfold | Alt + ⌘ + ] |
Editor
Next are the shortcut key assignments exclusive to the editor.
There are many special operations, so it may be difficult to memorize them all, but if you remember them by the initial key such as "Ctrl," "Alt," or "⌘," it will be relatively easier.
By mastering these shortcuts, you can dramatically speed up your editor operations.
| Command | Shortcut Key Assignment |
|---|---|
| Add selection above | ⌘ + Alt + Up, ⌘ + Control + P |
| Add selection below | ⌘ + Alt + Down, ⌘ + Control + N |
| Backspace | Backspace, Control + H, Shift + Backspace |
| Cancel | Esc |
| Show code actions | Enter |
| Confirm completion | Enter, Tab |
| Delete line | ⌘ + Shift + K |
| Delete to start of line | ⌘ + Backspace |
| Delete to end of line | ⌘ + Delete |
| Go to type definition | ⌘ + F12 |
| Hover | ⌘ + K, ⌘ + I |
| Format | ⌘ + Shift + I |
| Move to beginning of line | ⌘ + Up |
| Move to end of line | ⌘ + Down |
| Indent | ⌘ + ] |
| Outdent | ⌘ + [ |
| Redo | ⌘ + Shift + Z |
| Redo selection | ⌘ + Shift + U |
| Toggle hunk diff | ⌘ + ' |
| Expand all hunk diffs | ⌘ + " |
| Revert selected hunk | ⌘ + Alt + Z |
| Select all | ⌘ + A |
| Select all matches | ⌘ + Shift + L |
| Toggle code actions | ⌘ + . |
| Toggle comment | ⌘ + / |
| Toggle Git Blame | ⌘ + Alt + G, B |
| Toggle line numbers | ⌘ + ; |
| Undo | ⌘ + Z |
| Undo selection | ⌘ + U |
| Delete to end of next word | Alt + D, Alt + Delete |
| Delete to start of previous word | Alt + Backspace, Alt + H, Control + W |
| Duplicate line | Alt + Shift + Down (down), Alt + Shift + Up (up) |
| Find all references | Alt + Shift + F12 |
| Fold | Alt + ⌘ + [ |
| Split and show type definition | Alt + ⌘ + F12 |
| Split and show definition | Alt + F12 |
| Move line | Alt + Down (down), Alt + Up (up) |
| Move to end of next word | Alt + F, Alt + Right |
| Move to start of previous word | Alt + B, Alt + Left |
| Show inline completion | Alt + \ |
| Unfold | Alt + ⌘ + ] |
| Reveal in file manager | Alt + ⌘ + R |
| Delete to end of next subword | Control + Alt + D, Control + Alt + Delete |
| Delete to start of previous subword | Control + Alt + Backspace, Control + Alt + H |
| Show cursor name | Control + ⌘ + C |
| Cut to end of line | Control + K |
| Delete | Control + D, Delete |
| Join lines | Control + J |
| Move down | Control + N, Down |
| Move left | Control + B, Left |
| Move page | Control + V (down), Shift + Page Down (down), Alt + V (up), Shift + Page Up (up) |
| Move right | Control + F, Right |
| Move to line start | Control + A, Home, ⌘ + Left |
| Move to matching bracket | Control + M |
| Move to end of line | Control + E, End, ⌘ + Right |
| Move to end of paragraph | Control + Down |
| Move to end of next subword | Control + Alt + F, Control + Alt + Right |
| Move to start of paragraph | Control + Up |
| Move up | Control + P, Up |
| Next screen | Control + L |
| Move to start of previous subword | Control + Alt + B, Control + Alt + Left |
| Show character palette | Control + ⌘ + Space |
| Show completion | Control + Space |
| Transpose | Control + T |
| Go to definition | F12 |
| Go to diagnostic | F8 |
| Go to implementation | Shift + F12 |
| Go to previous diagnostic | Shift + F8 |
| Move page | Page Down (down), Page Up (up) |
| Rename | F2 |
| Tab | Tab, Shift + Tab (previous Tab) |
Pane Operations
These are shortcut key assignments for pane operations, unique to multi-pane editors.
By mastering these, you can greatly reduce the need for mouse or trackpad operations.
| Command | Shortcut Key Assignment |
|---|---|
| Activate item 1 | Control + 1 |
| Activate item 2 | Control + 2 |
| Activate item 3 | Control + 3 |
| Activate item 4 | Control + 4 |
| Activate item 5 | Control + 5 |
| Activate item 6 | Control + 6 |
| Activate item 7 | Control + 7 |
| Activate item 8 | Control + 8 |
| Activate item 9 | Control + 9 |
| Activate last item | Control + 0 |
| Activate next item | Alt + ⌘ + Right, ⌘ + } |
| Activate previous item | Alt + ⌘ + Left, ⌘ + { |
| Close active item | ⌘ + W |
| Close all items | ⌘ + K, ⌘ + W |
| Close clean items | ⌘ + K, U |
| Close inactive items | Alt + ⌘ + T |
| Back | Control + - |
| Forward | Control + _ |
| Reopen closed item | ⌘ + Shift + T |
| Split down | ⌘ + K, Down |
| Split left | ⌘ + K, Left |
| Split right | ⌘ + K, Right |
| Split up | ⌘ + K, Up |
Search
Zed offers powerful search features compared to other editors. Most shortcuts are based on Alt + ⌘, so once you get used to them, you can master them quickly.
| Command | Shortcut Key Assignment |
|---|---|
| Toggle filter | Alt + ⌘ + F |
| Toggle focus | ⌘ + F, ⌘ + Shift + F |
| Enable regex mode | Alt + ⌘ + G |
| Enable text mode | Alt + ⌘ + X |
| Cycle mode | Alt + Tab |
| Select all matches | Alt + Enter |
| Select next match | ⌘ + G |
| Select previous match | ⌘ + Shift + G |
| Toggle case sensitivity | Alt + ⌘ + C |
| Toggle replace | ⌘ + Shift + H |
| Toggle all words | Alt + ⌘ + W |
| Close inactive tabs and panes | Control + Alt + ⌘ + W |
Workspace
These are shortcut key assignments for the entire workspace.
Shortcuts related to moving between panes, activating panes, and terminal operations are the main focus. Many of these are frequently used, so be sure to master them.
| Command | Shortcut Key Assignment |
|---|---|
| Activate pane 1 | ⌘ + 1 |
| Activate pane 2 | ⌘ + 2 |
| Activate pane 3 | ⌘ + 3 |
| Activate pane 4 | ⌘ + 4 |
| Activate pane 5 | ⌘ + 5 |
| Activate pane 6 | ⌘ + 6 |
| Activate pane 7 | ⌘ + 7 |
| Activate pane 8 | ⌘ + 8 |
| Activate pane 9 | ⌘ + 9 |
| Activate pane below | ⌘ + K, ⌘ + Down |
| Activate pane to the left | ⌘ + K, ⌘ + Left |
| Activate pane to the right | ⌘ + K, ⌘ + Right |
| Activate pane above | ⌘ + K, ⌘ + Up |
| Close all docks | Alt + ⌘ + Y |
| New file | ⌘ + N |
| New terminal | Control + ~ |
| New window | ⌘ + Shift + N |
| Save | ⌘ + S |
| Save all | ⌘ + Alt + S |
| Save as | ⌘ + Shift + S |
| Save without formatting | ⌘ + K, S |
| Swap pane in direction | ⌘ + K, Shift + Down / Left / Right / Up |
| Toggle bottom dock | ⌘ + J |
| Toggle left dock | ⌘ + B |
| Toggle right dock | ⌘ + R |
| Unfollow | Escape |