ASCII, ISO 8859–1, UCS, and UTF

Introduction to Character Encoding

In this article, we will learn about popular character encoding schemes and how we can use them in real life.

Uday Hiwarale
Published in
32 min readNov 15, 2019



The encoding by definition is a way to convert data from one format to another. When we have some text (sequence of characters) and we want to either store it inside a computer (machine) or transfer over a digital network, we need to convert it to binary representation because that’s the only language a binary-based computer can understand.

A character encoding is a way to convert text data into binary numbers. In nutshell, we can assign unique numeric values to specific characters and convert those numbers in binary language. These binary numbers later can be converted back to original characters based on their values.

Before we begin, let’s understand a few terminologies first.

Binary to Hex representation

The binary number system is very similar to the decimal number system but we have only 0 an 1 to represent a number. This YouTube video explains how we can convert a decimal number to the binary number. You can also convert a binary number to the decimal number, follow this tutorial.

The hexadecimal number system is also similar to the decimal number system but we have 16 characters to play with, from 0–9 and A-F. To convert a binary to the hexadecimal number, we need to get the decimal value of the binary number and convert it to the hexadecimal number. Follow this video tutorial to understand decimal to hexadecimal conversion.

In a nutshell, the hexadecimal number has the base of 16. This means a single character of the hexadecimal number system is enough to represent values between 0–15. Similarly, in the decimal number system (base 10), a single character can represent a value between 0–9 while in the binary number system (base 2), a single character can represent a value between 0–1.

Since a single character of hexadecimal represents a value between 0 and 15, and similarly, a binary 4-bit number holds a value between 0 and 15, we can use them interchangeably.