Detect the encoding of unknown text and decode it correctly
Take a string of mojibake or raw bytes, identify whether it is UTF-8, Latin-1, Base64, or URL-encoded, and decode it to readable text.
- 1
When text arrives from an unknown source it may be double-encoded, in a legacy charset, or wrapped in Base64. Guessing the encoding by eye is error-prone — use statistical detection first, then apply the matching decoder.
- 2 Encoding Detector →
Paste the raw text or hex. The tool reports the most likely charset (UTF-8, ISO-8859-1, Shift-JIS, etc.) with a confidence score.
- 3 Charset Reference →
Look up the detected charset to confirm its byte ranges and common use cases before committing to a decode.
- 4 Base64 Decoder →
If detection suggests Base64 (high ratio of [A-Za-z0-9+/=], length multiple of 4), decode here first, then re-run detection on the result.
- 5 URL Decoder →
If the text contains many %XX sequences, URL-decode first, then re-examine the output for a second encoding layer.
Frequently asked questions
- The detector says UTF-8 but the text still looks wrong — what next?
- The text may be double-encoded (e.g. UTF-8 bytes interpreted as Latin-1 then re-encoded). Try decoding as Latin-1 first, then re-encode the result as UTF-8, or look for a Base64/URL layer underneath.
- How reliable is automatic detection?
- Statistical detection is ~95% accurate for common charsets on sufficient text, but short strings or ambiguous byte patterns can fool it. Always sanity-check the decoded output against expected content.
Workflows that solve this
Learn more
Want to understand why?