The Computer Oracle

Converting the encoding of a text file (Mac OS X)

Become or hire the top 3% of the developers on Toptal https://topt.al/25cXVn

--

Music by Eric Matyas
https://www.soundimage.org
Track title: Quiet Intelligence

--

Chapters
00:00 Question
00:35 Accepted answer (Score 122)
00:48 Thank you

--

Full question
https://superuser.com/questions/151981/c...

Question links:
[How can I convert multiple files to UTF-8 encoding using *nix command line tools?]: https://superuser.com/questions/16672/ho...
[detect the encoding]: https://superuser.com/questions/151972/d...

--

Content licensed under CC BY-SA
https://meta.stackexchange.com/help/lice...

--

Tags
#macos #conversion #characterencoding

#avk47



ACCEPTED ANSWER

Score 125


Use iconv:

iconv -f iso-8859-1 -t utf-8 < file > file.new