Skip to content
Everyday Utilities Free · No signup · Private · Instant results

ASCII Table Reference

Browse ASCII characters, decimal codes, hex, and HTML entities side-by-side.

About the ASCII Table Reference

The ASCII Character Table on HT99 Tools displays the 7-bit ASCII character set (codes 0–127) alongside the decimal, hexadecimal, and binary representations of each code point. Switch to Printable Only to focus on the 95 visible characters (32–126), or use Convert mode to encode a string of text into its ASCII decimal codes.

ASCII — the American Standard Code for Information Interchange, formalised as ANSI X3.4 in 1963 and ISO 646 in 1972 — maps 128 code points to characters. The first 32 (0–31) and code 127 are control characters designed for teletype and terminal control: LF (line feed, 10), CR (carriage return, 13), HT (horizontal tab, 9), ESC (escape, 27), DEL (delete, 127). The remaining 95 (32–126) are printable: space, digits, uppercase and lowercase letters, and punctuation.

ASCII is the foundation of every modern text encoding. UTF-8 (RFC 3629) was explicitly designed so that the first 128 code points are byte-identical to ASCII, which means any valid ASCII file is also valid UTF-8. Latin-1 (ISO 8859-1), Windows-1252, and every other ISO 8859 variant agree on the ASCII range.

How It Works

ASCII is a 7-bit code: each code point fits in 7 bits, so it occupies the range 0–127. When stored in a byte, the high bit is 0. The standard divides the 128 codes into two groups: 33 control codes (0–31 and 127) and 95 printable codes (32–126). Code 32 is the space character — the only printable character that produces no visible mark.

The tool computes the decimal value with char.charCodeAt(0), the hexadecimal value with code.toString(16) (uppercased and zero-padded to two digits), and the binary value with code.toString(2) (zero-padded to eight bits). The character itself is rendered with String.fromCharCode(code) for printable codes; for control codes, the standard mnemonic (NUL, SOH, STX, ..., DEL) is shown instead.

The mnemonics come from the original 1963 ANSI X3.4 standard. NUL is null (code 0); SOH is start of heading (1); STX is start of text (2); ETX is end of text (3, also what Ctrl+C sends); EOT is end of transmission (4); ACK is acknowledge (6); BEL is bell (7, which historically rang a physical bell on the teletype); BS is backspace (8); HT is horizontal tab (9); LF is line feed (10, the Unix newline); VT is vertical tab (11); FF is form feed (12); CR is carriage return (13, the Mac Classic newline); ESC is escape (27, which begins ANSI terminal escape sequences); DEL is delete (127).

Worked Examples

Convert mode with the default input HT99 produces a four-row table: H → 72 / 0x48 / 01001000, T → 84 / 0x54 / 01010100, 9 → 57 / 0x39 / 00111001, 9 → 57 / 0x39 / 00111001. The Copy button emits the decimal codes as a space-separated string: 72 84 57 57.

Full table mode renders 64 rows of two columns each. Row 1 shows 0 / 0x00 / NUL next to 64 / 0x40 / @; row 33 shows 32 / 0x20 / SP (space) next to 96 / 0x60 / ` (backtick). The letter A is code 65 (0x41), Z is 90 (0x5A), a is 97 (0x61), z is 122 (0x7A). The digits 09 are codes 48–57.

Printable Only mode drops the 33 control codes and renders just the 95 visible characters in a compact 48-row table. This is the range most modern developers actually care about — the control codes are mostly historical (teletype protocol characters) except for LF, CR, HT, and ESC, which still appear in terminal protocols today.

When to Use This Tool

  • Looking up the decimal or hex code of a character for an HTML numeric entity (AA).
  • Converting a short string to ASCII decimal codes for an escape sequence or a Caesar cipher exercise.
  • Debugging why a string with embedded control characters behaves strangely in a terminal.
  • Teaching the difference between LF (10), CR (13), and CRLF in cross-platform file handling.
  • Building a lookup table for an ASCII-art or terminal-graphics project.
  • Verifying that a string is pure ASCII (no characters above 127) before passing it to a system that does not support UTF-8.
  • Resolving a numeric HTML entity (&#XX;) to its character by hand.

Limitations & Disclaimer

The tool displays the 7-bit ASCII range only (0–127). Convert mode uses charCodeAt, which returns UTF-16 code units; for characters above U+007F the result is the UTF-16 code unit value, not the ASCII value (which does not exist for those characters). For Unicode code points above the BMP (e.g. emoji), use codePointAt in a dedicated Unicode inspector. The control-character mnemonics are the original 1963 ANSI X3.4 names; some standards (ISO 646) use slightly different names. See our disclaimer for full terms.

Frequently Asked Questions

What is the difference between ASCII and UTF-8?

ASCII is a 7-bit encoding (128 code points); UTF-8 is a variable-length encoding that can represent every Unicode code point. UTF-8 was designed so that the first 128 code points are byte-identical to ASCII — every valid ASCII file is also valid UTF-8. UTF-8 uses one byte for ASCII, two bytes for Latin-1 supplement and Greek, three bytes for most CJK and Indic scripts, and four bytes for emoji and historic scripts.

Why are there only 128 ASCII characters?

Because the original 1963 standard was designed for a 7-bit channel (teletype machines that transmitted 7 bits per character with a parity bit). 7 bits give 128 possible values, which was plenty for English letters, digits, punctuation, and 33 control codes. Eight-bit extensions (Latin-1, Windows-1252) doubled the capacity to 256, but those are not ASCII — they are supersets.

What are the control characters used for today?

Mostly legacy. <code>LF</code> (10) is the Unix line ending; <code>CR</code> (13) is the classic Mac line ending; <code>CRLF</code> is the Windows and HTTP line ending. <code>HT</code> (9) is the tab key. <code>ESC</code> (27) begins ANSI escape sequences (colours, cursor movement) in terminals. <code>BEL</code> (7) beeps the terminal. The others &mdash; <code>SOH</code>, <code>STX</code>, <code>ETX</code>, etc. &mdash; were teletype protocol characters and are obsolete except in embedded systems and amateur radio protocols.

How does the tool handle characters above 127?

In Convert mode, the tool uses <code>charCodeAt(0)</code>, which returns the UTF-16 code unit. For characters above U+FFFF (emoji, historic scripts), this returns the value of a surrogate half &mdash; not the actual code point. For ASCII-range characters (0&ndash;127), it works correctly. For Latin-1 (128&ndash;255), it returns the ISO 8859-1 value. For higher code points, prefer a Unicode code-point lookup tool.

What is the difference between charCodeAt and codePointAt?

<code>charCodeAt</code> returns the 16-bit UTF-16 code unit at a position. For characters in the Basic Multilingual Plane (BMP, U+0000 to U+FFFF), it returns the code point. For supplementary characters (above U+FFFF), it returns the high or low surrogate half (a value between 0xD800 and 0xDFFF). <code>codePointAt</code> (ES2015) returns the actual Unicode code point, correctly handling supplementary characters.

Is my input uploaded anywhere?

No. The table is generated entirely in the browser. Any text you convert never leaves the device.

Last updated: September 9, 2026  ·  Author: HT99 Tools Editorial Team