What ’ and é actually mean
You pasted one of these into a search box because your text, CSV or page suddenly said ’ instead of an apostrophe. It is not a mystery character and not a font problem: it is UTF-8 text that was read as Windows-1252. Each byte of ’ (E2 80 99) is a perfectly valid Windows-1252 character, so nothing errored — you just got three wrong characters. Every row below was produced by running the codecs, not typed from memory.
| What you see | What it was | What happened | Fixable from the text alone? |
|---|---|---|---|
| it’s | it’s | UTF-8 bytes read as Windows-1252 | yes |
| café | café | UTF-8 bytes read as Windows-1252 | yes |
| naïve | naïve | UTF-8 bytes read as Windows-1252 | yes |
| Grüße | Grüße | UTF-8 bytes read as Windows-1252 | yes |
| résumé | résumé | UTF-8 bytes read as Windows-1252 | yes |
| “quotedâ€� | “quoted” | UTF-8 bytes read as Windows-1252 | yes |
| — dash | — dash | UTF-8 bytes read as Windows-1252 | yes |
| €10 | €10 | UTF-8 bytes read as Windows-1252 | yes |
| “Naïve café,â€� she said — €5 | “Naïve café,” she said — €5 | UTF-8 bytes read as Windows-1252 | yes |
| � | (byte 0x81) | UTF-8 bytes read as cp1252, but 0x81 is undefined in cp1252 | only with the original bytes |
| � | (byte 0x8D) | UTF-8 bytes read as cp1252, but 0x8D is undefined in cp1252 | only with the original bytes |
| � | (byte 0x8F) | UTF-8 bytes read as cp1252, but 0x8F is undefined in cp1252 | only with the original bytes |
| â€� | ‐ (byte 0x90) | UTF-8 bytes read as cp1252, but 0x90 is undefined in cp1252 | only with the original bytes |
| â€� | ” (byte 0x9D) | UTF-8 bytes read as cp1252, but 0x9D is undefined in cp1252 | only with the original bytes |
The one case that needs the original bytes
Windows-1252 leaves five byte values undefined: 81 8D 8F 90 9D. They are exactly the bytes that finish the UTF-8 sequences for curly quotes, em dashes and the euro sign, so the text you see often ends with the replacement character � — as in â€�.
Anything decoded as latin-1 instead keeps those bytes (as invisible control characters), so the text is still fully recoverable. Anything decoded as cp1252 has already replaced them — from that string alone the byte is gone. That distinction is why “just reverse the encoding” fails on some files and works on others.
How to get the text back
- In the browser, nothing uploaded: paste the text, or pick a .csv / .xlsx. It tries UTF-8, GB18030, Big5, Shift_JIS, EUC-JP and Windows-1252, and when two readings both come out clean it shows both instead of picking one for you.
- In Python — encode back to bytes, decode as UTF-8:
s = "it’s" fixed = s.encode("cp1252").decode("utf-8") # it’sThis works only when the string still contains every original byte; if it has � you need the file, not the string. - Fix the source: a page or file saved as UTF-8 but served with charset=windows-1252 will keep producing this. Set the header or the file's encoding once and it stops.
Have a file rather than a string?
Send a file up to 1 MB and I fix it and show you the result before you pay: $10 if it reads correctly, nothing if it does not (with the reason). Payment by card or USDC through the uGig page; terms.
Other languages
- 日本語: 縺薙s縺ォ縺。縺ッ の正体
- 中文: 乱码修复