Compress and decompress text with Gzip/Deflate and show size savings (Brotli via wasm).
The Gzip Inspector compresses text or bytes into gzip, zlib or raw deflate, and decompresses data back, showing sizes and ratios. For gzip data it also reads the header fields such as modification time, operating system and CRC-32.
All three use the DEFLATE algorithm (RFC 1951), which combines LZ77 matching of repeated sequences with Huffman coding. They differ only in the wrapper around the compressed stream. Raw deflate has no wrapper. Zlib (RFC 1950) adds a 2-byte header and an Adler-32 checksum. Gzip (RFC 1952) adds a 10-byte header that can hold a file name and timestamp, and ends with a CRC-32 checksum and the original size modulo 2^32. HTTP Content-Encoding: gzip uses the gzip format, while many libraries and file formats embed zlib or raw deflate. Brotli is a different algorithm and is not offered by this tool. Because compressed bytes are not printable text, they are usually shown as Base64 or hex.
No. Only gzip, zlib and raw deflate are supported.
They share the same DEFLATE compression and differ in the wrapper. Gzip has a larger header and a CRC-32, zlib has a 2-byte header and an Adler-32 checksum, and raw deflate has neither.
Very small, random or already compressed data cannot be shrunk, and the wrapper adds bytes. The card then reads Grew by.
It is the checksum of the uncompressed data stored in the gzip trailer. The trailer also stores the original size modulo 2^32.
Compression input is limited to 20 MB, and decompressed output larger than 100 MB is rejected.
No. Compression and decompression run in the page using the fflate library.