&

ASCII Code 38

Ampersand

About This Character

ASCII code 38 (0x26) represents the Ampersand character "&". The "Ampersand" character (&) with ASCII code 38 is a punctuation or special symbol in the printable ASCII range. Punctuation characters serve important roles in both natural language writing and programming syntax. 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.

Character Encoding

Decimal 38
Octal 046
Hexadecimal 0x26
Binary 00100110
HTML Code &
HTML Entity &
Unicode U+0026
Unicode Name AMPERSAND
URL Escape %26
Quoted-Printable &
UTF-8 (Hex) 26
Category Printable — Punctuation & Symbols

How to Type in Code

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

See Also

Copied!