Look up an ASCII code in decimal, hex and binary

Convert an ASCII character or control value among decimal, hexadecimal, octal, and binary notation.

freeworks offlinenothing uploaded
ToolASCII Table Reference
Input
Output
Put this on your own site

The frame below runs the same code as this page, in the reader's own browser. Nothing is sent to us, and nothing is sent to you.

Pick a dark background and the text and panels follow it, so the frame stays readable on a dark page.

Preview

How it works

Every 7-bit ASCII value from 0 through 127 is represented in four radices, with binary padded to eight visible digits for byte-oriented work. A separately labelled Latin-1 Supplement covers printable values 160 through 255 without redefining them as ASCII.

Formula
hex 0x41 = decimal 65 = octal 0o101 = binary 01000001 = A
  • Bare numeric input is decimal, 0x selects hexadecimal, and 0o selects octal.
  • One-character lookup is case-sensitive because uppercase and lowercase letters occupy different code positions.

Worked example

Character 65
Look up by decimal code
Input
											65
										
Output
												1 of 224 entries match "65":

Dec  Hex  Oct  Binary    Char  Name                  
65   41   101  01000001  A     Latin capital letter A
											

When to use this

Protocol debugging identifies CR and LF controls, source-code escapes translate numeric byte notation, and hex dumps map printable byte values back to ASCII characters.

Edge cases

  • 41 means decimal 41, while 0x41 means hexadecimal 65 and finds A; the prefix controls the radix.
  • A resolves to 65 and a resolves to 97 because a literal-character search preserves case.
  • 160 is a Latin-1 non-breaking space rather than ASCII, so it appears only in the separately named supplement.

References