What is Gzip Compression Checker?
This gzip compression checker shows how much gzip shrinks your data. Paste text, JSON, HTML, CSS or JavaScript into the Compress tab and it compresses it with real gzip in your browser, then reports the original size, the compressed size and the percentage saved, along with the compressed data as Base64.
That tells you what a payload will actually cost over the network when a server sends it with Content-Encoding: gzip. The Decompress tab works the other way: paste gzip data as Base64 (H4sI…) or hex (1f8b…) to get the original text back and see the same size comparison.
How to use Gzip Compression Checker
- Choose Compress & Analyze to measure compression, or Decompress to read gzip data.
- In Compress, paste your text, JSON or source code.
- Read the original size, the gzip size and the percentage saved, and copy the Base64 gzip output if you need it.
- In Decompress, paste Base64 or hex gzip data to see the original text and its size.
Key features
- Real gzip compression using the browser's CompressionStream
- Original size, compressed size and percentage saved
- Compressed output as Base64
- Decompression of Base64 and hex gzip data
- Runs entirely in your browser
Common use cases
- Estimating the transfer size of API responses and JSON payloads
- Comparing how well different data formats compress
- Checking the benefit of enabling gzip on a server or CDN
- Creating gzip-compressed Base64 test data
- Reading gzip-compressed values from logs and databases
Technical details & standards
Compression uses the browser's native CompressionStream with the gzip format (RFC 1952, DEFLATE compression), the same algorithm web servers use for Content-Encoding: gzip, so the sizes are a good guide to real transfer sizes. Sizes are measured in UTF-8 bytes, and the saving is (1 − compressed ÷ original) × 100.
Text with repetition, such as JSON, HTML and minified JavaScript, typically shrinks by 60–85%, while already-compressed data (images, video, zip files) barely shrinks and can even grow slightly because of the 18-byte gzip header and trailer. Brotli usually compresses text a further 15–25% compared with gzip.
Frequently asked questions
What is a good gzip compression ratio?
For text formats, a saving of 60–85% is typical: JSON and HTML often shrink to a fifth of their size. If you see less than 20%, the data is probably already compressed or very random, such as Base64-encoded images.
Why is my compressed output bigger than the input?
Very short or already-compressed inputs cannot shrink, and gzip adds about 18 bytes of header and trailer. Servers usually skip compression for responses below about 1 KB for this reason.
How do I check whether a website uses gzip?
Open your browser's developer tools, select a request in the Network tab and look for Content-Encoding: gzip (or br for Brotli) in the response headers, or run curl -sI -H "Accept-Encoding: gzip" https://example.com.
Should I use gzip or Brotli?
Brotli compresses text about 15–25% better and is supported by all modern browsers over HTTPS, so serve Brotli where possible and keep gzip as the fallback for older clients and tools.
Is my data safe?
Processing happens locally in your browser. Tool input is not sent to CodeUnpack servers.
Does it work offline?
Once the page has loaded, this tool can process input without an internet connection.