Convert text to binary, hex, octal, and decimal — or decode binary back to text. See every character's binary representation instantly.
| Char | Dec | Hex | Binary | Oct |
|---|---|---|---|---|
| A | 65 | 41 | 01000001 | 101 |
| Z | 90 | 5A | 01011010 | 132 |
| a | 97 | 61 | 01100001 | 141 |
| z | 122 | 7A | 01111010 | 172 |
| 0 | 48 | 30 | 00110000 | 060 |
| 9 | 57 | 39 | 00111001 | 071 |
| Space | 32 | 20 | 00100000 | 040 |
| ! | 33 | 21 | 00100001 | 041 |
| @ | 64 | 40 | 01000000 | 100 |
Base64 Encoder, Number Base Converter, Hash Generator, and 40+ more free tools.
Browse All Tools →Every character you type is stored as a number in your computer's memory. ASCII (American Standard Code for Information Interchange) assigns a number to each character — for example, 'A' is 65, 'a' is 97, '0' is 48.
Text: H e l l o ASCII: 72 101 108 108 111 Binary: 01001000 01100101 01101100 01101100 01101111
Each character is converted to its ASCII code, then that number is expressed in binary (base 2) using 8 bits (one byte).
Binary uses only two digits: 0 and 1. Each position represents a power of 2:
Bit position: 7 6 5 4 3 2 1 0 Power of 2: 128 64 32 16 8 4 2 1 Example: 01001000 = 0+64+0+0+8+0+0+0 = 72 = 'H'
48 65 6C 6C 6F = "Hello"110 145 154 154 157 = "Hello"72 101 108 108 111 = "Hello"ASCII only covers 128 characters (0-127). For international characters and emoji, UTF-8 encoding uses 1-4 bytes per character. This tool handles UTF-8 automatically — try typing emoji or non-Latin characters!
// JavaScript
"Hello".split('').map(c => c.charCodeAt(0).toString(2).padStart(8, '0')).join(' ');
# Python
' '.join(format(ord(c), '08b') for c in 'Hello')
// Go
for _, c := range "Hello" { fmt.Printf("%08b ", c) }
Text to binary conversion works by taking each character, finding its ASCII or Unicode code point, then converting that decimal number to binary (base-2). For example, 'A' is ASCII 65, which is 01000001 in 8-bit binary. Each character becomes an 8-bit binary string, with leading zeros padding numbers shorter than 8 bits.
Most text-to-binary tools use ASCII for standard English characters (0-127). UTF-8 extends this for Unicode characters, encoding them as 1-4 bytes. For basic Latin characters, ASCII and UTF-8 produce identical binary output. If your text contains accented letters, emoji, or non-Latin scripts, UTF-8 encoding is needed to represent all characters correctly.
Binary (base-2) is the fundamental number system of all digital computing. Every piece of data stored or transmitted by a computer is ultimately represented as binary digits (bits). Binary underpins CPU operations, memory addressing, network protocols, file encoding, and cryptography. Understanding binary helps developers work with bitwise operations, permissions, and low-level data processing.
To convert binary back to text, split the binary string into 8-bit groups. Convert each 8-bit group from binary to decimal using place values (128, 64, 32, 16, 8, 4, 2, 1). Then look up the decimal number in the ASCII table to find the corresponding character. Our tool does this automatically in both directions.
Binary uses base-2 (digits 0-1) while hexadecimal uses base-16 (digits 0-9 and A-F). Hex is a more compact representation: one hex digit equals exactly 4 binary bits, so a byte (8 bits) is two hex digits. Developers often prefer hex in debugging, memory dumps, and color codes because it's shorter than binary while still mapping cleanly to bytes.