Can You Give Up Your Arrow Keys in Vim?

Disable the arrow keys in vim and you will quickly build better habits for navigating pages, paragraphs, lines and words.

noremap <up> <nop>
noremap <down> <nop>
noremap <left> <nop>
noremap <right> <nop>
inoremap <up> <nop>
inoremap <down> <nop>
inoremap <left> <nop>
inoremap <right> <nop>

You'll never touch the arrow keys again and it'll be for the better. This keeps your fingers on the home row at all times.

  • w   jump by start of words (punctuation considered words)
  • W   jump by words (spaces separate words)
  • e   jump to end of words (punctuation considered words)
  • E   jump to end of words (no punctuation)