Skip to content
Free Binary Translator

Binary Translator: text to binary, hex and ASCII

With this Binary Translator, you can convert text to binary, hex, decimal (ASCII) or octal and translate binary code or hex back to text. “Hello” becomes 01001000 01100101 01101100 01101100 01101111 (hex 48 65 6c 6c 6f). Free, no sign-up required, and right in your browser: your text never leaves your device.

Built by Dimitri Heissler

Building something of your own? Host it on a VPS with full control.

Each byte as 8 bits of zeros and ones, for example A = 01000001.

Your text stays in your browser: it is neither uploaded nor saved.

Characters in the input
0
Characters in the result
0
Bytes
0
Bits
0

Example result

What this Binary Translator shows you

Type text to instantly get its code in binary, hexadecimal, decimal, or octal, plus a list of characters and their bytes. Paste code, and the tool detects the format and displays the text. Three examples:

Example 1: Text in binary, hex, decimal, and octal

Input (text):

Hello World
The same text in four writing styles
FormatOutput
Binary code01001000 01100101 01101100 01101100 01101111 00100000 01010111 01101111 01110010 01101100 01100100
Hexadecimal48 65 6c 6c 6f 20 57 6f 72 6c 64
Decimal numbers (ASCII codes)72 101 108 108 111 32 87 111 114 108 100
Octal numbers110 145 154 154 157 040 127 157 162 154 144

Result explained: The text has 11 characters and consists of 11 bytes, or 88 bits. The first character, H, becomes 01001000 (binary), 48 (hex), 72 (decimal) or 110 (octal), depending on the notation. An ASCII character is exactly one byte; other characters need multiple bytes (see example 2).

Example 2: Umlauts, euro sign, and emoji in UTF-8

Input (text):

Cheese 5 € 😀
Characters in the second example, with Unicode number and UTF-8 bytes
CharactersUnicodeBytesHexBinary
CU+004314301000011
hU+006816801101000
eU+006516501100101
sU+007317301110011
SpacesU+002012000100000
5U+003513500110101
€U+20AC3E2 82 AC11100010 10000010 10101100
😀U+1F6004F0 9F 98 8011110000 10011111 10011000 10000000

Result explained: 12 characters become 17 bytes. In UTF-8, a character takes one to four bytes depending on its Unicode code point: unaccented letters and digits take one byte, umlauts and other accented letters take two, the euro sign takes three, and an emoji takes four. That’s why the byte count exceeds the character count as soon as the text contains anything outside ASCII.

Example 3: Paste code and convert it back to text

Input (code, format detected automatically):

48 65 6c 6c 6f 20 57 6f 72 6c 64

Detected: Hexadecimal

Output (text):

Hello World

Result explained: Two hexadecimal digits make one byte: 48 becomes H, and 65 becomes e. The tool reads binary code and hex with spaces, commas, newlines or no separators at all. Decimal values need a separator, and the tool does not detect octal automatically; select the Octal format for that.

How it works

How to translate text to binary code and back

Four steps from text to code—no account, no download.

Step 1

Paste text or code

Type the text you want to convert, or paste binary code, hex or decimal values into the input field. The result appears as you type, with no button to press.

Step 2

Check direction and format

The “Detected: …” indicator shows whether the tool found text or code. Use the buttons to set the direction yourself and choose the format: Binary, Hex, Decimal (ASCII) or Octal.

Step 3

Customize output

Choose the separator between values, a prefix such as 0x, 0b or 0o, and uppercase or lowercase letters for hex. The character encoding is UTF-8, with ISO-8859-1 available for older data.

Step 4

Check and apply result

Check the character, byte and bit counts and a table showing your characters in all four notations. Copy the result or download it as a text file.

Basics

How binary code works: one byte has 8 bits

A computer stores each character as a number. It writes that number in binary using just two digits, 0 and 1. A byte has 8 such positions, each with a fixed value: 128, 64, 32, 16, 8, 4, 2, and 1.

Which bits are set for the characters H, A, and z
CharactersASCII code1286432168421Calculation steps
H720100100064 + 8 = 72
A650100000164 + 1 = 65
z1220111101064 + 32 + 16 + 8 + 2 = 122

H has the ASCII code 72. That is 64 plus 8, so the bits for 64 and 8 are set: 01001000. To convert back, add the values of all the 1 bits. Hex (two digits per byte, 48 for H) and octal (three digits, 110) express the same number more compactly.

Use cases

What you can use the Binary Translator for

Whether it’s homework, a puzzle or troubleshooting, binary, hex and ASCII are just different ways of representing the same bytes.

Learning and school

See how each letter becomes a byte of 8 bits. The place-value table from 128 to 1 and the ASCII table are useful for explaining binary code in computer science class.

Puzzles, geocaching and CTF

Paste a sequence of zeros and ones; the tool detects it and shows the text. It also reads separated groups of 7 bits and 8-bit code without separators. Invalid parts are reported with their positions.

Development and debugging

Read hex values with 0x or \x as text, check which bytes an umlaut or emoji uses in UTF-8, and switch to ISO-8859-1 for older data. The page runs in your browser, including on your smartphone, with no app required.

To convert numbers such as 10 or 255 between binary, decimal, hex and octal, use the Number Base Converter instead. Go to Number Base Converter

ASCII table

ASCII table and binary code alphabet from 0 to 127

All 128 ASCII characters with their decimal, hex, octal and binary codes. Characters 0 to 31 and 127 are control characters, such as the newline (10) and tab (9). From 32 onward come spaces, digits, punctuation and letters: A to Z starting at 65 (A = 01000001), a to z starting at 97 (a = 01100001). Accented letters such as ä are not part of ASCII.

ASCII table with decimal, hex, octal, and binary values
DecimalHexOctalBinaryCharacters
00000000000000NUL
10100100000001SOH
20200200000010STX
30300300000011ETX
40400400000100EOT
50500500000101ENQ
60600600000110ACK
70700700000111BEL
80801000001000BS
90901100001001HT
100A01200001010LF
110B01300001011VT
120C01400001100FF
130D01500001101CR
140E01600001110SO
150F01700001111SI
161002000010000DLE
171102100010001DC1
181202200010010DC2
191302300010011DC3
201402400010100DC4
211502500010101NAK
221602600010110SYN
231702700010111ETB
241803000011000CAN
251903100011001EM
261A03200011010SUB
271B03300011011ESC
281C03400011100FS
291D03500011101GS
301E03600011110RS
311F03700011111US
322004000100000SP
332104100100001!
342204200100010"
352304300100011#
362404400100100$
372504500100101%
382604600100110&
392704700100111'
402805000101000(
412905100101001)
422A05200101010*
432B05300101011+
442C05400101100,
452D05500101101-
462E05600101110.
472F05700101111/
4830060001100000
4931061001100011
5032062001100102
5133063001100113
5234064001101004
5335065001101015
5436066001101106
5537067001101117
5638070001110008
5739071001110019
583A07200111010:
593B07300111011;
603C07400111100<
613D07500111101=
623E07600111110>
633F07700111111?
644010001000000@
654110101000001A
664210201000010B
674310301000011C
684410401000100D
694510501000101E
704610601000110F
714710701000111G
724811001001000H
734911101001001I
744A11201001010J
754B11301001011K
764C11401001100L
774D11501001101M
784E11601001110N
794F11701001111O
805012001010000P
815112101010001Q
825212201010010R
835312301010011S
845412401010100T
855512501010101U
865612601010110V
875712701010111W
885813001011000X
895913101011001Y
905A13201011010Z
915B13301011011[
925C13401011100\
935D13501011101]
945E13601011110^
955F13701011111_
966014001100000`
976114101100001a
986214201100010b
996314301100011c
1006414401100100d
1016514501100101e
1026614601100110f
1036714701100111g
1046815001101000h
1056915101101001i
1066A15201101010j
1076B15301101011k
1086C15401101100l
1096D15501101101m
1106E15601101110n
1116F15701101111o
1127016001110000p
1137116101110001q
1147216201110010r
1157316301110011s
1167416401110100t
1177516501110101u
1187616601110110v
1197716701110111w
1207817001111000x
1217917101111001y
1227A17201111010z
1237B17301111011{
1247C17401111100|
1257D17501111101}
1267E17601111110~
1277F17701111111DEL

Discover more

More tools

Looking for more tools? View all text & character tools

FAQ

Frequently asked questions about the Binary Translator

Quick answers about binary code, hex, ASCII, UTF-8, and this tool.

Type or paste the text above. The Binary Translator converts each character to at least one byte and displays each byte as 8 bits of zeros and ones, separated by spaces. Uppercase A becomes 01000001, lowercase a becomes 01100001. Use the buttons to select Hex, Decimal (ASCII) or Octal instead of Binary.

Paste the binary code above; the tool detects it automatically. Each group of 8 bits makes one byte. Groups can be separated by spaces, commas or newlines, or placed directly next to each other. Groups of 7 bits are also supported. If a part is invalid, its position is reported.

“Hello” is 01001000 01100101 01101100 01101100 01101111 in binary and 48 65 6c 6c 6f in hex. Some sites write bytes as 7 bits without the leading 0. The value is the same, and the tool reads this format too as long as the groups are separated. Enter your own name above to see its code immediately.

01100101 is the lowercase e. The set bits have values of 64, 32, 4 and 1, totaling 101 in decimal or 65 in hex. Paste the code above and the tool will show the letter; you can also find it in row 101 of the ASCII table.

The Binary Translator converts characters, not numbers. A single number stays as text; the tool recognizes decimal values as code only when there are at least two numbers, each no greater than 255. So “10” becomes the codes for the characters 1 and 0: 00110001 00110000. To convert a number to another base, use the Number Base Converter. Go to Number Base Converter

Paste the hex code above, such as 48 61 6c 6c 6f, 0x48 0x69 or \x48\x69. The tool recognizes hex by 0x or \x, by pairs with at least one letter from a to f, or by a long run without spaces such as 48656c6c6f that contains digits and at least one letter from a to f. If every pair contains only digits, such as 48 69, the tool treats them as decimal values: click Hex to read them as hex instead. The tool also detects pairs separated by colons or hyphens as hex if they contain a letter from a to f, such as 4a:6f. If they contain only digits, such as 48:69, it does not detect any code: click Hex and also set the direction to Code → Text; otherwise, automatic mode converts the entered text to hex. In Hex format, the tool also reads values separated by colons or hyphens.

ASCII has only 128 characters: unaccented letters, digits, punctuation and control characters, each of which fits in one byte. UTF-8 matches ASCII for these characters and uses two to four bytes for all others: ä is C3 A4, the euro sign takes three bytes, and an emoji takes four. Older systems encode ä as E4 (ISO-8859-1). A single E4 is invalid in UTF-8, so the tool warns you and offers to use ISO-8859-1.

No. The conversion runs entirely in your browser, with no uploads, logging, or storage. You can check the Network tab in your browser’s developer tools: typing does not generate any requests.

Any more questions?

Contact Support
Building something of your own?

Your project needs a server that's always accessible

A ZAP-Hosting VPS reliably puts your application or project online.

4.4/5 Trustpilot32,000+ Active serversSince 2010

No setup. No risk. Online in seconds.

Flexible TermCancel anytimeOnline in 60 seconds

Looking for more tools? View all text & character tools