Home › Developer Tools › Hex Dump and File Inspector

Hex Dump and File Inspector

Choose a file to see its bytes as offset, hex and ASCII, in pages of 256 bytes. Files up to 2 MB are supported.

Choose a file to begin.
Size (bytes)-
Zero bytes-
Printable ASCII bytes-
No file loaded.
Your file is read in your browser and is never uploaded. Nothing about it is stored, and no request leaves the page.

How to use

  1. Press the file chooser and pick a file of 2 MB or less. A larger file is refused before it is read.
  2. Read the three figures: size in bytes, the count of zero bytes and the count of printable ASCII bytes. They cover the whole file, not only the visible page.
  3. Study the dump. Each line is an offset, sixteen bytes in hex and the same bytes as text.
  4. Use Next and Previous to move through the file 256 bytes at a time. The label between the buttons shows which page and byte range you are on.

Worked example

Take a 22-byte file that holds the text Hello, tools4free!, a line feed, a zero byte, and the two bytes c3 bf. The tool shows two lines:

00000000  48 65 6c 6c 6f 2c 20 74  6f 6f 6c 73 34 66 72 65  Hello, tools4fre
00000010  65 21 0a 00 c3 bf                                 e!....

The offset on the second line is hex 10, which is byte 16. The line feed (0a) and the zero byte (00) are not printable, so each shows as a dot, and so do both bytes of c3 bf. The summary reads size 22, zero bytes 1, printable bytes 18. The other three bytes are neither zero nor printable ASCII.

How it works

Reading the file. When you choose a file, your browser reads its bytes locally. The file is never uploaded, and nothing about it is stored. Files over 2 MB are refused before they are read.

Each line shows the byte offset (the position from the start of the file, in hex), then 16 bytes in two-digit hex with an extra gap after the eighth byte, then the same bytes as ASCII. Printable characters (space to tilde) appear as they are. Every other byte is shown as a dot.

Pages. The file is shown 256 bytes at a time (16 lines per page). Use Previous and Next to move through it.

Summary. The size is the file size in bytes. Zero bytes counts the 0x00 bytes, and printable bytes counts those from 0x20 to 0x7E.

The ASCII range comes from the US-ASCII standard, summarised in RFC 20. Bytes above 0x7F are not ASCII, so a UTF-8 character outside basic Latin shows as dots, as the example does. The File API is what lets a web page read a chosen file without sending it anywhere.

Reading what you see

Many formats begin with a short signature, sometimes called magic bytes, that you can spot at offset 0:

Starts with (hex)Shown asUsually means
89 50 4e 47 0d 0a 1a 0a.PNG....PNG image
ff d8 ff...JPEG image
25 50 44 46 2d%PDF-PDF document
50 4b 03 04PK..ZIP archive, and formats built on it such as DOCX
7f 45 4c 46.ELFLinux executable

Common mistakes

Frequently asked questions

Is my file uploaded?

No. The browser reads it on your device, and no request leaves the page.

Why are some bytes shown as dots?

Only bytes from 0x20 to 0x7E have a visible ASCII character. All others, including control codes and bytes above 0x7F, appear as a dot.

Why is the middle gap in each line?

It splits the sixteen bytes into two groups of eight, which makes it easier to count across.

Can I edit the file here?

No. This is a viewer only, and the file on your disk is never changed.

Does a zero byte count mean the file is corrupt?

No. Many valid formats contain zero bytes. A high count can hint at binary data or padding, while text files rarely have any.

Related tools