Executables & System · Updated · All file signatures

XAR & macOS .pkg Magic Bytes (xar!)

eXtensible ARchiver (XAR) is the archive container adopted by Apple for flat macOS Installer packages (.pkg). Every XAR archive starts at byte 0 with the 4-byte ASCII magic xar! (78 61 72 21), followed by header size (usually 00 1C), version (00 01), and a zlib-compressed XML table of contents.

Signature & identification summary

Detected format nameXAR archive
Hexadecimal magic bytes78 61 72 21
ASCII / marker previewxar!
Byte offset0
MIME typeapplication/x-xar
Common extensions & aliases.pkg, .xar, .mpkg

Check whether your file really is XAR / macOS PKG.

Drop any file into File Sniff’s free local browser checker to verify its 78 61 72 21 signature and spot misleading extensions—without uploading a single byte.

Check a file’s real type ↗︎

Container & byte-layout notes

Inside a macOS .pkg sit Distribution XML, Bom (Bill of Materials), Payload (a gzip/cpio archive of installed files), Scripts (preinstall/postinstall shell scripts) and optional Apple Developer ID X.509 CMS signatures.

Extension mismatches & common pitfalls

Because .pkg installers execute preinstall/postinstall scripts with administrator privileges on Mac, verify code-signing with pkgutil --check-signature before opening any downloaded .pkg.

Which apps open XAR / macOS PKG files?

PlatformCompatible applications & tools
Mac (macOS)macOS Installer, pkgutil / xar in Terminal, Suspicious Package (for safe inspection)
iPhone & iPadNot executable on iOS/iPadOS
Windows7-Zip (can inspect XAR contents read-only)

Free local tools & related guides

Inspect files & folders natively
on Mac, iPhone & iPad.

The native File Sniff app scans entire folders, spots extension mismatches, repairs extensions with Undo on Mac, and exports CSV or JSON reports locally.

Download on the App Store ↗︎