EasyUnitConverter.com

Ascii To Binary Converter

Enter the ascii text value to convert to binary or Binary to ASCII Text.

10
10
10
16

ASCII Text:

ASCII text includes all printable characters: letters (a-z, A-Z), digits (0-9), and symbols.

Binary:

Each ASCII character is represented as an 8-bit binary number (e.g., "A" = 01000001).

How to Convert ASCII Text to Binary — Formula:

For each character: binary = charCode.toString(2).padStart(8, "0").

Example: "Hi" → H=72=01001000, i=105=01101001 → "01001000 01101001".

Technical Details:

Standard ASCII: 128 characters in 7 bits. UTF-8 extends this to support all Unicode characters using 1-4 bytes. This converter uses 8-bit ASCII encoding.

Ascii To Binary Converter:

Convert any text to its binary representation. Each character becomes an 8-bit binary code.

How to Convert ASCII Text to Binary

  1. Get character from text
  2. Get ASCII code (decimal) from ASCII table
  3. Convert decimal to 8-bit binary
  4. Continue with next character

Example

Convert "Hi" to binary:

"H" = 72₁₀ = 01001000₂

"i" = 105₁₀ = 01101001₂

Result: "01001000 01101001"

ASCII Text to Hex, Binary Conversion Table

ASCII CharacterHexadecimalBinary
NUL0000000000
SOH0100000001
STX0200000010
ETX0300000011
EOT0400000100
ENQ0500000101
ACK0600000110
BEL0700000111
BS0800001000
HT0900001001
LF0A00001010
VT0B00001011
FF0C00001100
CR0D00001101
SO0E00001110
SI0F00001111
DLE1000010000
DC11100010001
DC21200010010
DC31300010011
DC41400010100
NAK1500010101
SYN1600010110
ETB1700010111
CAN1800011000
EM1900011001
SUB1A00011010
ESC1B00011011
FS1C00011100
GS1D00011101
RS1E00011110
US1F00011111
Space2000100000
!2100100001
"2200100010
#2300100011
$2400100100
%2500100101
&2600100110
'2700100111
(2800101000
)2900101001
*2A00101010
+2B00101011
,2C00101100
-2D00101101
.2E00101110
/2F00101111
03000110000
13100110001
23200110010
33300110011
43400110100
53500110101
63600110110
73700110111
83800111000
93900111001
:3A00111010
;3B00111011
<3C00111100
=3D00111101
>3E00111110
?3F00111111
@4001000000
A4101000001
B4201000010
C4301000011
D4401000100
E4501000101
F4601000110
G4701000111
H4801001000
I4901001001
J4A01001010
K4B01001011
L4C01001100
M4D01001101
N4E01001110
O4F01001111
P5001010000
Q5101010001
R5201010010
S5301010011
T5401010100
U5501010101
V5601010110
W5701010111
X5801011000
Y5901011001
Z5A01011010
[5B01011011
\5C01011100
]5D01011101
^5E01011110
_5F01011111
`6001100000
a6101100001
b6201100010
c6301100011
d6401100100
e6501100101
f6601100110
g6701100111
h6801101000
i6901101001
j6A01101010
k6B01101011
l6C01101100
m6D01101101
n6E01101110
o6F01101111
p7001110000
q7101110001
r7201110010
s7301110011
t7401110100
u7501110101
v7601110110
w7701110111
x7801111000
y7901111001
z7A01111010
{7B01111011
|7C01111100
}7D01111101
~7E01111110
DEL7F01111111

Frequently Asked Questions

How do I convert ASCII Text to Binary?

For each character: binary = charCode.toString(2).padStart(8, "0").

What is the ASCII Text number system?

ASCII text includes all printable characters: letters (a-z, A-Z), digits (0-9), and symbols.

What is the Binary number system?

Each ASCII character is represented as an 8-bit binary number (e.g., "A" = 01000001).

Where is ASCII Text to Binary conversion used?

Standard ASCII: 128 characters in 7 bits. UTF-8 extends this to support all Unicode characters using 1-4 bytes. This converter uses 8-bit ASCII encoding.

Can I convert large ascii text numbers?

Yes. This converter handles numbers of any practical size. For very large numbers, the conversion is performed using arbitrary-precision arithmetic to ensure accuracy.

How to Convert ASCII to Binary (Characters to Binary Numbers)

Converting ASCII text to binary is how computers store every text file, email, and web page. Each character has a fixed numeric code (the ASCII value), which is stored as an 8-bit binary number. This conversion is fundamental to serial communication, file encoding, and understanding network protocols at the byte level.

  1. Look up each character's ASCII decimal value in the ASCII table.
  2. Convert each decimal value to an 8-bit binary number.
  3. Pad with leading zeros to ensure each character is exactly 8 bits.
  4. Concatenate all 8-bit groups to form the complete binary representation.
  5. Example: "AB" → 65, 66 → 01000001 01000010.
💡 Tip: Quick formulas: for digits 0-9, ASCII = 48 + digit. For uppercase A-Z, ASCII = 65 + position (A=0). For lowercase a-z, ASCII = 97 + position. No table lookup needed for letters and digits.

ASCII to Binary: Common Characters

Frequently converted characters with their ASCII codes and binary:

InputOutput
Space00100000
0 (zero)00110000
900111001
A01000001
Z01011010
a01100001
z01111010
.00101110
@01000000
\n00001010
!00100001
#00100011

Solved Examples: ASCII to Binary

Question 1: Convert the word "Code" to binary.

Solution:

C = 67 = 01000011

o = 111 = 01101111

d = 100 = 01100100

e = 101 = 01100101

Answer: "Code" = 01000011 01101111 01100100 01100101 (32 bits total = 4 bytes).

Question 2: Encode "Hi!" in binary for serial transmission.

Solution:

H = 72 = 01001000

i = 105 = 01101001

! = 33 = 00100001

Answer: "Hi!" = 01001000 01101001 00100001 — 24 bits sent over the wire.

Question 3: What binary does a web server send for the HTTP status "200"?

Solution:

2 = 50 = 00110010

0 = 48 = 00110000

0 = 48 = 00110000

Answer: "200" = 00110010 00110000 00110000 — text digits, not the number 200 (which would be 11001000).

Question 4: Convert the newline sequence "\r\n" (CRLF) to binary.

Solution:

\r (CR) = 13 = 00001101

\n (LF) = 10 = 00001010

Answer: CRLF = 00001101 00001010 — the Windows line ending (HTTP also uses CRLF for headers).

Practice: ASCII to Binary

Try solving these on your own to test your understanding:

  1. Convert "OK" to binary. (Answer: 01001111 01001011)
  2. What is the binary for the space character? (Answer: 00100000)
  3. Convert "42" (the string) to binary. (Answer: 00110100 00110010)
  4. What is the binary for the newline character \n? (Answer: 00001010)
  5. Convert "Hello" to binary. (Answer: 01001000 01100101 01101100 01101100 01101111)
  6. What is the binary representation of "@"? (Answer: 01000000)

How Text Files Are Actually Stored

When you save a text file, each character becomes its ASCII binary code stored sequentially on disk. A 1000-character text file uses exactly 1000 bytes (plus possible metadata). Line endings differ by OS: Unix uses LF (0x0A), Windows uses CR+LF (0x0D 0x0A), old Mac used CR (0x0D). A hex editor reveals these raw binary/hex values, showing that "text" files are just binary interpreted through the ASCII lens.

Serial Communication and Binary Transmission

UART serial communication sends ASCII characters bit by bit: start bit, 8 data bits (LSB first), optional parity bit, stop bit. At 9600 baud, each character takes about 1.04ms to transmit. When debugging serial protocols with an oscilloscope or logic analyzer, you read the binary waveform and convert to ASCII to see the message. Each high/low transition corresponds to a 1/0 in the character's binary representation.

Key Takeaways

  • Look up ASCII code, convert to 8-bit binary with leading zeros.
  • Digits: binary = 0011 + 4-bit digit value (0000-1001).
  • Uppercase: starts at 01000001 (65); lowercase starts at 01100001 (97).
  • Difference between upper and lower case is always bit 5 (value 32).
  • Text files are sequential ASCII bytes — a "plain text" file IS binary.
  • Line endings: Unix = 0A, Windows = 0D 0A, in binary = 00001010 or 00001101 00001010.

Related Number System Converters: