Skip to main content

    Binary ↔ Text Converter

    Convert text to binary and binary to text. Supports ASCII encoding with space-separated bytes.

    Free to use. Runs in your browser.

    Paste text to convert each character to its 8-bit binary representation, or paste binary to decode back to ASCII. ASCII characters only (0-127).

    Use it for byte-level learning, protocol examples, and puzzles where each character is shown as one binary byte.

    Text

    Binary

    Byte grouping

    The converter separates bytes with spaces, so 01001000 01101001 reads as two characters. Removing the spaces makes the boundaries ambiguous.

    ASCII range

    Standard ASCII values run from 0 to 127. Values above that depend on the text encoding used by the system that produced the bytes.

    Common checks

    Hello becomes 01001000 01100101 01101100 01101100 01101111. If decoding gives question marks, inspect the byte spacing first.

    Reading one byte

    01000001 equals 65 in decimal because the 64 place is on and the 1 place is on. ASCII maps decimal 65 to the letter A.

    Binary: The Language Computers Actually Speak

    Everything on your computer, every file, every image, every message, is stored as sequences of 0s and 1s. That's it. When you type the letter "A", your computer stores 01000001. When you type "Hello", it stores five bytes: 01001000 01100101 01101100 01101100 01101111. Binary is the foundation of all digital data.

    This converter translates between human-readable text and its binary representation using ASCII encoding. Each character becomes 8 binary digits (one byte). It's the same encoding your computer uses internally, you're just seeing the raw data format that's normally hidden behind fonts and rendering engines.

    Everything runs in your browser. Type text, see binary. Paste binary, see text. Instant, private, and offline-capable.

    ASCII Character Reference

    CharacterBinaryDecimalHex
    A010000016541
    Z01011010905A
    a011000019761
    z011110101227A
    0001100004830
    9001110015739
    Space001000003220
    !001000013321

    What this means for you: Notice that uppercase 'A' (65) and lowercase 'a' (97) differ by exactly 32. That's not a coincidence, it's a deliberate design decision in ASCII that makes case conversion a single bit flip (bit 5). The entire ASCII table was designed with these binary tricks in mind.

    Understanding Binary Encoding

    ASCII (7-bit, 128 characters)

    The original character encoding. Covers English letters, digits, and basic punctuation. Every ASCII character fits in one byte. Still the foundation of UTF-8, all ASCII text is valid UTF-8.

    UTF-8 (variable width, 1-4 bytes)

    The web's standard encoding. ASCII characters use 1 byte, European accented characters use 2, Asian characters use 3, and emojis use 4. This tool handles ASCII; for full Unicode, you'd need a UTF-8 aware converter.

    Bits vs bytes

    1 bit = one 0 or 1. 1 byte = 8 bits = one ASCII character. Network speeds are measured in bits per second (Mbps), file sizes in bytes (MB). A "100 Mbps" connection transfers ~12.5 MB per second, the 8:1 ratio trips people up constantly.

    Why 8 bits per byte?

    8 bits gives you 256 possible values (2^8). That's enough for all ASCII characters (128) plus extended characters. It's also evenly divisible by 2 and 4, making hardware design simpler. The 8-bit byte became standard with the IBM System/360 in the 1960s.

    Powers of 2 Cheat Sheet

    BinaryDecimalSignificance
    11Smallest unit, 1 bit
    1004One hex digit (nibble)
    10000000128ASCII character set size
    1000000002561 byte, RGB channel max +1
    100000000001,0241 KB (kibibyte)
    1000000000000000000001,048,5761 MB (mebibyte)

    Walking Through a Text to Binary Conversion

    Binary conversion is easiest when you follow one character at a time. The text "Hi!" has three ASCII characters, so it becomes three bytes. Each byte is padded to eight bits so the decoder can recover the original boundaries.

    CharacterASCII DecimalBinary ByteNotes
    H720100100064 + 8 gives decimal 72
    i10501101001Lowercase letters sit in the 97 to 122 range
    !3300100001Punctuation is part of the ASCII table too

    Put together, "Hi!" becomes 01001000 01101001 00100001.

    Binary to Text Input Rules

    Use groups of eight

    One ASCII character is one byte, so each binary group should contain eight digits. A seven-digit value may be valid mathematically, but byte output is usually padded to eight.

    Separate bytes

    Spaces make the byte boundaries explicit. New lines are fine too because the converter splits on whitespace before decoding each byte.

    Keep only 0 and 1

    Characters such as commas, quotes, or prefixes like 0b should be removed before decoding. They are notation helpers, not part of the byte.

    Expect ASCII output

    This tool reads each group as a single character code. Multi-byte UTF-8 sequences need a byte-aware decoder if you want accents, Arabic, Chinese, or emoji.

    Binary, Decimal, Hex, and Octal

    Developers often switch between number bases because each one makes a different pattern easier to read. Binary shows every bit. Hex groups those bits into compact blocks. Octal groups them into threes, which is why Unix permissions are often written as 755 or 644.

    BaseDigitsExample for Decimal 65Common Use
    Binary0 and 101000001Bit flags, masks, teaching byte layout
    Octal0 to 7101Unix permissions and some legacy formats
    Decimal0 to 965Human-facing numbers and ASCII tables
    Hex0 to 9, A to F41Memory dumps, colours, hashes, byte streams

    Where Binary Shows Up in Real Work

    Flags and permissions

    A bit can mean on or off, true or false, allowed or denied. File permissions, feature flags, and compact protocol options often pack several yes/no settings into one number.

    Network packets

    Protocol documents describe bytes, bit ranges, and flags. Reading binary helps when a packet capture shows that one bit changes a request from accepted to rejected.

    File signatures

    Many files start with fixed byte sequences. PNG begins with a known eight-byte signature, while PDF begins with readable ASCII bytes for %PDF.

    Debugging encodings

    If text looks corrupted, comparing the expected bytes with the actual bytes can reveal whether the problem is ASCII, UTF-8, Windows-1252, or another encoding.

    Practice Strings to Try

    TextBinaryWhat It Shows
    OK01001111 01001011Uppercase letters in the 65 to 90 range
    ok01101111 01101011Lowercase letters differ by the case bit
    4200110100 00110010Digits are characters, not the number forty-two
    A B01000001 00100000 01000010The middle byte is a space character

    Related Tools

    How to use this tool

    1

    Choose the conversion direction: Text to Binary or Binary to Text

    2

    Type or paste your input in the left panel

    3

    See the instant conversion in the right panel and copy

    Common uses

    • Learning how computers represent text data
    • Converting text for CTF challenges and puzzles
    • Understanding ASCII encoding for programming courses
    • Debugging binary data in network protocols

    Share this tool

    Frequently Asked Questions

    What is binary?
    Binary is the base-2 number system using only two digits: 0 and 1. Every piece of data in your computer, text, images, music, apps, is stored as sequences of 0s and 1s. Each digit is called a 'bit', and 8 bits make a 'byte' which can represent one character.
    How does text become binary?
    Each character is assigned a number in the ASCII table (A=65, B=66, etc.), and that number is converted to binary. The letter 'A' is 65 in decimal, which is 01000001 in binary. This tool does that conversion for every character you type.
    Is my data sent to a server?
    No. The conversion uses JavaScript's built-in charCodeAt() and String.fromCharCode() methods, running entirely in your browser. Nothing is transmitted.
    Why are the binary numbers 8 digits long?
    Each character is represented by one byte (8 bits). Even if the binary value could be shorter (like 'A' = 1000001, 7 digits), we pad it to 8 digits with a leading zero for consistency. This is how computers actually store ASCII characters.
    What about emoji and non-English characters?
    This tool uses basic ASCII encoding (1 byte per character). ASCII covers English letters, digits, and basic punctuation. Characters outside ASCII (emoji, Chinese, Arabic) use multi-byte encodings (UTF-8) which this tool doesn't fully support.
    How do spaces between binary bytes work?
    Spaces separate each byte (character) in the binary output. Without spaces, 01001000 01101001 ('Hi') would be 0100100001101001, you couldn't tell where one character ends and another begins. The space is a delimiter, not part of the encoding.
    What's the difference between binary and Base64?
    Binary is the raw 0s and 1s representation. Base64 encodes binary data using 64 printable characters (A-Z, a-z, 0-9, +, /) to make it safe for text-based systems like email and JSON. They serve different purposes.
    Can I convert binary back to text?
    Yes, click the direction toggle button to switch to Binary to Text mode. Paste space-separated 8-digit binary strings and get the text back. The conversion is perfectly reversible.
    What are some real-world uses of binary?
    Network engineers use binary for subnet mask calculations. Hardware engineers work in binary for circuit design. Security researchers read binary for reverse engineering. Developers encounter binary in file format specifications, bitwise operations, and protocol debugging.
    How do computers add in binary?
    The same way you add in decimal, but carrying at 2 instead of 10. 0+0=0, 0+1=1, 1+0=1, 1+1=10 (0 carry 1). This is why computers use binary, addition, the most fundamental operation, can be implemented with simple logic gates (AND, XOR).
    What's a bitwise operation?
    Operations that work on individual bits: AND (&), OR (|), XOR (^), NOT (~), and shifts (<<, >>). They're used for flags, permissions, compression, cryptography, and performance-critical code. Understanding binary makes bitwise operations easier to reason about.
    Why do programmers need to know binary?
    Binary appears in debugging (memory dumps, network packets), permissions (chmod uses octal, which maps to binary), colours (hex maps to binary), and performance (bitwise operations are the fastest CPU instructions). You don't need it daily, but when you need it, nothing else will do.

    Results are for general informational purposes only and should be checked before use. They are not professional advice. See our Disclaimer and Terms of Service.