vimtricks.wiki Concise Vim tricks, one at a time.

How do I disable the error beep in Vim?

Answer

:set belloff=all

Explanation

The belloff=all option disables all error bells and visual bells in Vim. No more beeping when you press Escape or hit an error.

How it works

  • :set belloff=all disables all bells
  • This suppresses both audio beeps and visual flashes
  • Applies to all events that normally trigger a bell

Example

set belloff=all

Tips

  • :set visualbell t_vb= is an older approach (visual bell with empty terminal code)
  • :set noerrorbells disables only error bells
  • belloff was introduced in Vim 8.0
  • Some terminals handle bell silencing independently
  • This is a very common vimrc setting

Next

How do you yank a single word into a named register?