Lossless compression

Lossless compression is a class of data compression algorithms that allows the original data to be perfectly reconstructed from the compressed data. Lossless compression methods are reversible. Examples of lossless compression include gzip, brotli, Zstandard, WebP, and PNG.

Lossy compression, on the other hand, uses inexact approximations by discarding some data from the original file, making it an irreversible compression method. Compression methods such as WebP are capable of both lossy and lossless compression depending on the compression level or the options you want to use during encoding.

See also