Skip to main content

Change file encoding in Vim

This is for my own reference, I always forget how to do this..

Once

:w[rite] ++enc=utf-8 [filename]

Persistently

:set fileencoding=utf-8

Now what?

If you’re up for more, here are a few things you can do:

April 2025's Thoughts