File Type Detector (Magic Bytes)
Reads the first 512 bytes of any dropped file in the browser and matches them against a table of ~35 well-known file signatures (PNG, JPEG, GIF, WebP, PDF, ZIP, GZIP, 7z, MP3, FLAC, MP4, MKV, WOFF2, ELF, PE, SQLite, …). Compares the detected type against the browser-reported MIME (which comes from the OS, usually from the extension) and flags mismatches — useful when checking downloaded archives, verifying that a renamed .jpg really is a JPEG, or sanity-checking user-uploaded files before processing.
How to use
- Drop or pick any file.
- Read the detected type — if it disagrees with the declared one, the badge will tell you.
Frequently asked questions
- Does the file leave my browser?
- No. Only the first 512 bytes are read, and only locally through the File API. Nothing is uploaded.
- Why does a .docx come up as ZIP?
- DOCX, XLSX, PPTX, JAR, EPUB, and OOXML are all ZIP containers under the hood. To distinguish them you'd need to inspect a specific entry inside the archive — magic-byte detection alone can't tell them apart.
- The signature matches, but the file still will not open. Why?
- Magic bytes only describe the beginning of a file. A download that was cut short, a binary transferred in text mode (which rewrites line endings inside the data), or a container whose payload is corrupt all keep a perfectly valid header while the rest is unusable. Detection tells you what a file claims to be, not that it is complete.
- Can two formats share one signature?
- Yes, and ZIP is the clearest case: .docx, .xlsx, .odt, .jar, .apk and .epub are all ZIP archives, so their real identity is decided by what sits inside rather than by the first bytes. Some formats are also identified by bytes further into the file, which is why a very short file, or one wrapped in another container, can come back unidentified.
Guides on this topic
Related tools
MIME Type Lookup
Find the MIME type for a file extension (or the other way around) and learn what each type is for.
EML File Viewer
Drop an `.eml` file and read the parsed message — key headers, plain-text and HTML body parts, and a list of attachments — all in the browser.
File Encoding Detector
Upload any text file and detect its encoding — UTF-8, UTF-16 LE/BE, UTF-32, Latin-1, ASCII — with BOM detection, byte signal analysis, and a hex preview.
Byte Size Converter (KB / KiB / MB / MiB / ...)
Convert between decimal (KB, MB, GB — SI base 1000) and binary (KiB, MiB, GiB — IEC base 1024) byte units, plus bits.
File Hash (Checksum)
Compute SHA-1, SHA-256, and SHA-512 checksums of any file.
File Splitter
Split a large file into smaller chunks to bypass attachment or upload size limits.