🔢 Text to Binary Converter
By ToolNimba Editorial Team · Updated 2026-06-19
Type some text and press Convert.
This converter turns text into binary and binary back into text. Type or paste your message, choose a direction, and you get the result instantly. Each character becomes an 8-bit group (eight 0s and 1s), separated by spaces so the output is easy to read. Everything runs in your browser, so nothing you type is sent anywhere.
What is the Text to Binary Converter?
Computers store every letter, digit and symbol as a number, and those numbers are stored in binary: a base-2 system that uses only two digits, 0 and 1. The mapping from a character to its number comes from a character set. The original ASCII set covers the basic English letters, digits and punctuation, assigning each one a code from 0 to 127. The letter A is 65, a space is 32, and the digit 0 is the number 48 (not 0, which is a control character). Modern text uses UTF-8, which keeps those same codes for the ASCII range and adds longer sequences for everything else, from accented letters to emoji.
To write a character in binary, you take its code and express it in base 2. The number 65 is 64 plus 1, which in 8-bit binary is 01000001. We pad each value to eight digits (one byte) so every character lines up neatly and the stream can be split back apart without ambiguity. That is why a single ASCII character always shows as exactly eight 0s and 1s here. A character outside the ASCII range, such as an accented letter, takes two or more bytes under UTF-8, so it produces more than one 8-bit group.
Decoding reverses the process: the binary is split into 8-bit groups, each group is read as a base-2 number, and that number is looked up as a byte. The bytes are then interpreted as UTF-8 to rebuild the original text. Because the split relies on each character being exactly eight bits, the total number of binary digits must be a multiple of 8. If it is not, something is missing or extra, and the converter will tell you rather than guess.
When to use it
- Learning how computers represent text, for a computer science class or homework on number systems.
- Creating a fun "secret message" in binary to share with friends, then decoding it back.
- Checking the exact byte values behind a piece of text when debugging encoding issues.
- Generating binary strings for a puzzle, escape room clue, or programming exercise.
How to use the Text to Binary Converter
- Pick a direction: "Text to binary" to encode, or "Binary to text" to decode.
- Type or paste your input into the top box.
- Choose how the binary groups are separated (space, none, or new line).
- Read the result in the lower box and press Copy to grab it.
- Use "Swap input and output" to feed the result straight back through in the other direction.
Formula & method
Worked examples
Convert the word "Hi" to binary.
- Look up each character code: H = 72, i = 105.
- Write 72 in binary: 64 + 8 = 01001000.
- Write 105 in binary: 64 + 32 + 8 + 1 = 01101001.
- Join the 8-bit groups with a space.
Result: 01001000 01101001
Decode the binary 01001000 01101001 01101111 back to text.
- Split into 8-bit groups: 01001000, 01101001, 01101111.
- Read each as a base-2 number: 01001000 = 72, 01101001 = 105, 01101111 = 111.
- Look up the codes: 72 = H, 105 = i, 111 = o.
- Join the characters in order.
Result: Hio
Common characters and their 8-bit binary codes
| Character | Decimal code | 8-bit binary |
|---|---|---|
| A | 65 | 01000001 |
| a | 97 | 01100001 |
| Z | 90 | 01011010 |
| 0 (digit) | 48 | 00110000 |
| Space | 32 | 00100000 |
| ! (exclamation) | 33 | 00100001 |
Common mistakes to avoid
- Pasting binary that is not a multiple of 8 digits. Each character is stored as exactly eight bits. If your binary has, say, 15 or 20 digits in total, a group is incomplete and the text cannot be rebuilt. Count the 0s and 1s: the total must divide evenly by 8.
- Confusing the digit 0 with the number zero. The character "0" has code 48 (00110000), not 0. Code 0 is the null control character, which is not a printable digit. This trips people up when they expect "0" to map to all zeros.
- Mixing up separators when decoding. The decoder ignores anything that is not a 0 or 1, so spaces, commas and line breaks between groups are fine. But stray letters or stray digits inside a group will change the value, so keep the binary clean.
- Expecting one group per non-English character. Accented letters, emoji and other non-ASCII characters take two or more bytes under UTF-8, so each one produces more than one 8-bit group. That is correct, not a bug.
Glossary
- Binary
- A base-2 number system that uses only the digits 0 and 1. Computers store all data this way.
- Bit
- A single binary digit, either 0 or 1. The smallest unit of digital information.
- Byte
- A group of eight bits. One ASCII character is stored in one byte.
- ASCII
- A character set mapping basic English letters, digits and symbols to codes 0 through 127.
- UTF-8
- A modern encoding that keeps the ASCII codes and uses extra bytes for other characters, from accents to emoji.
- Character code
- The number assigned to a character, such as 65 for the letter A, which is then written in binary.
Frequently asked questions
How do I convert text to binary?
Type your text, keep the mode on "Text to binary", and the converter writes each character as an 8-bit binary group. Internally it takes each character code (for example A is 65) and expresses it in base 2 padded to eight digits, so A becomes 01000001.
How do I convert binary back to text?
Switch to "Binary to text" and paste your binary. The tool splits it into 8-bit groups, reads each group as a number, and looks that number up as a character. Spaces and line breaks between groups are ignored, so you can paste binary in any common layout.
Why is each character 8 bits long?
One byte is eight bits, and a basic ASCII character fits in a single byte. Padding every value to eight digits keeps the groups aligned so the stream can be split back into characters without ambiguity.
What does "01001000" mean in binary?
Read as a base-2 number, 01001000 equals 64 + 8 = 72. The character with code 72 is a capital H, so 01001000 represents the letter H.
Can it handle emoji and accented letters?
Yes. The converter uses UTF-8, so characters outside the basic ASCII range are encoded as two or more bytes. Each byte still shows as an 8-bit group, so a single emoji may produce four groups.
Is my text sent to a server?
No. The whole conversion runs in your browser with plain JavaScript. Nothing you type is uploaded or stored, so it is safe to use for private notes.