The printable ASCII characters with their decimal, hex and HTML codes, plus the control codes worth knowing.
| Dec | Hex | Char | HTML | Description |
|---|---|---|---|---|
| 32 | 20 | space |   | Space |
| 33 | 21 | ! | ! | Exclamation mark |
| 34 | 22 | " | " | Double quote |
| 35 | 23 | # | # | Number sign (hash) |
| 36 | 24 | $ | $ | Dollar sign |
| 37 | 25 | % | % | Percent sign |
| 38 | 26 | & | & | Ampersand |
| 39 | 27 | ' | ' | Apostrophe |
| 40 | 28 | ( | ( | Left parenthesis |
| 41 | 29 | ) | ) | Right parenthesis |
| 42 | 2A | * | * | Asterisk |
| 43 | 2B | + | + | Plus sign |
| 44 | 2C | , | , | Comma |
| 45 | 2D | - | - | Hyphen / minus |
| 46 | 2E | . | . | Period (full stop) |
| 47 | 2F | / | / | Forward slash |
| 48 | 30 | 0 | 0 | Digit 0 |
| 49 | 31 | 1 | 1 | Digit 1 |
| 50 | 32 | 2 | 2 | Digit 2 |
| 51 | 33 | 3 | 3 | Digit 3 |
| 52 | 34 | 4 | 4 | Digit 4 |
| 53 | 35 | 5 | 5 | Digit 5 |
| 54 | 36 | 6 | 6 | Digit 6 |
| 55 | 37 | 7 | 7 | Digit 7 |
| 56 | 38 | 8 | 8 | Digit 8 |
| 57 | 39 | 9 | 9 | Digit 9 |
| 58 | 3A | : | : | Colon |
| 59 | 3B | ; | ; | Semicolon |
| 60 | 3C | < | < | Less-than sign |
| 61 | 3D | = | = | Equals sign |
| 62 | 3E | > | > | Greater-than sign |
| 63 | 3F | ? | ? | Question mark |
| 64 | 40 | @ | @ | At sign |
| 65 | 41 | A | A | Capital letter A |
| 66 | 42 | B | B | Capital letter B |
| 67 | 43 | C | C | Capital letter C |
| 68 | 44 | D | D | Capital letter D |
| 69 | 45 | E | E | Capital letter E |
| 70 | 46 | F | F | Capital letter F |
| 71 | 47 | G | G | Capital letter G |
| 72 | 48 | H | H | Capital letter H |
| 73 | 49 | I | I | Capital letter I |
| 74 | 4A | J | J | Capital letter J |
| 75 | 4B | K | K | Capital letter K |
| 76 | 4C | L | L | Capital letter L |
| 77 | 4D | M | M | Capital letter M |
| 78 | 4E | N | N | Capital letter N |
| 79 | 4F | O | O | Capital letter O |
| 80 | 50 | P | P | Capital letter P |
| 81 | 51 | Q | Q | Capital letter Q |
| 82 | 52 | R | R | Capital letter R |
| 83 | 53 | S | S | Capital letter S |
| 84 | 54 | T | T | Capital letter T |
| 85 | 55 | U | U | Capital letter U |
| 86 | 56 | V | V | Capital letter V |
| 87 | 57 | W | W | Capital letter W |
| 88 | 58 | X | X | Capital letter X |
| 89 | 59 | Y | Y | Capital letter Y |
| 90 | 5A | Z | Z | Capital letter Z |
| 91 | 5B | [ | [ | Left square bracket |
| 92 | 5C | \ | \ | Backslash |
| 93 | 5D | ] | ] | Right square bracket |
| 94 | 5E | ^ | ^ | Caret |
| 95 | 5F | _ | _ | Underscore |
| 96 | 60 | ` | ` | Backtick (grave) |
| 97 | 61 | a | a | Small letter a |
| 98 | 62 | b | b | Small letter b |
| 99 | 63 | c | c | Small letter c |
| 100 | 64 | d | d | Small letter d |
| 101 | 65 | e | e | Small letter e |
| 102 | 66 | f | f | Small letter f |
| 103 | 67 | g | g | Small letter g |
| 104 | 68 | h | h | Small letter h |
| 105 | 69 | i | i | Small letter i |
| 106 | 6A | j | j | Small letter j |
| 107 | 6B | k | k | Small letter k |
| 108 | 6C | l | l | Small letter l |
| 109 | 6D | m | m | Small letter m |
| 110 | 6E | n | n | Small letter n |
| 111 | 6F | o | o | Small letter o |
| 112 | 70 | p | p | Small letter p |
| 113 | 71 | q | q | Small letter q |
| 114 | 72 | r | r | Small letter r |
| 115 | 73 | s | s | Small letter s |
| 116 | 74 | t | t | Small letter t |
| 117 | 75 | u | u | Small letter u |
| 118 | 76 | v | v | Small letter v |
| 119 | 77 | w | w | Small letter w |
| 120 | 78 | x | x | Small letter x |
| 121 | 79 | y | y | Small letter y |
| 122 | 7A | z | z | Small letter z |
| 123 | 7B | { | { | Left curly brace |
| 124 | 7C | | | | | Vertical bar (pipe) |
| 125 | 7D | } | } | Right curly brace |
| 126 | 7E | ~ | ~ | Tilde |
| Dec | Hex | Abbr | Description |
|---|---|---|---|
| 0 | 00 | NUL | Null character |
| 7 | 07 | BEL | Bell / alert |
| 8 | 08 | BS | Backspace |
| 9 | 09 | TAB | Horizontal tab (\t) |
| 10 | 0A | LF | Line feed — newline (\n) |
| 13 | 0D | CR | Carriage return (\r) |
| 27 | 1B | ESC | Escape |
| 127 | 7F | DEL | Delete |
ASCII maps numbers to characters — the letter A is 65, a space is 32, the digit 0 is 48. It defines 128 codes in total: the first 32 (0–31) plus 127 are invisible control characters like tab, newline and carriage return, and the rest (32–126) are the printable letters, digits and symbols in the table above. Almost every text-based system builds on this foundation, which is why it's worth knowing where to look.
A few practical patterns fall out of the numbering. Uppercase and lowercase letters are exactly 32 apart (A is 65, a is 97), which is how case conversion works at the byte level. The digits 0–9 sit at 48–57, so subtracting 48 from a digit's code gives its value. And the difference between a line feed (10) and a carriage return (13) is the root of the classic Windows-versus-Unix newline difference. Modern UTF-8 is a superset of ASCII — the first 128 characters are identical — so this table is still the base layer underneath today's text. To convert between decimal, hex and binary, use the number base converter.