About unicode encoder / decoder
Unicode escape sequences such as \u0915 represent characters in source code and JSON. The tool converts text to escapes and back.
Formats
- \uXXXX for characters in the Basic Multilingual Plane.
- A pair of \u escapes (surrogate pair) for emoji and rarer characters in JSON and older JavaScript.
- \u{1F600} in modern JavaScript.
A worked example
The Hindi letter क becomes \u0915, and the emoji 😀 becomes the pair \ud83d\ude00 in JSON, because it lies outside the basic plane. Decoding reverses the process, so you can read text from an escaped JSON response.
Where it is useful
- Reading API responses where non-English text is escaped.
- Embedding special characters in source code that must stay ASCII.
- Checking why a character appears as a box or a question mark.
Debugging tip
If an API returns text like \u0928\u092e\u0938\u094d\u0924\u0947, paste it here to read the real text, which is नमस्ते. Your own code should parse JSON normally, and the escapes disappear automatically.
