GZ file format: what it is and how to use it
gzip is the Unix compression workhorse: DEFLATE in a tiny wrapper that powers .tar.gz, HTTP encoding and thirty years of pipelines. Learn when to use it and what to choose instead.
Files stay on your device
-
No uploadsFiles stay on your device
-
Batch processingHandle multiple files at once
-
100% privateNo sign-up, no tracking
What is a GZ file?
A .gz file is a stream compressed with gzip, Jean-Loup Gailly and Mark Adler's free 1992 answer to the patented compress: DEFLATE (LZ77 + Huffman) in a small header with a CRC32 footer. It compresses exactly one stream, which is why .tar.gz (aka .tgz) pairs it with tar for file sets, and why it became the web's Content-Encoding for two decades.
When should you use .gz?
- Unix convention:
.tar.gzis how source code, logs and datasets still ship. - Pipelines:
zcat/zless/grepchains that never decompress to disk. - Universal readability: every OS, language and tool on the planet speaks it.
When is another format a better fit?
For noticeably better ratio and speed today, zstd wins on both axes. For a Windows audience, ZIP is friendlier; for the web's text, Brotli. gzip's value is ubiquity: it is the compression nothing fails to read.
The short version: GZ is the safe middle of compression: not the best at anything, but readable by everything.
How to open a GZ file
On Windows
Double-click the file, or open it with 7-Zip.
In your browser
Open GZ files right in a browser tab or with the dexrr viewer. No install, no upload.
Also opens in
-
7-Zip
-
WinRAR
-
gzip (Unix)
-
tar (Unix)
View GZ files
A quick preview or a new format. No install, no upload.
GZ technical details
- Full name
- GZIP compressed file
- Extensions
- .gz .gzip
- MIME type
-
application/gzip, application/x-gzip - Magic bytes
-
1F 8B - Compression
- Lossless
- Developer
- Jean-loup Gailly & Mark Adler (RFC 1952)
- Specification
- datatracker.ietf.org
GZ questions, answered
How do I open a .gz file?
gunzip, tar -xzf, 7-Zip and most archive tools decompress it. dexrr extracts .gz files directly in your browser.
Can I convert GZ files online?
Yes, dexrr decompresses .gz and repacks the contents locally in your browser to zip or other formats.
Is GZ better than ZIP?
They solve different problems: .gz compresses one stream, .zip archives many files. For Unix pipes gzip is idiomatic; for users ZIP is friendlier.
What is a .tar.gz (or .tgz) file?
A tar archive (the file bundle) compressed with gzip: tar handles many-files-to-one, gzip handles one-to-smaller. Extract with tar -xzf.
Is the GZ format outdated?
Superseded technically by zstd, but its ubiquity is untouchable. It remains the compression baseline everything implements.