Home

Xz

XZ refers to a data compression format and the XZ Utils software package. It uses the LZMA2 compression algorithm to deliver high compression ratios with fast decompression, making it competitive with other widely used formats such as gzip and bzip2, especially for large files. The XZ format supports streaming, a range of compression levels, and configurable dictionary sizes. It also provides an integrity check mechanism, with options such as CRC32, CRC64, or SHA-256 to verify data integrity. A single file compressed with XZ typically has the .xz extension, and XZ is also commonly used to compress tar archives (tar.xz).

The XZ Utils project includes command-line tools for compressing and decompressing data. The primary tool is

Historically, XZ Utils was developed as an open-source implementation of the XZ format, rooted in the LZMA

xz,
which
can
perform
compression
and
decompression,
with
options
to
preserve
the
original
file
(-k),
write
output
to
stdout
(-c),
and
control
multi-threading
(-T).
Examples:
to
compress
a
file,
run
xz
file.txt;
to
decompress,
run
xz
-d
file.txt.xz;
to
keep
the
original
file,
use
xz
-k
file.txt.xz.
For
multi-file
archives,
a
tar
archive
can
be
compressed
with
XZ,
for
example
using
a
command
such
as
tar
-cJf
archive.tar.xz
directory
(depending
on
the
tar
version
and
options).
compression
lineage
originating
with
Igor
Pavlov
and
later
extended
by
contributors
such
as
Lasse
Collin.
The
format
and
tools
have
been
adopted
across
Unix-like
systems
and
remain
widely
used
in
software
distributions
and
source
packages
due
to
their
balance
of
high
compression
efficiency,
streaming
support,
and
robustness.