Vim keybinds

These are the most useful Vim keybindings:

KeybindingAction
iEnter insert mode
EscExit insert mode
:wSave the file
:qQuit Vim
:wqSave and quit
ddDelete a line
yyCopy (yank) a line
pPaste
uUndo
Ctrl + rRedo
/textSearch for 'text'
nGo to the next search result
xDelete character under the cursor
:set nuShow line numbers
:set nonuHide line numbers
GGo to the end of the file
ggGo to the beginning of the file
:e filenameOpen a new file
:sp filenameOpen a new file in a split window
Ctrl + w + wSwitch between split windows
:vs filenameOpen a new file in a vertical split
0Move to the beginning of the line
$Move to the end of the line
wMove to the beginning of the next word
bMove to the beginning of the previous word
c + motionChange text that motion moves over
vEnter visual mode
VEnter visual line mode
Ctrl + vEnter visual block mode
:Enter command-line mode
.Repeat the last command
:%s/old/new/gReplace all occurrences of 'old' with 'new'
:nohRemove search highlighting
:r !commandRun an external command and insert its output