Fix garbled characters like é and ’ in a CSV
When a UTF-8 file is read as Windows-1252, é becomes é and an apostrophe becomes ’. Repair it in your browser without uploading the file.
Characters like é, ü or ’ in a file are almost always the same accident: the text was saved as UTF-8 and then opened as if it were Windows-1252 (or Latin-1). Each accented letter is two or three bytes in UTF-8, and Windows-1252 shows each byte as its own character. This is often called mojibake.
Common examples
éshows asé,üasü,ñasñ- a curly apostrophe
’shows as’, and“ ”as“ †€shows as€,£as£
Stopping it in Excel
If the file itself is fine and only Excel shows it wrong, import it instead of double-clicking it: Data, From Text/CSV, and choose UTF-8 as the file origin. Saving the file with a UTF-8 byte order mark (BOM) at the start also makes Excel read it as UTF-8. The tool below can add one when you download.
When the garbage is already in the file
If someone saved the file after it was misread, the broken characters are now real text and need converting back. The tool finds runs of characters that look like misread UTF-8, turns them back into their original bytes and decodes those properly. If a run does not decode as valid UTF-8, it is left alone, so correct text such as SÃO PAULO or AÑO is not touched. The sample includes one of those.