Inserting Unicode Characters in Neovim

Inserting unicode characters into a document can be cumbersome, and for many people the default process is to do a quick web search to find the desired character, then copy and paste it into the document. Neovim provides built-in support for inserting unicode characters, if you already know the codepoint of the character you would like to insert.

To summarize, the steps are:

  1. Start in Insert Mode
  2. Hit Ctrl-V followed by u
  3. Type the codepoint of the character you would like to insert

To demonstrate, suppose we created a simple shopping list, and just bought coffee so we want to insert a check mark to reflect that. We first need to move the cursor into position then check that line off:

Initial Conditions
✕·milk
·coffee
✕·eggs
NORMAL
50%
2:1
 

Now that the cursor is in position, let's type s (substitute) which deletes the character under the cursor and enters insert mode.

Start a substitution
s
✕·milk
·coffee
✕·eggs
INSERT
50%
2:1
 

Next, we hit C-V, followed by u and the Unicode code point we want to insert.

Insert the Unicode
<C-v>u2713
✕·milk
·coffee
✕·eggs
INSERT
50%
2:2
 

Finally, we can hit Esc to return to normal mode and continue editing.

Final Result
<Esc>
✕·milk
·coffee
✕·eggs
NORMAL
50%
2:1