File Extension & Magic Byte Checker
Inspect file magic bytes (first 512 bytes) to detect renamed extensions and true MIME types.
- 100% On-Device Execution
- Zero Files Uploaded to Server
- Reads ONLY the first 512 bytes via Blob.slice(0, 512) — zero memory load even for 500 MB files.
How to Use File Extension & Magic Byte Checker
3 Quick StepsFollow these steps to process your data or files directly inside your browser:
- 1Drop or choose any file (even large archives or unknown binary files up to 500 MB).
- 2Compare the filename extension against its real binary hex magic signature.
- 3Flag Mismatched / Spoofed extensions immediately and inspect the hex header.
Technical Architecture & Key Capabilities
Local RAM OnlyReads strictly bytes 0..512 via File.slice(0, 512).arrayBuffer() and matches leading byte offsets against known magic headers before printing a compact hex/ASCII view.
Included Workbench Capabilities
- Uses Blob.slice(0, 512) so multi-hundred-MB files are inspected in < 5ms without loading into RAM
- Detects PNG, JPEG, WebP, GIF, PDF, ZIP/DOCX/XLSX, MP3, MP4, ELF, PE/EXE, SQLite, WASM, GZIP, and UTF-8 text
- Compares declared file extension against detected magic signature (Match vs Mismatch alert)
- Displays raw 32-byte hex & ASCII header dump
Support
Frequently Asked Questions About File Extension & Magic Byte Checker
Quick answers about how this works, what it assumes, and where its limits are.
Why does Extension Checker check magic bytes instead of trusting the filename?
Anyone can rename photo.png to photo.jpg or executable.exe to invoice.pdf. Binary magic bytes at offset 0 reveal the genuine file format.
Does checking a 200 MB video file freeze my browser?
No. Because it calls file.slice(0, 512), the browser only reads half a kilobyte from disk.
Why do .docx and .xlsx files show a PKZIP signature?
Modern Office Open XML documents (.docx, .xlsx, .pptx) are literally ZIP archives containing XML files (magic bytes 50 4B 03 04).
Knowledge Center
Related Technical Tutorials & Guides
Deep-dive articles on client-side file processing, data validation, and privacy.
Static Offline QR Payloads, Magic-Byte File Verification & Metadata Privacy
Why direct Wi-Fi, vCard, and Geo QR payloads never expire compared with tracked dynamic shortlinks—and how client-side magic bytes and metadata inspection detect spoofed files or EXIF leaks.
Decimal Precision, Canonical SI Unit Normalization & Web Crypto SHA-256 Verification
Explore how deterministic calculators avoid IEEE 754 floating-point drift, why unit converters normalize through SI base units, and how `crypto.subtle.digest` verifies file integrity.
Inspecting JWTs, Avoiding Regex Backtracking, Cron Syntax & Asset Minification
Practical developer handbook for decoding Base64URL JSON Web Tokens safely offline, preventing catastrophic regex backtracking (ReDoS), reading 5-field cron schedules, and lexical HTML/CSS/JS minification.
Related Utilities
More Free Online Tools
Explore more instant on-device file, format, and developer utilities.
MIME Type Lookup Directory
Searchable MIME Content-Type reference by extension, category, or uploaded file lookup.
File Metadata Viewer
Inspect file timestamps, PNG/JPEG binary dimensions & bit depth, and PDF header metadata safely.
Binary to Text Converter
Decode space-separated or continuous 8-bit binary sequences back into readable UTF-8 text.
Text to Binary Converter
Encode plain text into padded 8-bit UTF-8 binary bytes with space or newline grouping.
Background Color Changer
Swap solid, uniform, or transparent image backgrounds for clean white, dark studio, or custom brand colors in seconds.
Image Background Remover
Turn white, green-screen, or uniform backgrounds into crisp transparent PNGs using click-to-sample keying and edge feathering.
