Text & Developer tool

Text to Binary Converter Online

Convert text to binary code and binary back to text, with UTF-8 support.

  • Instant results
  • Working shown
  • No sign-up
  • Runs in your browser
ToolUpdates as you type
01001000 01101001

2 characters = 2 bytes = 16 bits (UTF-8)

  • H (U+0048)01001000
  • i (U+0069)01101001
How it works

This text to binary converter turns each character into its UTF-8 bytes and writes every byte as 8 bits. For example, "Hi" becomes 01001000 01101001. It also works the other way: paste binary and it decodes the bytes back into text.

This text to binary converter shows how a computer stores your text as 0s and 1s. Type any text to get binary code, or paste binary to turn it back into readable text. It uses UTF-8, so Indian scripts, the ₹ sign and emoji all work.

How to use the text to binary converter

  1. Choose Text to binary or Binary to text.
  2. Type or paste your input.
  3. Tick or untick Space between bytes to change how the binary looks.
  4. Copy the result. Use Decode it back to check a conversion.

Below the binary, the tool lists each character with its Unicode code point and its bytes, so you can see which character made which bits.

How it works

Every character has a number called a code point. UTF-8 turns that number into 1 to 4 bytes, and each byte is written as 8 binary digits.

Character → code point → UTF-8 bytes → 8 bits per byte
H → 72 → 72 → 01001000
i → 105 → 105 → 01101001

So "Hi" in binary is 01001000 01101001. Going back, the tool splits the bits into bytes, checks that they form valid UTF-8, and turns them into characters.

ASCII to binary table

For English letters, digits and common symbols, UTF-8 uses the same single byte as ASCII.

Character Decimal code Binary
A 65 01000001
Z 90 01011010
a 97 01100001
z 122 01111010
0 48 00110000
9 57 00111001
space 32 00100000

Notice that a lower case letter is its capital plus 32. In binary, only one bit changes: A is 01000001 and a is 01100001.

Common mistake: A common mistake is dropping leading zeros, so A becomes 1000001. That is still 65, but a decoder that expects 8-bit groups will read the wrong characters. Keep all 8 bits.

Characters that need more than one byte

Character UTF-8 bytes in binary Bytes
é 11000011 10101001 2
₹ 11100010 10000010 10111001 3
😀 11110000 10011111 10011000 10000000 4

The first bits of the first byte tell the reader how many bytes follow: 110 means 2, 1110 means 3 and 11110 means 4. Every following byte starts with 10.

Binary to text: input rules

  • Only 0, 1 and spaces are allowed.
  • Separate bytes with spaces, or paste one run of bits whose length is a multiple of 8.
  • Groups shorter than 8 bits, such as 7-bit ASCII like 1001000 1101001, are also read, one group per byte.

Learn more

Binary text sits on top of the number systems used everywhere in programming. Convert numbers between bases with the number system converter. To work with characters in code, try count the frequency of each character in a string and string programs in Java. The character counter shows how many characters your text has before you convert it.

Pro tip: A byte count is not a character count. "नमस्ते" has 6 Unicode code points but 18 UTF-8 bytes, because each Devanagari code point takes 3 bytes.

Frequently asked questions

How do I convert text to binary by hand?
Look up the character code, then write it in binary with 8 digits. H is 72, and 72 in binary is 01001000. For plain English letters and digits, the code is the same in ASCII and UTF-8.
What is the difference between ASCII and UTF-8?
ASCII has 128 characters, each fitting in one byte. UTF-8 covers every Unicode character. It stores ASCII characters as the same single byte, and other characters, such as é, ₹ or Hindi letters, as 2 to 4 bytes.
How do I convert binary to text?
Choose Binary to text and paste the bits. Put a space after every 8 bits, or paste one long run whose length is a multiple of 8. The tool reads the bytes as UTF-8.
Why do I get a 'not valid UTF-8' error?
Some byte patterns are not allowed in UTF-8, for example a lead byte that is not followed by the right continuation bytes. This usually means a bit was lost or added while copying.
Why does an emoji take 32 bits?
Emoji are outside the first 65,536 Unicode code points, so UTF-8 stores them in 4 bytes. 4 bytes × 8 bits = 32 bits.

Try another tool

See all free tools
Chat with us