Dark mode switch icon Light mode switch icon

Converting Text From Unicode To Ascii

1 min read

Just had to convert some text files from Unicode to ASCII and used Vim to do it:

Open each file and notice that vim says [converted] at the bottom, indicating that it has transparently opened the unicode file to let you edit that file.

On each file, change the file encoding setting to latin1 (basic ASCII):

Then save the file and it will be converted:

FYI, The vim docs note that changing the “encoding” setting does not affect existing text so that won’t work.

Originally published on by Jason Axley