Cheat sheets

Vim keyboard shortcuts on macOS

Vim runs inside a terminal, so there's no macOS menu bar for Keysi to read. Its shortcuts come from this sheet instead. Hold ⌘ while Vim is in the foreground and they appear.

73 shortcuts · adds to what Keysi reads from the app's own menus · free, and not part of Keysi Pro.

Open in Keysi Don't have Keysi? Download free

Shows this sheet in Keysi's Settings ▸ Shortcuts, where it's already installed.

Modes

ActionKeys
Insert before cursori
Append after cursora
Insert at start of lineI
Append at end of lineA
Open line belowo
Open line aboveO
Visual modev
Visual line modeV
Visual block modeCtrl-v
Replace modeR
Command mode:
Normal modeEsc

Motion

ActionKeys
Left / down / up / righth j k l
Next wordw
Previous wordb
End of worde
Start / end of line0 / $
First non-blank character^
Go to first linegg
Go to last lineG
Go to line n:{n}
Half page down / upCtrl-d / Ctrl-u
Page down / upCtrl-f / Ctrl-b
Previous / next paragraph{ / }
Matching bracket%
Top / middle / bottom of screenH M L
Jump to next characterf{char}

Editing

ActionKeys
Delete characterx
Delete linedd
Delete worddw
Delete to end of lineD
Change linecc
Change wordcw
Yank (copy) lineyy
Yank wordyw
Paste after / beforep / P
Undou
RedoCtrl-r
Repeat last change.
Indent / outdent line>> / <<
Join linesJ
Toggle case~

Search & replace

ActionKeys
Search forward/{pattern}
Search backward?{pattern}
Next / previous matchn / N
Search word under cursor*
Replace in whole file:%s/old/new/g
Replace with confirmation:%s/old/new/gc
Clear search highlight:noh

Windows & splits

ActionKeys
Split horizontally:sp
Split vertically:vs
Split windowCtrl-w s
Split window verticallyCtrl-w v
Move between splitsCtrl-w h j k l
Close splitCtrl-w q
Close all other splitsCtrl-w o
Equalize split sizesCtrl-w =

Buffers & tabs

ActionKeys
List buffers:ls
Next / previous buffer:bn / :bp
Close buffer:bd
New tab:tabnew
Next / previous tabgt / gT

Marks & macros

ActionKeys
Set markm{a}
Jump to mark'{a}
Record macroq{a}
Play macro@{a}
Repeat last macro@@

Save & quit

ActionKeys
Write:w
Quit:q
Write and quit:wq
Quit without saving:q!
Write all:wa
Write if changed and quit:x

Use this sheet

It's already in Keysi. Install the app and hold ⌘ in Vim.

Keysi lists it as Vim in Settings ▸ Shortcuts.

To change it, download the file below and put it in ~/Library/Application Support/Keysi/Sheets/ (Settings ▸ Shortcuts ▸ “Reveal Sheets Folder”). A sheet with the same id replaces the built-in one, so your edits stick. Or use Keysi's editor and skip the JSON.

Matches the program in a terminal's foreground: vim, nvim. Keysi checks the terminal's foreground job, so the sheet appears while you're actually in it.

Download the Vim sheet (JSON) Get Keysi — free

Cheat sheets for other apps