Detect Encoding Php Online

If you detect that the string is valid UTF-8 but looks wrong, you might need to detect if it was double-encoded.

Since automatic detection is never 100% reliable—similar to "decoding an encrypted string without the key"—developers should follow these guidelines: Detect encoding in PHP without multibyte extension? detect encoding php