About Unicode characters in html, xml

Hi! So you probably wonder how to put those special text symbols into HTML? You can do that using Unicode entities. Just copy-pasting the symbols into a HTML, or xml document doesn't work right sometimes. I'll show it to you, and guide you through the whole process of creating symbols straight from your keyboard.

But first you need to know several short basic things.

Things to know


Text encoding systems

Text encoding systems (also called charsets) are standards for numeric representation of text characters. They pair (define) numbers with text symbols. So a certain computer number means the certain text character. Encoding systems are used by all computers right now, because computers store information using numbers.
Humans actually tie characters and symbols to how they sound, or their names. But maybe that is somehow digitally-encoded in our brains as well. Who knows?..

Unicode

Unicode is a text encoding system. It pairs more than 100,000 text characters and symbols with their codes (numbers).

Simple, huh? So now I'll explain the rules of how to put text characters into HTML using these numeric codes. And how to get those codes, also.

Unicode codes table

You can get any Unicode-encoded character's numeric code from official Unicode code charts.

How to make HTML symbol codes

Here are principles inputting HTML symbols by their Unicode code.

  1. If you have a decimal code.

    Write "&#code;" in HTML.
    Example: "ß" stands for "ß".

  2. If you have a hexadecimal code. It should contain numbers and letters from A to F range (should be alpha-numeric). Though it can fully consist of just numbers, or just letters. Like "«" stands for "«".

    Write "&#xcode;" in HTML.
    Example: "ß" stands for "ß".

  3. If the code is HTML shortcut. The code should consist of letters only. If symbol is some kind of word, like "hearts", it's probably a shortcut.

    Write "&code;" in HTML.
    Example: "♥" stands for "♥".
    If it doesn't work, this code may really be hexadecimal, but with leading zero's omitted.

Be aware that you can translate any text symbol's decimal code into hex, and convert any hex code into decimal.
Keep in mind the bad thing, that nowadays not all symbols are supported even by major OS's and browsers.

Special HTML character entities for symbolsHTML entities for special characters that are widely used. And these symbols' names as well.

Character encoding tools

Entity Tool - Escape special HTML & JavaScript character entities
Entity Tool - Escape special HTML & JavaScript character entitiesJavascript tool to convert your text with symbols into HTML, or Javascript character entities. You can insert the whole text and it will just escape special characters, leaving other characters alone. You can leave tags and ampersands unconverted.
Escape, encode and decode URL and URITool to encode, decode and escape URL characters. Encodes your URL's and URI's special chars and text symbols into standard ASCII for maximum validity and compatibility.
Last update 14 years ago

Comments

Question
Great!! Any chance of you telling me how to get a bomb icon for FB? I used wingdings in word capital m but it wont carry over onto Fb :o(
Answer
Yeah, of course it wouldn't. And there's no bomb in standard encodings, so I'm afraid you can't put a bomb there. Anyway, I recommend you read my Facebook name with cool symbol letters article about the Facebook name stuff. =)
css/large.css"> ?>