0

ASCII Character: Zero

ASCII Code 48 · Unicode U+0030 · Hex 0x30

zero 0

About the Zero Character

ASCII code 48 (0x30) represents the Zero character "0". The digit "0" has ASCII code 48. The digits 0–9 occupy consecutive ASCII codes 48–57, which makes numeric conversion straightforward: subtracting 48 (or 0x30) from any digit character’s ASCII code gives its numeric value. The printable ASCII characters (codes 32–126) include the space, digits, uppercase and lowercase Latin letters, and common punctuation symbols. These 95 characters form the foundation of text representation in virtually all computing systems and are universally supported across all character encodings, programming languages, and operating systems.

Encoding Details

ASCII Code 48
Hexadecimal 0x30
Octal 060
Binary 00110000
Unicode U+0030
Unicode Name DIGIT ZERO
HTML Numeric 0
HTML Entity
URL Escape %30
UTF-8 (Hex) 30
Quoted-Printable 0

Source Code Examples

JavaScript
// Character literal
let char = '0';
// Using char code
let char2 = String.fromCharCode(48);
// Unicode escape
let char3 = '\x30';
Python
# Character literal
char = '0'
# Using chr()
char = chr(48)
# Using ord() to get code
code = ord('0')  # Returns 48
HTML
<!-- Direct character -->
0
<!-- HTML entity (numeric) -->
&#48;
<!-- Hex entity -->
&#x30;
C#
// Character literal
char c = '0';
// Using cast
char c2 = (char)48;
// To get code from char
int code = (int)'0';  // Returns 48

Navigate

Copied!