ASCII table
Every ASCII code in decimal, hexadecimal, octal and binary, with HTML entities and character names — plus a converter for turning text into codes and back.
Nothing matches that. Try a character, a decimal value like 65, a hex value like 41, or a name like escape.
Control characters 0–31, 127
Non-printing codes inherited from teleprinters. Most are obsolete; tab, line feed, carriage return, null and escape are still in daily use.
| Dec | Hex | Oct | Binary | Char | HTML | Name | |
|---|---|---|---|---|---|---|---|
| 0 | 00 | 000 | 00000000 | NUL \0 | � | Null | |
| 1 | 01 | 001 | 00000001 | SOH |  | Start of Heading | |
| 2 | 02 | 002 | 00000010 | STX |  | Start of Text | |
| 3 | 03 | 003 | 00000011 | ETX |  | End of Text | |
| 4 | 04 | 004 | 00000100 | EOT |  | End of Transmission | |
| 5 | 05 | 005 | 00000101 | ENQ |  | Enquiry | |
| 6 | 06 | 006 | 00000110 | ACK |  | Acknowledge | |
| 7 | 07 | 007 | 00000111 | BEL \a |  | Bell | |
| 8 | 08 | 010 | 00001000 | BS \b |  | Backspace | |
| 9 | 09 | 011 | 00001001 | HT \t | 	 | Horizontal Tab | |
| 10 | 0A | 012 | 00001010 | LF \n | | Line Feed | |
| 11 | 0B | 013 | 00001011 | VT \v |  | Vertical Tab | |
| 12 | 0C | 014 | 00001100 | FF \f |  | Form Feed | |
| 13 | 0D | 015 | 00001101 | CR \r | | Carriage Return | |
| 14 | 0E | 016 | 00001110 | SO |  | Shift Out | |
| 15 | 0F | 017 | 00001111 | SI |  | Shift In | |
| 16 | 10 | 020 | 00010000 | DLE |  | Data Link Escape | |
| 17 | 11 | 021 | 00010001 | DC1 |  | Device Control 1 (XON) | |
| 18 | 12 | 022 | 00010010 | DC2 |  | Device Control 2 | |
| 19 | 13 | 023 | 00010011 | DC3 |  | Device Control 3 (XOFF) | |
| 20 | 14 | 024 | 00010100 | DC4 |  | Device Control 4 | |
| 21 | 15 | 025 | 00010101 | NAK |  | Negative Acknowledge | |
| 22 | 16 | 026 | 00010110 | SYN |  | Synchronous Idle | |
| 23 | 17 | 027 | 00010111 | ETB |  | End of Transmission Block | |
| 24 | 18 | 030 | 00011000 | CAN |  | Cancel | |
| 25 | 19 | 031 | 00011001 | EM |  | End of Medium | |
| 26 | 1A | 032 | 00011010 | SUB |  | Substitute | |
| 27 | 1B | 033 | 00011011 | ESC \e |  | Escape | |
| 28 | 1C | 034 | 00011100 | FS |  | File Separator | |
| 29 | 1D | 035 | 00011101 | GS |  | Group Separator | |
| 30 | 1E | 036 | 00011110 | RS |  | Record Separator | |
| 31 | 1F | 037 | 00011111 | US |  | Unit Separator | |
| 127 | 7F | 177 | 01111111 | DEL |  | Delete |
Printable ASCII 32–126
The 95 characters every system agrees on — space, punctuation, digits and the unaccented Latin alphabet.
| Dec | Hex | Oct | Binary | Char | HTML | Name | |
|---|---|---|---|---|---|---|---|
| 32 | 20 | 040 | 00100000 | SP |   | Space | |
| 33 | 21 | 041 | 00100001 | ! | ! | Exclamation mark | |
| 34 | 22 | 042 | 00100010 | " | " " | Double quote | |
| 35 | 23 | 043 | 00100011 | # | # | Number sign / hash | |
| 36 | 24 | 044 | 00100100 | $ | $ | Dollar sign | |
| 37 | 25 | 045 | 00100101 | % | % | Percent sign | |
| 38 | 26 | 046 | 00100110 | & | & & | Ampersand | |
| 39 | 27 | 047 | 00100111 | ' | ' | Apostrophe | |
| 40 | 28 | 050 | 00101000 | ( | ( | Left parenthesis | |
| 41 | 29 | 051 | 00101001 | ) | ) | Right parenthesis | |
| 42 | 2A | 052 | 00101010 | * | * | Asterisk | |
| 43 | 2B | 053 | 00101011 | + | + | Plus sign | |
| 44 | 2C | 054 | 00101100 | , | , | Comma | |
| 45 | 2D | 055 | 00101101 | - | - | Hyphen-minus | |
| 46 | 2E | 056 | 00101110 | . | . | Full stop / period | |
| 47 | 2F | 057 | 00101111 | / | / | Slash | |
| 48 | 30 | 060 | 00110000 | 0 | 0 | Digit 0 | |
| 49 | 31 | 061 | 00110001 | 1 | 1 | Digit 1 | |
| 50 | 32 | 062 | 00110010 | 2 | 2 | Digit 2 | |
| 51 | 33 | 063 | 00110011 | 3 | 3 | Digit 3 | |
| 52 | 34 | 064 | 00110100 | 4 | 4 | Digit 4 | |
| 53 | 35 | 065 | 00110101 | 5 | 5 | Digit 5 | |
| 54 | 36 | 066 | 00110110 | 6 | 6 | Digit 6 | |
| 55 | 37 | 067 | 00110111 | 7 | 7 | Digit 7 | |
| 56 | 38 | 070 | 00111000 | 8 | 8 | Digit 8 | |
| 57 | 39 | 071 | 00111001 | 9 | 9 | Digit 9 | |
| 58 | 3A | 072 | 00111010 | : | : | Colon | |
| 59 | 3B | 073 | 00111011 | ; | ; | Semicolon | |
| 60 | 3C | 074 | 00111100 | < | < < | Less-than sign | |
| 61 | 3D | 075 | 00111101 | = | = | Equals sign | |
| 62 | 3E | 076 | 00111110 | > | > > | Greater-than sign | |
| 63 | 3F | 077 | 00111111 | ? | ? | Question mark | |
| 64 | 40 | 100 | 01000000 | @ | @ | At sign | |
| 65 | 41 | 101 | 01000001 | A | A | Uppercase A | |
| 66 | 42 | 102 | 01000010 | B | B | Uppercase B | |
| 67 | 43 | 103 | 01000011 | C | C | Uppercase C | |
| 68 | 44 | 104 | 01000100 | D | D | Uppercase D | |
| 69 | 45 | 105 | 01000101 | E | E | Uppercase E | |
| 70 | 46 | 106 | 01000110 | F | F | Uppercase F | |
| 71 | 47 | 107 | 01000111 | G | G | Uppercase G | |
| 72 | 48 | 110 | 01001000 | H | H | Uppercase H | |
| 73 | 49 | 111 | 01001001 | I | I | Uppercase I | |
| 74 | 4A | 112 | 01001010 | J | J | Uppercase J | |
| 75 | 4B | 113 | 01001011 | K | K | Uppercase K | |
| 76 | 4C | 114 | 01001100 | L | L | Uppercase L | |
| 77 | 4D | 115 | 01001101 | M | M | Uppercase M | |
| 78 | 4E | 116 | 01001110 | N | N | Uppercase N | |
| 79 | 4F | 117 | 01001111 | O | O | Uppercase O | |
| 80 | 50 | 120 | 01010000 | P | P | Uppercase P | |
| 81 | 51 | 121 | 01010001 | Q | Q | Uppercase Q | |
| 82 | 52 | 122 | 01010010 | R | R | Uppercase R | |
| 83 | 53 | 123 | 01010011 | S | S | Uppercase S | |
| 84 | 54 | 124 | 01010100 | T | T | Uppercase T | |
| 85 | 55 | 125 | 01010101 | U | U | Uppercase U | |
| 86 | 56 | 126 | 01010110 | V | V | Uppercase V | |
| 87 | 57 | 127 | 01010111 | W | W | Uppercase W | |
| 88 | 58 | 130 | 01011000 | X | X | Uppercase X | |
| 89 | 59 | 131 | 01011001 | Y | Y | Uppercase Y | |
| 90 | 5A | 132 | 01011010 | Z | Z | Uppercase Z | |
| 91 | 5B | 133 | 01011011 | [ | [ | Left square bracket | |
| 92 | 5C | 134 | 01011100 | \ | \ | Backslash | |
| 93 | 5D | 135 | 01011101 | ] | ] | Right square bracket | |
| 94 | 5E | 136 | 01011110 | ^ | ^ | Caret | |
| 95 | 5F | 137 | 01011111 | _ | _ | Underscore | |
| 96 | 60 | 140 | 01100000 | ` | ` | Grave accent | |
| 97 | 61 | 141 | 01100001 | a | a | Lowercase a | |
| 98 | 62 | 142 | 01100010 | b | b | Lowercase b | |
| 99 | 63 | 143 | 01100011 | c | c | Lowercase c | |
| 100 | 64 | 144 | 01100100 | d | d | Lowercase d | |
| 101 | 65 | 145 | 01100101 | e | e | Lowercase e | |
| 102 | 66 | 146 | 01100110 | f | f | Lowercase f | |
| 103 | 67 | 147 | 01100111 | g | g | Lowercase g | |
| 104 | 68 | 150 | 01101000 | h | h | Lowercase h | |
| 105 | 69 | 151 | 01101001 | i | i | Lowercase i | |
| 106 | 6A | 152 | 01101010 | j | j | Lowercase j | |
| 107 | 6B | 153 | 01101011 | k | k | Lowercase k | |
| 108 | 6C | 154 | 01101100 | l | l | Lowercase l | |
| 109 | 6D | 155 | 01101101 | m | m | Lowercase m | |
| 110 | 6E | 156 | 01101110 | n | n | Lowercase n | |
| 111 | 6F | 157 | 01101111 | o | o | Lowercase o | |
| 112 | 70 | 160 | 01110000 | p | p | Lowercase p | |
| 113 | 71 | 161 | 01110001 | q | q | Lowercase q | |
| 114 | 72 | 162 | 01110010 | r | r | Lowercase r | |
| 115 | 73 | 163 | 01110011 | s | s | Lowercase s | |
| 116 | 74 | 164 | 01110100 | t | t | Lowercase t | |
| 117 | 75 | 165 | 01110101 | u | u | Lowercase u | |
| 118 | 76 | 166 | 01110110 | v | v | Lowercase v | |
| 119 | 77 | 167 | 01110111 | w | w | Lowercase w | |
| 120 | 78 | 170 | 01111000 | x | x | Lowercase x | |
| 121 | 79 | 171 | 01111001 | y | y | Lowercase y | |
| 122 | 7A | 172 | 01111010 | z | z | Lowercase z | |
| 123 | 7B | 173 | 01111011 | { | { | Left curly brace | |
| 124 | 7C | 174 | 01111100 | | | | | Vertical bar | |
| 125 | 7D | 175 | 01111101 | } | } | Right curly brace | |
| 126 | 7E | 176 | 01111110 | ~ | ~ | Tilde |
Extended ASCII 128–255
Not part of the ASCII standard. Shown here as Windows-1252, the most common mapping on the web; codes 160–255 match Latin-1 exactly, while 128–159 differ.
| Dec | Hex | Oct | Binary | Char | HTML | Code point | |
|---|---|---|---|---|---|---|---|
| 128 | 80 | 200 | 10000000 | € | € € | U+20AC | |
| 129 | 81 | 201 | 10000001 | — |  | Unused in Windows-1252 | |
| 130 | 82 | 202 | 10000010 | ‚ | ‚ ‚ | U+201A | |
| 131 | 83 | 203 | 10000011 | ƒ | ƒ ƒ | U+0192 | |
| 132 | 84 | 204 | 10000100 | „ | „ „ | U+201E | |
| 133 | 85 | 205 | 10000101 | … | … … | U+2026 | |
| 134 | 86 | 206 | 10000110 | † | † † | U+2020 | |
| 135 | 87 | 207 | 10000111 | ‡ | ‡ ‡ | U+2021 | |
| 136 | 88 | 210 | 10001000 | ˆ | ˆ ˆ | U+02C6 | |
| 137 | 89 | 211 | 10001001 | ‰ | ‰ ‰ | U+2030 | |
| 138 | 8A | 212 | 10001010 | Š | Š Š | U+0160 | |
| 139 | 8B | 213 | 10001011 | ‹ | ‹ ‹ | U+2039 | |
| 140 | 8C | 214 | 10001100 | Œ | Œ Œ | U+0152 | |
| 141 | 8D | 215 | 10001101 | — |  | Unused in Windows-1252 | |
| 142 | 8E | 216 | 10001110 | Ž | Ž Ž | U+017D | |
| 143 | 8F | 217 | 10001111 | — |  | Unused in Windows-1252 | |
| 144 | 90 | 220 | 10010000 | — |  | Unused in Windows-1252 | |
| 145 | 91 | 221 | 10010001 | ‘ | ‘ ‘ | U+2018 | |
| 146 | 92 | 222 | 10010010 | ’ | ’ ’ | U+2019 | |
| 147 | 93 | 223 | 10010011 | “ | “ “ | U+201C | |
| 148 | 94 | 224 | 10010100 | ” | ” ” | U+201D | |
| 149 | 95 | 225 | 10010101 | • | • • | U+2022 | |
| 150 | 96 | 226 | 10010110 | – | – – | U+2013 | |
| 151 | 97 | 227 | 10010111 | — | — — | U+2014 | |
| 152 | 98 | 230 | 10011000 | ˜ | ˜ ˜ | U+02DC | |
| 153 | 99 | 231 | 10011001 | ™ | ™ ™ | U+2122 | |
| 154 | 9A | 232 | 10011010 | š | š š | U+0161 | |
| 155 | 9B | 233 | 10011011 | › | › › | U+203A | |
| 156 | 9C | 234 | 10011100 | œ | œ œ | U+0153 | |
| 157 | 9D | 235 | 10011101 | — |  | Unused in Windows-1252 | |
| 158 | 9E | 236 | 10011110 | ž | ž ž | U+017E | |
| 159 | 9F | 237 | 10011111 | Ÿ | Ÿ Ÿ | U+0178 | |
| 160 | A0 | 240 | 10100000 |   | U+00A0 | ||
| 161 | A1 | 241 | 10100001 | ¡ | ¡ ¡ | U+00A1 | |
| 162 | A2 | 242 | 10100010 | ¢ | ¢ ¢ | U+00A2 | |
| 163 | A3 | 243 | 10100011 | £ | £ £ | U+00A3 | |
| 164 | A4 | 244 | 10100100 | ¤ | ¤ ¤ | U+00A4 | |
| 165 | A5 | 245 | 10100101 | ¥ | ¥ ¥ | U+00A5 | |
| 166 | A6 | 246 | 10100110 | ¦ | ¦ ¦ | U+00A6 | |
| 167 | A7 | 247 | 10100111 | § | § § | U+00A7 | |
| 168 | A8 | 250 | 10101000 | ¨ | ¨ ¨ | U+00A8 | |
| 169 | A9 | 251 | 10101001 | © | © © | U+00A9 | |
| 170 | AA | 252 | 10101010 | ª | ª ª | U+00AA | |
| 171 | AB | 253 | 10101011 | « | « « | U+00AB | |
| 172 | AC | 254 | 10101100 | ¬ | ¬ ¬ | U+00AC | |
| 173 | AD | 255 | 10101101 | | ­ ­ | U+00AD | |
| 174 | AE | 256 | 10101110 | ® | ® ® | U+00AE | |
| 175 | AF | 257 | 10101111 | ¯ | ¯ ¯ | U+00AF | |
| 176 | B0 | 260 | 10110000 | ° | ° ° | U+00B0 | |
| 177 | B1 | 261 | 10110001 | ± | ± ± | U+00B1 | |
| 178 | B2 | 262 | 10110010 | ² | ² ² | U+00B2 | |
| 179 | B3 | 263 | 10110011 | ³ | ³ ³ | U+00B3 | |
| 180 | B4 | 264 | 10110100 | ´ | ´ ´ | U+00B4 | |
| 181 | B5 | 265 | 10110101 | µ | µ µ | U+00B5 | |
| 182 | B6 | 266 | 10110110 | ¶ | ¶ ¶ | U+00B6 | |
| 183 | B7 | 267 | 10110111 | · | · · | U+00B7 | |
| 184 | B8 | 270 | 10111000 | ¸ | ¸ ¸ | U+00B8 | |
| 185 | B9 | 271 | 10111001 | ¹ | ¹ ¹ | U+00B9 | |
| 186 | BA | 272 | 10111010 | º | º º | U+00BA | |
| 187 | BB | 273 | 10111011 | » | » » | U+00BB | |
| 188 | BC | 274 | 10111100 | ¼ | ¼ ¼ | U+00BC | |
| 189 | BD | 275 | 10111101 | ½ | ½ ½ | U+00BD | |
| 190 | BE | 276 | 10111110 | ¾ | ¾ ¾ | U+00BE | |
| 191 | BF | 277 | 10111111 | ¿ | ¿ ¿ | U+00BF | |
| 192 | C0 | 300 | 11000000 | À | À À | U+00C0 | |
| 193 | C1 | 301 | 11000001 | Á | Á Á | U+00C1 | |
| 194 | C2 | 302 | 11000010 | Â | Â Â | U+00C2 | |
| 195 | C3 | 303 | 11000011 | Ã | Ã Ã | U+00C3 | |
| 196 | C4 | 304 | 11000100 | Ä | Ä Ä | U+00C4 | |
| 197 | C5 | 305 | 11000101 | Å | Å Å | U+00C5 | |
| 198 | C6 | 306 | 11000110 | Æ | Æ Æ | U+00C6 | |
| 199 | C7 | 307 | 11000111 | Ç | Ç Ç | U+00C7 | |
| 200 | C8 | 310 | 11001000 | È | È È | U+00C8 | |
| 201 | C9 | 311 | 11001001 | É | É É | U+00C9 | |
| 202 | CA | 312 | 11001010 | Ê | Ê Ê | U+00CA | |
| 203 | CB | 313 | 11001011 | Ë | Ë Ë | U+00CB | |
| 204 | CC | 314 | 11001100 | Ì | Ì Ì | U+00CC | |
| 205 | CD | 315 | 11001101 | Í | Í Í | U+00CD | |
| 206 | CE | 316 | 11001110 | Î | Î Î | U+00CE | |
| 207 | CF | 317 | 11001111 | Ï | Ï Ï | U+00CF | |
| 208 | D0 | 320 | 11010000 | Ð | Ð Ð | U+00D0 | |
| 209 | D1 | 321 | 11010001 | Ñ | Ñ Ñ | U+00D1 | |
| 210 | D2 | 322 | 11010010 | Ò | Ò Ò | U+00D2 | |
| 211 | D3 | 323 | 11010011 | Ó | Ó Ó | U+00D3 | |
| 212 | D4 | 324 | 11010100 | Ô | Ô Ô | U+00D4 | |
| 213 | D5 | 325 | 11010101 | Õ | Õ Õ | U+00D5 | |
| 214 | D6 | 326 | 11010110 | Ö | Ö Ö | U+00D6 | |
| 215 | D7 | 327 | 11010111 | × | × × | U+00D7 | |
| 216 | D8 | 330 | 11011000 | Ø | Ø Ø | U+00D8 | |
| 217 | D9 | 331 | 11011001 | Ù | Ù Ù | U+00D9 | |
| 218 | DA | 332 | 11011010 | Ú | Ú Ú | U+00DA | |
| 219 | DB | 333 | 11011011 | Û | Û Û | U+00DB | |
| 220 | DC | 334 | 11011100 | Ü | Ü Ü | U+00DC | |
| 221 | DD | 335 | 11011101 | Ý | Ý Ý | U+00DD | |
| 222 | DE | 336 | 11011110 | Þ | Þ Þ | U+00DE | |
| 223 | DF | 337 | 11011111 | ß | ß ß | U+00DF | |
| 224 | E0 | 340 | 11100000 | à | à à | U+00E0 | |
| 225 | E1 | 341 | 11100001 | á | á á | U+00E1 | |
| 226 | E2 | 342 | 11100010 | â | â â | U+00E2 | |
| 227 | E3 | 343 | 11100011 | ã | ã ã | U+00E3 | |
| 228 | E4 | 344 | 11100100 | ä | ä ä | U+00E4 | |
| 229 | E5 | 345 | 11100101 | å | å å | U+00E5 | |
| 230 | E6 | 346 | 11100110 | æ | æ æ | U+00E6 | |
| 231 | E7 | 347 | 11100111 | ç | ç ç | U+00E7 | |
| 232 | E8 | 350 | 11101000 | è | è è | U+00E8 | |
| 233 | E9 | 351 | 11101001 | é | é é | U+00E9 | |
| 234 | EA | 352 | 11101010 | ê | ê ê | U+00EA | |
| 235 | EB | 353 | 11101011 | ë | ë ë | U+00EB | |
| 236 | EC | 354 | 11101100 | ì | ì ì | U+00EC | |
| 237 | ED | 355 | 11101101 | í | í í | U+00ED | |
| 238 | EE | 356 | 11101110 | î | î î | U+00EE | |
| 239 | EF | 357 | 11101111 | ï | ï ï | U+00EF | |
| 240 | F0 | 360 | 11110000 | ð | ð ð | U+00F0 | |
| 241 | F1 | 361 | 11110001 | ñ | ñ ñ | U+00F1 | |
| 242 | F2 | 362 | 11110010 | ò | ò ò | U+00F2 | |
| 243 | F3 | 363 | 11110011 | ó | ó ó | U+00F3 | |
| 244 | F4 | 364 | 11110100 | ô | ô ô | U+00F4 | |
| 245 | F5 | 365 | 11110101 | õ | õ õ | U+00F5 | |
| 246 | F6 | 366 | 11110110 | ö | ö ö | U+00F6 | |
| 247 | F7 | 367 | 11110111 | ÷ | ÷ ÷ | U+00F7 | |
| 248 | F8 | 370 | 11111000 | ø | ø ø | U+00F8 | |
| 249 | F9 | 371 | 11111001 | ù | ù ù | U+00F9 | |
| 250 | FA | 372 | 11111010 | ú | ú ú | U+00FA | |
| 251 | FB | 373 | 11111011 | û | û û | U+00FB | |
| 252 | FC | 374 | 11111100 | ü | ü ü | U+00FC | |
| 253 | FD | 375 | 11111101 | ý | ý ý | U+00FD | |
| 254 | FE | 376 | 11111110 | þ | þ þ | U+00FE | |
| 255 | FF | 377 | 11111111 | ÿ | ÿ ÿ | U+00FF |
How ASCII encodes text
ASCII assigns a number to each character, and that number is what a computer actually stores. The encoding uses seven bits, which gives 128 possible values, numbered 0 to 127. Thirty-three of those are control codes that instruct a device rather than print anything; the remaining ninety-five are the printable characters — space, punctuation, the ten digits and the unaccented Latin alphabet in both cases.
The layout is not arbitrary, and noticing the structure makes the table far easier to remember. Uppercase letters run from 65 to 90 and lowercase from 97 to 122, a gap of exactly 32 — one bit — so changing case means flipping bit 6 and nothing else. The digits occupy 48 to 57, which in hexadecimal is 0x30 to 0x39, so the last hex digit is the numeral: mask off the high bits of the character '7' and you get the number 7. Control codes sit first precisely so that everything printable begins at a clean boundary, with space at 32.
The history of ASCII
ASCII was published in 1963 by the American Standards Association as ASA X3.4, the work of the X3.2 subcommittee on which IBM's Bob Bemer was a leading figure — he is often called the father of ASCII and is credited with getting the escape character into the standard. A significant revision in 1967 produced the layout still in use, and the 1986 edition, ANSI X3.4-1986, is the version usually cited today.
The control codes make much more sense once you know the machinery they were written for. These were teleprinters: BEL at code 7 rang a physical bell to get the operator's attention, BS moved the print head back one position so a character could be struck over, and the separation of carriage return from line feed existed because they were two distinct mechanical actions — return the carriage to the left margin, then advance the paper by one line. That distinction is the direct ancestor of the line-ending disagreement between Windows, which still writes both, and Unix, which writes only the line feed.
ASCII was not universal at first. IBM's mainframes used EBCDIC, an entirely different and incompatible encoding, and moving data between the two worlds was a standing nuisance for decades. What settled the matter was Unicode: when UTF-8 was designed in 1992, Ken Thompson and Rob Pike made the first 128 code points identical to ASCII and encoded them as single bytes with the same values. Every ASCII file became a valid UTF-8 file overnight, and that backward compatibility is a large part of why UTF-8 now encodes almost the entire web.
Extended ASCII is not one thing
Once hardware settled on eight-bit bytes, the spare bit left room for another 128 characters above 127 — and everyone filled that space differently. IBM's code page 437 put box-drawing characters and Greek letters there for the original PC. ISO 8859-1, usually called Latin-1, used it for Western European accented letters. Microsoft's Windows-1252 is Latin-1 with the unused 128–159 range filled in with curly quotes, dashes, the euro sign and similar typographic characters.
The consequence is that a byte above 127 has no single meaning. The value 233 is é in Latin-1 and Windows-1252, but Θ in code page 437. This is the root cause of the classic mojibake you still meet today — the "’" that appears where an apostrophe should be is UTF-8 bytes being read as Windows-1252. The table above shows the Windows-1252 interpretation because it is the one most often encountered on the web, and gives the Unicode code point for each so there is no ambiguity about which character is meant.
Where ASCII codes are still worth knowing
Looking up a code is a routine step in several everyday jobs. Debugging data that will not parse usually means finding a stray control character or a non-ASCII byte where plain text was expected. Writing or reading regular expressions often means working in character ranges, and knowing that digits are 48–57 and uppercase 65–90 explains why [A-Za-z0-9] is written the way it is. Escaping characters for HTML, URLs or a shell depends on knowing precisely which character you have. And anyone working with serial devices, terminal escape sequences or fixed-width file formats meets the control codes directly.
Related conversions live in their own tools: binary to text converts whole messages between 8-bit binary and readable text, the base converter moves any number between binary, octal, decimal and hexadecimal, and HTML encoder / decoder converts characters to and from the entity codes shown in the table. For characters beyond ASCII, see special characters & symbols, and for the invisible ones that break parsing, the invisible character detector.
Frequently asked questions
What is the ASCII value of A?
Uppercase A is 65 in decimal — 41 in hexadecimal, 101 in octal and 01000001 in binary. Lowercase a is 97, exactly 32 higher, and that offset holds for every letter in the alphabet, so Z is 90 and z is 122. The gap is deliberate rather than coincidental: 32 is a single bit, so the only difference between an uppercase and a lowercase letter is bit 6, which allowed early hardware and software to change case by flipping one bit instead of performing a lookup.
How many characters are in the ASCII table?
Standard ASCII defines 128 characters, numbered 0 to 127, because the encoding is seven bits wide. Thirty-three of those are non-printing control characters — codes 0 to 31 plus 127, the delete code — and the remaining ninety-five are printable, a count that includes the space at 32. Tables advertising 256 characters are showing extended ASCII, where everything above 127 is outside the ASCII standard and depends entirely on which code page the system is using.
What is the difference between ASCII and Unicode?
Scope, mainly. ASCII covers 128 characters, which is sufficient for unaccented English and nothing else. Unicode covers over 150,000 characters spanning essentially every writing system in use, along with symbols and emoji. The two were deliberately made compatible: the first 128 Unicode code points are identical to ASCII, and UTF-8 encodes exactly those as single bytes with the same numeric values. The practical upshot is that any file containing only ASCII is already valid UTF-8 with no conversion whatsoever, which is a large part of why UTF-8 displaced every competing encoding.
What are ASCII control characters used for today?
A small number remain essential and the rest are museum pieces. Line feed (10) and carriage return (13) still terminate lines, with Unix and macOS using LF alone while Windows writes CR followed by LF — a split inherited directly from teleprinters, where returning the carriage and advancing the paper were two separate mechanical operations. Tab (9) is ubiquitous, null (0) terminates strings in C and related languages, and escape (27) introduces the ANSI sequences that colour and position text in a terminal. The device control codes, the separators and most of the rest were designed for teletypes, paper tape and magnetic tape, and are effectively dead outside legacy protocols.
What is extended ASCII?
Extended ASCII is a loose label for any scheme that uses the eighth bit of a byte to add 128 more characters above code 127. The essential thing to understand is that there is no single extended ASCII: ISO 8859-1 (Latin-1), Windows-1252 and IBM code page 437 all assign completely different characters to the same numbers. Byte 233 is é in Latin-1 but Θ in code page 437, which is precisely why text moved between systems used to arrive as nonsense. The table on this page shows Windows-1252, the mapping most often met on the web, and lists the Unicode code point alongside each character so there is no ambiguity.
How do I convert text to ASCII codes?
Use the converter at the top of this page. Type or paste your text on the left, choose decimal, hexadecimal, octal or binary, and the codes appear immediately with one value per character. The panel works in both directions, so pasting 72 101 108 108 111 into the right-hand box returns Hello. Values are separated by spaces, and the reverse direction also accepts commas or line breaks. Everything is calculated in your browser, so nothing is uploaded. Characters above 127 are reported as Unicode code points, with a note, since they are not strictly ASCII.
Why is the ASCII code for a space 32?
Because the first thirty-two slots were reserved for control functions, so space — the first genuinely printable character — took the next one available. The choice proved unusually convenient. In binary, 32 is 00100000, a single bit set, which is what makes the offset between uppercase and lowercase letters exactly one bit. It also places space immediately before the punctuation, digits and letters in numeric order, so a plain sort by character code puts spaces first, which is generally what you want.