Code

Text to Binary Converter

Paste any text and get its binary code, one 8-bit byte per character. This is the encode-only view for when you specifically want text turned into ones and zeros.

text-to-binary.decode
Text
Binary

01001000 01100101 01101100 01101100 01101111

Everything happens in your browser. Use it to make a secret note, decorate a project, or simply see how the computer stores the words you type.

How the Text to Binary works

Each character is looked up in ASCII to get a number, then that number is written in base 2 and padded to 8 digits. Spaces separate the bytes so the result stays readable.

Because it is a direct one-to-one mapping, the same input always produces the same binary. Nothing is random and nothing is lost.

Examples

Yes
01011001 01100101 01110011
42
00110100 00110010
Digits are characters too.
OK!
01001111 01001011 00100001

Text to Binary chart

Every letter at a glance. Use it to read or write by hand.

A
01000001
B
01000010
C
01000011
D
01000100
E
01000101
F
01000110
G
01000111
H
01001000
I
01001001
J
01001010
K
01001011
L
01001100
M
01001101
N
01001110
O
01001111
P
01010000
Q
01010001
R
01010010
S
01010011
T
01010100
U
01010101
V
01010110
W
01010111
X
01011000
Y
01011001
Z
01011010

What happens to characters that are not plain English letters

Converting English text to binary is uneventful: every character is one byte, so every character is eight bits, and the output length is always the input length times eight. The interesting cases start as soon as the text leaves ASCII.

An accented letter such as e-acute is a single character to you but is stored as two bytes in UTF-8, so it produces sixteen bits rather than eight. An emoji is usually four bytes and produces thirty-two. This is not a quirk of this tool, it is how text is stored everywhere, and it is why a binary string is often longer than the character count suggests.

The practical consequence: if you are counting bits to check your work, count bytes rather than characters. A message that looks like ten characters can be fourteen bytes, and the binary will be one hundred and twelve bits, not eighty.

History and origins

Binary text encoding is a side effect of how computers were designed to store characters. When you save a document, each letter is already sitting in memory as a byte of eight bits.

The ASCII standard from 1963 fixed which number belongs to which character, so text to binary produces the same result on any modern machine.

Frequently asked questions

Why is every group 8 digits long?

Standard ASCII characters fit in a single byte, which is 8 bits. Padding every value to 8 digits keeps the output aligned and makes it easy to decode later.

Can I convert the binary back to text?

Yes. Use the binary to text tool, or the two-way binary translator, and paste the same space-separated groups to read the message.

Learn more

Go deeper on the ideas behind this tool.

Not sure this is the right tool?

If you have a message and you are not certain what it is, the cipher identifier reads the character set and the letter statistics and tells you which scheme it most likely uses, and why. It covers every code and cipher on this site.

Related translators