Text to Binary Converter

Text becomes binary by writing each character’s code as 8 digits of 0s and 1s: letters, digits and punctuation use the American Standard Code for Information Interchange (ASCII), so A is 65, which is 01000001. Accents and emoji use UTF-8, which takes 2 to 4 bytes. Type a word, a name or a message to see it in binary code, or switch, paste binary, and read the text.

Converted on your device. What you type goes into the page’s link, so Share link can send it.

In binary
01001000 01101001 ASCII

“Hi” is 2 bytes in binary: one byte (8 bits) per character.

Characters 2
Bytes 2
Bits 16
Decimal
72 105
Hex
48 69

How to convert text to binary

Every character has a number. For letters, digits and punctuation it is the ASCII code (A is 65, a is 97, a space is 32). Write that number in binary with 8 digits, using the place values 128, 64, 32, 16, 8, 4, 2 and 1, and put a space between the bytes. Here is the first character of yours:

Each byte is 8 bits with place values 128 · 64 · 32 · 16 · 8 · 4 · 2 · 1

Here it is with your numbers:

  1. “H” is code 72 in the ASCII table.
  2. 72 = 64 + 8, so those places get a 1 and the rest a 0: 01001000.

It means “Hi” is 01001000 01101001 in binary.

To go back from binary to text, add up the place values that have a 1 and look the number up: 01001000 is 64 + 8, which is 72, the capital H.

Source RFC 20 (Internet Standard 80) · ASCII format for network interchange ↗

Your characters in binary

CharacterBinaryDecimalHex
H U+0048010010007248
i U+00690110100110569

For a character outside ASCII, the decimal and hex columns show each of its UTF-8 bytes, and the small U+ code next to each character is its own Unicode number.

ASCII letters in binary

Tap a letter to convert it.

CapitalBinarySmallBinary
A01000001a01100001
B01000010b01100010
C01000011c01100011
D01000100d01100100
E01000101e01100101
F01000110f01100110
G01000111g01100111
H01001000h01101000
I01001001i01101001
J01001010j01101010
K01001011k01101011
L01001100l01101100
M01001101m01101101
N01001110n01101110
O01001111o01101111
P01010000p01110000
Q01010001q01110001
R01010010r01110010
S01010011s01110011
T01010100t01110100
U01010101u01110101
V01010110v01110110
W01010111w01110111
X01011000x01111000
Y01011001y01111001
Z01011010z01111010

The digits 0 to 9 are codes 48 to 57 (00110000 to 00111001), and a space is 32 (00100000).

What about accents and emoji? (UTF-8)

ASCII only has 128 codes, so it has no é, ñ, € or 😀. Today’s computers use Unicode, which gives every character a number, and store it with UTF-8: the 128 ASCII characters stay one byte, exactly as before, and every other character takes 2, 3 or 4 bytes, depending on its number.

Unicode numbersBytesPattern
U+0000 – U+007F10xxxxxxx
U+0080 – U+07FF2110xxxxx 10xxxxxx
U+0800 – U+FFFF31110xxxx 10xxxxxx 10xxxxxx
U+10000 – U+10FFFF411110xxx 10xxxxxx 10xxxxxx 10xxxxxx

The x’s hold the character’s number in binary. So é (Unicode 233) is 11000011 10101001, € is 3 bytes and 😀 is 4. A single byte like 11101001 on its own isn’t valid UTF-8, so when binary doesn’t decode, the converter tells you which byte is wrong and why instead of showing a garbled character.

Source RFC 3629 · UTF-8, a transformation format of ISO 10646 ↗

FAQs

How can I convert text to 1 and 0?

Look up each character’s code and write it in 8 binary digits. A is 65 in the ASCII table, and 65 = 64 + 1, so A is 01000001. Do the same for each character and put a space between the bytes, or type the text in the converter above.

Source RFC 20 (Internet Standard 80) · ASCII format for network interchange ↗

How can I convert English to binary code?

English letters, digits and punctuation are all in the ASCII table, so each one becomes one byte (8 bits). Capital letters are 65 to 90 (01000001 to 01011010) and small letters 97 to 122 (01100001 to 01111010). A space is 32, or 00100000.

How to write "I love you" in binary code?

01001001 00100000 01101100 01101111 01110110 01100101 00100000 01111001 01101111 01110101: ten bytes, one for each letter and one for each space (00100000). As ASCII codes it is 73 32 108 111 118 101 32 121 111 117.

What is your name in binary?

Type your name in the box above to see it. Each letter is one byte: a capital letter starts 010 and a small letter starts 011. “Sam”, for example, is 01010011 01100001 01101101.

What does the following binary code translate to 01101000, 01100101, 01101100, 01101100, 01101111?

It spells hello, in small letters: 104 is h, 101 is e, 108 is l (twice) and 111 is o.

What is 01100011 in binary?

01100011 is the small letter c: 64 + 32 + 2 + 1 makes code 99.

What does 01101100 mean?

01101100 is the small letter l: 64 + 32 + 8 + 4 makes code 108.

What is 01000010 in ASCII?

01000010 is the capital letter B: 64 + 2 makes code 66.

What is the ASCII code from a to z?

Small letters a to z are 97 to 122, and capitals A to Z are 65 to 90. A small letter’s code is always its capital’s code plus 32, so in binary only one digit changes (A 01000001, a 01100001).

Sources

Related calculators