Convert text to Unicode HTML entities and back
No uploads — conversion happens locally in your browser

Text to Unicode converts ordinary text into Unicode decimal HTML entities (also called numeric character references), like . It also converts those entities back into readable text.
Think of it as a reversible “label maker” for characters: each character becomes a number, wrapped as.
Who is this useful for?
If you frequently transform text for sharing or debugging, you might also like our Text to ASCII binary and Case Converter.
Type or paste your text
Use the “Text to Unicode” box. The output updates instantly.
Copy the Unicode output
Click “Copy unicode to clipboard”. You’ll get a string shaped like .
Convert back when needed
Paste a string containing entities into “Unicode to Text”. Every becomes a character.
Share or reset safely
Use Share/Reset at the bottom. If the input contains sensitive content, avoid sharing links that include results.
How to interpret the output
Each entity is a decimal number. In this tool, the number comes from the JavaScript notion of a character code unit, so a single visible emoji may become two entities.
Example 1: "Hi" → Unicode entities
Input text: . The tool converts each character into.
In the calculator, type in the first box and copy the output.
Example 2: entities → text (mixed input)
Input Unicode string: . Only the matching entities are replaced.
Practical takeaway: you can paste an entire HTML snippet and the tool will replace every decimal entity it recognizes.
1) Preparing a safe HTML demo snippet
Background: you want to show a string in HTML without it being interpreted as markup.
Input:
Result:
How to use it: paste the output into your HTML content area to display the original characters.
2) Debugging “invisible” characters
Background: a string fails to match because it contains a non-breaking space.
Input: a text that visually looks like .
Result: if the space is a non-breaking space, you will see a different number than a normal space.
How to use it: compare the entity numbers to confirm what character is actually present.
3) Sharing a snippet in a support ticket
Background: you need to paste a string that keeps breaking formatting in a ticket.
Input: your problematic line
Result: a compact entity string you can paste anywhere
How to use it: include the entity output plus a short note that it is decimal HTML entities.
4) Quick readability checks for encoding pipelines
Background: you are moving text through systems with uncertain encoding behavior.
Input: a short sample phrase
Result: stable numeric representation you can compare before/after
How to use it: run “text → unicode” on the source and destination to spot changes.
For other ways to represent strings, try Text to ASCII binary for byte-ish representations, or Base64 String Encoder/Decoder for compact transport.
Convert text to entities to see exactly what characters your template is outputting.
Spot non-breaking spaces or odd punctuation by comparing their numeric values.
Share strings safely in docs and tickets without worrying about rendering rules.
Lightly obscure text for casual sharing (not security). Use encryption for real secrecy.
Compare the entity output before/after copying through systems to catch silent changes.
Turn decimal entities back into readable text for quick inspection.
When it might not be the right tool
Practical tips
Pro tip: if the decoded output looks odd, check whether your input actually contains semicolons — works, but will not be recognized by this tool.
The implementation intentionally stays simple. It mirrors the behavior of a common reference tool: split the input into JavaScript “characters” (UTF-16 code units), then wrap each code unit value as a decimal HTML entity.
(decimal numeric character reference per UTF-16 code unit)
Reverse conversion (decoding)
The tool searches for a strict decimal entity pattern and replaces it with the corresponding character.
Variables: is one UTF-16 unit, and is a decimal integer.
Code points vs code units
Unicode assigns a code point to each character (like for “A”). JavaScript strings are stored as UTF-16, which means some characters (notably many emoji) use two 16-bit code units. This tool outputs decimal entities per code unit, not per code point.
HTML numeric character references
HTML supports numeric references like for ©. They can be decimal or hex. This tool focuses on the decimal form because it’s easy to compare and copy.
If your goal is a byte-level representation for debugging encoding boundaries, use Text to ASCII binary (for ASCII-range strings) or Base64 for transport.
Because this tool encodes UTF-16 code units. Some characters are represented as a surrogate pair, which means two 16-bit units, so you’ll see two decimal entities.
No. The output format is decimal HTML entities like .
Not in this tool. It only recognizes the decimal pattern.
Then they won’t be decoded. For example, works, but does not.
It’s reversible and not encryption. For secrets, use Encrypt / Decrypt Text with a key you control.
Yes. The decoder replaces all matching entities in the input. Non-matching text stays the same.
Limitations to keep in mind
Further reading
Note: this page uses decimal entities for readability and compatibility with the tool’s output format.
If you’re looking for code-focused transformations, you may also like our Hash Text tool for fingerprints and comparisons.
Use a simple chronometer (stopwatch) to track elapsed time down to milliseconds. Runs locally in your browser.
Normalize email addresses to a standard format for easier comparison. Useful for deduplication and data cleaning. Runs locally in your browser.
Estimate the time needed to consume a total amount at a constant rate, and get an expected end time. Runs locally in your browser.
Parse and decode your JSON Web Token (JWT) and display its content. All computation runs locally in your browser.
Know which file extensions are associated to a MIME type, and which MIME type is associated to a file extension. Includes a full MIME types table.
Generate random Lorem Ipsum placeholder text with customizable paragraphs, sentences, and word counts. Runs locally in your browser.