THE TOOLBOX / BINARY & CHARACTER ENCODING
Inspect hex dumps &
ASCII control codes.
View strings and local binary files in canonical hexdump -C format, detect magic file signatures, export C uint8_t arrays, and search the 128-entry ASCII table.
THE DETAILS
Canonical hexdump -C byte offsets, binary magic signatures, and ANSI X3.4 7-bit ASCII encoding.
1. Canonical 16-Byte hexdump -C Layout
Modeled directly on BSD/GNU hexdump -C and xxd, every 16-byte line pairs an 8-digit hex address offset with two 8-byte hex octet blocks and a synchronized |ASCII| gutter so protocol framing and struct alignment are immediately visible.
2. Binary Magic Header Detection
Drop any local file to inspect its leading bytes and automatically identify magic headers including PNG (89 50 4E 47), JPEG (FF D8 FF), GIF89a, PDF (%PDF), ZIP/JAR/DOCX (50 4B 03 04), ELF binaries (7F 45 4C 46), and WebAssembly (00 61 73 6D).
3. Firmware & C uint8_t[] Array Export
Switch to the C uint8_t[] tab to export any binary header or test payload as a ready-to-compile C/C++/Rust byte array literal (const uint8_t payload[N] = { 0x48, 0x65, ... };).
4. Searchable 7-Bit ASCII Table (0–127)
Filter all 33 control codes (`NUL`, `BEL`, `BS`, `HT`, `LF`, `CR`, `ESC`, `DEL`) and 95 printable characters across Decimal, Hexadecimal, Octal, and 8-bit Binary. Need multi-byte Unicode grapheme counting or Base64 encoding? Use the Case & UTF-8 Byte Converter, Base64 & URL Converter, or Number Base & IEEE 754 Calculator.
Common Binary Magic Signatures & ASCII Control Codes Matrix
| Format / Control Code | Hexadecimal Byte Sequence | ASCII / Escape Representation |
|---|
| PNG Image Header | 89 50 4E 47 0D 0A 1A 0A | .PNG\r\n\x1A\n (detects 7-bit stripping) |
| WebAssembly Module | 00 61 73 6D 01 00 00 00 | \0asm + version 1 little-endian |
| UTF-8 Byte Order Mark (BOM) | EF BB BF | U+FEFF (Zero-Width No-Break Space) |
| HTTP Header Delimiter (CRLF) | 0D 0A 0D 0A | \r\n\r\n (CR = 13, LF = 10) |
Common Encoding & Byte Debugging Pitfalls
Invisible UTF-8 BOM Breaking JSON/Shell
Files saved in Windows Notepad with a leading EF BB BF UTF-8 BOM cause #!/bin/sh shebang lines and strict JSON parsers to fail at byte 0.
Smart Quotes vs. ASCII Quotes
Curly quotes pasted from word processors encode as 3-byte UTF-8 sequences (E2 80 9C and E2 80 9D) instead of ASCII 0x22 ("), causing syntax errors in code and CLI flags.
Null Byte String Truncation (0x00)
In C-family languages and PostgreSQL TEXT columns, a null byte (0x00 NUL) terminates strings prematurely or raises an invalid byte sequence error.
ASCII Case-Bit Flipping (Bit 5 / 0x20)
In 7-bit ASCII, uppercase letters (`A` = `0x41`) and lowercase letters (`a` = `0x61`) differ by exactly bit 5 (`0x20 = 32`), allowing branchless bitwise case conversion (`ch ^ 0x20`).
Frequently Asked Questions
What is the canonical hexdump -C format?
The canonical hexdump -C (and xxd) layout prints 16 bytes per row divided into three columns: an 8-digit hexadecimal byte offset on the left, two groups of 8 hexadecimal byte octets in the center, and a 16-character printable ASCII gutter enclosed in vertical pipes |...| on the right (where non-printable bytes below 0x20 or above 0x7E are rendered as dots).
How can I spot hidden UTF-8 Byte Order Marks (BOM) or zero-width spaces?
Paste the suspect string into the payload box. A UTF-8 BOM immediately appears at offset 00000000 as the 3-byte sequence EF BB BF, and a Unicode Zero-Width Space (U+200B) appears as the 3-byte sequence E2 80 8B even though it is invisible in text editors.
What are file magic numbers (file signatures)?
Operating systems and parsers identify binary file formats by inspecting the first few bytes of a file rather than trusting the filename extension. For example, PNG files always begin with 89 50 4E 47 0D 0A 1A 0A, PDF documents begin with 25 50 44 46 (%PDF), and WebAssembly modules begin with 00 61 73 6D (\0asm).
What is the difference between CR (0x0D) and LF (0x0A) line endings?
In the 7-bit ASCII standard (ANSI X3.4), LF (Line Feed, decimal 10, hex 0x0A) moves the cursor down one line (used by Unix, Linux, and macOS), whereas CRLF (Carriage Return 0x0D followed by Line Feed 0x0A) returns to column 0 and advances one line (used by Windows and HTTP/1.1 headers).
Are binary files uploaded to any server when I inspect them?
No. Files are read directly from disk into a local Uint8Array via File.arrayBuffer() inside your browser tab with zero network activity.