Cipher Table

Binary translator

See your words the way a computer stores them, as ones and zeros. Switch the number system to read the same bytes in hexadecimal, decimal or octal.

Key

How text becomes binary

A computer stores everything as numbers, and stores numbers in binary: base 2, where the only digits are 0 and 1. Each position is worth twice the one to its right:

128  64  32  16   8   4   2   1
  0   1   0   0   1   0   0   0    =  64 + 8  =  72

To store text, every character is given an agreed number. The agreement is ASCII, published in 1963, which numbers the capital letters from 65 (A) to 90 (Z), lower-case letters from 97 to 122, and the digits from 48 to 57. The number 72 is the letter H.

So the binary 01001000 means 72, which means H.

A neat detail: a capital letter and its lower-case form differ by exactly 32, a single bit. A is 01000001; a is 01100001.

The other number systems

The same bytes can be written in other bases, and the selector above switches between them:

System Base H is Used for
Binary 2 01001000 What the hardware actually stores
Octal 8 110 Older systems; file permissions
Decimal 10 72 Humans; ASCII tables
Hexadecimal 16 48 Programmers; colours; memory addresses

Hexadecimal is popular because one hex digit is exactly four bits, so a byte is always two tidy characters.

Beyond English

ASCII has room for only 128 characters. Today’s standard is Unicode, which numbers well over a hundred thousand characters from every writing system, and UTF-8, which stores them as one to four bytes each. UTF-8 was designed so that plain English text is byte-for-byte identical to ASCII. This translator uses UTF-8, so anything you can type will survive the round trip.

Is binary a secret code?

No. It is just a different way of writing the same thing, and any computer or person with a chart can read it. It appears in puzzles because it looks impenetrable. If you want the idea of two-symbol codes with a longer pedigree, see the Baconian cipher of 1605.

Questions people ask

How do I convert binary to text?

Split the binary into groups of eight digits. Each group is one byte; work out its value and look up the character with that number. 01001000 is 72, which is H. Paste binary into the right-hand pane to have it done for you, with or without spaces.

Why are there eight digits per letter?

Eight binary digits (bits) make one byte, the standard unit of computer storage. A byte can hold 256 different values, which is enough for the English alphabet in both cases, digits and punctuation with room to spare.

What is "hello" in binary?

01101000 01100101 01101100 01101100 01101111. In hexadecimal, the same five bytes are 68 65 6c 6c 6f.

Why do emoji and accented letters produce several bytes?

Modern text uses an encoding called UTF-8. Plain English letters take one byte each, but other characters take two, three or four. "é" is two bytes; most emoji are four.