Map Extract
Free tool

Text to binary, and binary back to text

Type text to see its bytes as groups of eight 0s and 1s, or paste binary to decode it. The box detects which you mean, and encodes with UTF-8, the same scheme used by web pages, email and most CSV files.

Runs in your browser. Nothing you enter is uploaded.

Example: why a pound sign takes two bytes

Four of the five characters in Hi £5 (H, i, the space and 5) are basic ASCII and fit in one byte each. The pound sign is not, so UTF-8 writes it as two bytes, 11000010 and 10100011.

That pair is behind a familiar spreadsheet problem. When a UTF-8 file is opened as if it were the older Windows encoding, each byte is shown as its own character and £5 turns into £5. Seeing the bytes makes the cause obvious: nothing was corrupted, the file was just read with the wrong encoding.

Input
Hi £5
Result
01001000 01101001 00100000 11000010 10100011 00110101

Converting either way

  1. Type text to encode

    Any characters work, including accents and emoji. A note under the box confirms that text is being turned into binary.

  2. Or paste binary to decode

    If the box holds only 0s, 1s and spaces, and at least eight digits, it is read as binary and decoded as UTF-8 text.

  3. Fix decoding errors

    If the bytes do not form valid UTF-8, for example because a group has seven digits, an error asks you to check that every group has eight.

Terms behind the 0s and 1s

Bit and byte
A bit is a single 0 or 1. A byte is eight bits, which can hold 256 different values, from 00000000 to 11111111.
ASCII
The original 128-character set of English letters, digits and punctuation. In UTF-8 every ASCII character is still a single byte starting with 0.
UTF-8
The encoding used by almost all web pages. Characters outside ASCII take two to four bytes; the first byte's leading 1s say how many follow.
Encoding mismatch
Reading bytes with a different encoding from the one used to write them, which produces characters such as £ or é in place of £ and é.

Questions people ask

How do you write a letter in binary?

Look up the letter's number and write it in base two using eight digits. Capital A is 65, which is 01000001; small a is 97, which is 01100001. Type any letter into the box above to see its byte, or several letters to see one group each.

How do I convert binary back to text?

Paste the binary into the box with a space between each group of eight digits, for example 01001111 01001011. The tool recognises it as binary and shows the decoded text, in this case OK. Groups of the wrong length or invalid byte sequences produce an error rather than a guess.

Why does an emoji become four groups of binary?

Most emoji sit far beyond the first 65,536 Unicode characters, and UTF-8 needs four bytes to store anything in that range. Each byte is shown as one group of eight, so a single emoji appears as four groups, and a flag, which is two symbols combined, as eight.

Where your data goes

Encoding and decoding run in this page with the browser's built-in UTF-8 support. The text and binary you enter are not sent anywhere.

Checked against the tool on

Top