XZ vs Zstandard
A side-by-side feature comparison.
Summary
XZ holds the crown for raw compression ratio on most general data, but Zstandard catches up at its highest levels and decompresses an order of magnitude faster. The right choice depends on whether you optimize for download size or wall-clock time.
Feature comparison
| Feature | XZ | Zstandard |
|---|---|---|
| Algorithm | LZMA2 | Zstandard (FSE + LZ77) |
| Best ratio | Smallest | Closes gap at -19 |
| Decompression speed | Slow | 3-5× faster |
| Threading | Available with -T | Native |
| Dictionary mode | No | Yes |
| Memory at decompress | Up to 65 MB | Configurable |
About XZ
XZ is a single-file compressor wrapping the LZMA2 algorithm, released in 2009 by the Tukaani Project. It produces the smallest files of any mainstream Unix compressor, with strong integrity checks (CRC32, CRC64, SHA-256). XZ is now the default packaging format for many Linux distributions, replacing GZIP and BZIP2 for kernel and source releases.
About Zstandard
Zstandard, or zstd, is a modern compression algorithm released by Facebook in 2016. It targets a wide range of compression levels (1-22), giving developers the choice between gzip-class speed and xz-class ratios from a single tool. Zstd has become the default compression for Arch Linux packages, Btrfs, ZFS, and the Linux kernel.
Read the full Zstandard guide →
More comparisons
- ZIP vs RAR
- ZIP vs 7z
- RAR vs 7z
- tar.gz vs tar.xz
- tar.xz vs tar.zst
- gzip vs Zstandard
- 7-Zip vs WinRAR
- 7-Zip vs PeaZip
- Keka vs The Unarchiver
- ZIP vs tar.gz
- LZ4 vs Snappy
- bzip2 vs bzip3
- ISO vs IMG
- Parquet vs ORC
- VMDK vs qcow2
- APK vs AAB (Android App Bundle)
- CAB vs MSI
- DEB vs RPM
- DMG vs macOS PKG
- Flatpak vs Snap
- AppImage vs Flatpak
- 7z vs ZPAQ
- Borg vs restic
- EPUB vs MOBI