.xz

What is a .xz file?

XZ is a high-ratio compression format using LZMA2 — the default for many Linux package repositories.

Safe format
Type Archive
By Lasse Collin
MIME application/x-xz

Drop any file to identify it

No upload. No signup. No sending your file halfway across the internet.
We tell you what it is, right here in your browser.

What is it

You're installing software on Linux and the source archive is a .tar.xz file. XZ has become the default compression format for many Linux distributions because it achieves some of the best compression ratios available — noticeably smaller than gzip or bzip2, though slower to compress.

XZ uses the LZMA2 algorithm (the same one behind 7Z archives), which is why the compression is so effective. Decompression is fast — it's only the compression step that takes time, which is fine for distribution archives that are compressed once and downloaded millions of times. The Linux kernel, GNU core utilities, and most major open-source projects ship their tarballs as .tar.xz.

Linux handles XZ natively (`tar -xJf archive.tar.xz`). macOS needs the xz command-line tool (install via Homebrew: `brew install xz`). On Windows, 7-Zip opens .tar.xz files. If you encounter one, it almost certainly came from a software project. If you're creating archives, XZ is the right choice when download size matters more than compression speed.

Technical details
Full Name
XZ Compressed File
MIME Type
application/x-xz
Developer
Lasse Collin
Magic Bytes
FD 37 7A 58 5A 00
Safety
.xz is a known, safe format.
What opens it
Built-in on Linux
FREE Linux
7-Zip
FREE Windows
The Unarchiver
FREE macOS
FAQ
Why is XZ used instead of gzip?
XZ produces significantly smaller files — often 30-50% smaller than gzip. The tradeoff is slower compression, but decompression is fast. For software distribution (compress once, download millions of times), XZ is the efficient choice.
How do I open .tar.xz on macOS?
Install the xz tools via Homebrew (`brew install xz`), then use `tar -xJf archive.tar.xz`. The Unarchiver (free, Mac App Store) also handles .tar.xz files with a double-click.
Related formats