HTML Unicode (UTF-8) Reference

Unicode is a universal character set that defines all the characters needed for writing the majority of living languages in use on computers.

Unicode aims to be (and already is) a superset of all other encoded computer character sets.

The Unicode Standard covers (almost) all characters, punctuations, and symbols in the world and enables processing, storage, and transport of text independent of platform and language.

The Unicode Consortium

The Unicode Consortium develops the Unicode Standard. The goal is to replace existing character sets with UTF (Unicode Transformation Format).

The Unicode Standard is implemented in HTML, XML, JavaScript, E-mail, PHP, Databases and in all modern operating systems and browsers.


The Unicode Character Sets

Unicode can be implemented by different character sets. The most commonly used encodings are UTF-8 and UTF-16:

Charset Description
UTF-8 A variable-length character encoding (1 to 4 bytes long). UTF-8 is backwards compatible with ASCII and the preferred encoding for e-mail and web pages.
UTF-16 A variable-length character encoding. UTF-16 is used in all major operating systems like Windows, IOS, and Unix.

The first 128 characters of UTF-8 have the same binary values as ASCII, making ASCII text valid UTF-8.


The HTML Standard is Unicode UTF-8

The default character set in HTML-4 (ISO-8859-1) were limited in size and not compatible in multilingual environments.

The default character encoding in HTML-5 is UTF-8.

HTML5 pages using a different character set than UTF-8 must specify this a <meta> tag:

Example

<meta charset=”ISO-8859-1″>

Continue reading HTML Unicode (UTF-8) Reference