About the text to binary
Convert text into the bytes a computer actually stores โ as binary, hexadecimal, octal or decimal โ and turn byte codes back into readable text. Text is encoded as UTF-8, the encoding the web uses, so accented letters, non-Latin scripts and emoji convert and round-trip correctly. Everything runs in your browser.
How to use it
- Choose a format: Binary, Hex, Octal or Decimal.
- Pick whether bytes are separated by a space or run together.
- Type or paste text in the Text box to see its bytes.
- Or paste byte codes into the bytes box to decode them back to text.
- Use Copy to grab either side.
Questions
- Why does one emoji turn into four bytes?
- UTF-8 uses one byte for basic ASCII characters and two to four bytes for everything else. Most emoji sit outside the first 65,536 code points, so they need four bytes.
- Why do I get a โnot valid UTF-8โ error?
- The bytes you entered do not form a complete UTF-8 sequence โ for example, the first byte of a multi-byte character without the bytes that must follow it. The tool reports this instead of guessing or inserting replacement characters.
- How do I convert binary to text without spaces?
- Paste the unbroken string of 0s and 1s. As long as its length is a multiple of 8, it is split into bytes automatically. Hex works the same way in pairs of digits and octal in groups of three.
- Why can't decimal bytes be written without a separator?
- Decimal byte values are one to three digits long, so a run like 7210 is ambiguous. Binary, hex and octal can be zero-padded to a fixed width, which is what makes the no-separator option possible for them.