Binary to Text Converter
Explore the binary representation of text, or decode binary back to human-readable form. Converts between UTF-8 text and 8-bit binary octets, handling multi-byte characters correctly. Perfect for learning, debugging encoding issues, steganography, or just satisfying curiosity about how computers represent text.
What does this tool do?
The Binary-Text converter transforms readable text into its binary representation and vice versa. Text is encoded via UTF-8, so all Unicode characters including emoji, accented letters, and CJK characters are correctly handled as multi-byte sequences. Binary input accepts flexible formatting: spaces between octets, commas, newlines, or concatenated strings. The decoder validates that each octet is in the valid 0-255 range and that complete UTF-8 sequences are present.
How it works
Encoding uses TextEncoder to convert text to UTF-8 bytes, then maps each byte (0-255) to its 8-bit binary representation as a string of 0s and 1s. For display, octets are typically space-separated for readability. Decoding splits input on whitespace or non-binary characters, validates each octet contains exactly 8 bits with values 0-255, converts binary strings to byte values via parseInt with base 2, assembles bytes into a Uint8Array, and uses TextDecoder to convert UTF-8 bytes back to text. Incomplete UTF-8 sequences (like missing continuation bytes for multi-byte characters) are detected and reported.
Features
- Encode text to binary octets, space-separated for readability
- Decode binary back to UTF-8 text
- Accepts any whitespace separator on decode (space, comma, newline)
- Validates each octet is in the 0-255 range
- Handles multi-byte UTF-8 characters correctly
- Live bidirectional conversion
- Clear error messages for invalid binary
How to use
- 1
Enter text or binary
Paste plain text to encode to binary, or paste binary octets to decode to text.
- 2
See instant conversion
The opposite field updates live. Text shows as binary; binary shows as decoded text.
- 3
Copy either format
Copy the binary for encoding purposes, or copy the decoded text. Both are available simultaneously.
- 4
Adjust formatting
Choose whether to display binary with spaces between octets for readability or as a continuous string.
Common use cases
Learning and education
Visualize how text is stored in computers. See ASCII values for English letters, and multi-byte UTF-8 for international characters and emoji.
Debugging encoding issues
Inspect the raw bytes of text that's behaving strangely to identify encoding mismatches, BOM markers, or corruption.
Steganography and puzzles
Hide messages in binary form, or decode binary puzzles and challenges. Binary representations are common in CTF competitions.
Low-level data inspection
Examine the exact byte structure of text data for protocol implementation, file format analysis, or network debugging.
Tips & best practices
- ASCII characters (English letters, numbers, basic punctuation) are single bytes (8 bits). 'A' is 01000001 (65 in decimal)
- UTF-8 uses multiple bytes for non-ASCII characters: 2 bytes for accented European letters, 3 bytes for most of the world's scripts, 4 bytes for emoji
- If decoding emoji fails, verify all 4 bytes are present — partial sequences cause decoding errors
- The space between octets is for human readability only — the decoder accepts continuous strings or any whitespace separators