.TGZ

TGZ File

Gzip-Compressed TAR Archive
Ask a question
QUICK ANSWER

A TGZ file is a gzip-compressed TAR archive - the same thing as .tar.gz, just spelled for old 8.3 filenames. On Windows use free 7-Zip or PeaZip, or run tar -xzf file.tgz in a terminal (Windows 10/11 include tar). On macOS, double-click and Archive Utility handles it. On Linux, tar -xzf file.tgz. The format has no built-in encryption, so scan contents before running anything from an untrusted source.

Developer: The GNU Project (tar + gzip) Category: Compressed Files Open standard MIME: application/gzip
OPENS ON Windows macOS Linux Android
Related: .RAR · .ZIP · .Z01 · .7Z

On this page

19k+ extensions indexed
Last reviewed Jun 16, 2026

Not sure what your file is?

Drop any file into our identifier - we read just the first bytes to name the format.

Identify a file

What is the TGZ file format?

.tgz is an archive format produced by the GNUzip (Gzip) tool. This format is in no way related to the Windows ZIP format. .tgz files store TAR archives that have been compressed with the DEFLATE algorithm via gzip. The .tgz extension is equivalent to .tar.gz - the two are exactly the same format; .tgz is simply the 8.3-compatible short form of .tar.gz, introduced to fit the DOS/Windows filename length limit.

GNUzip originated on Unix systems and was designed to replace the older compress archiving format. Gzip was created as a free replacement for compress and other patent-encumbered compression algorithms in use at that time. The .tar.gz spelling is more popular on Unix-like platforms, while the .tgz form is commonly seen on Windows. Software packages for Linux distributions - including source releases and system tools - are frequently distributed as .tgz archives.

Because gzip compresses the entire TAR stream as one solid block rather than compressing files individually, it is not possible to list or extract a single file without decompressing the whole stream. .tgz archives carry a gzip magic signature (1F 8B 08) at offset 0; the inner TAR structure is revealed only after decompression. Gzip archives containing TAR data are commonly referred to as "tarballs" in IT and open-source circles.

Security & safety

RISK: LOW

The tar+gzip formats are open and safe, and a .tgz is just compressed data that can't run by itself. Standard archive caution: a .tgz from an untrusted source can contain scripts or executables revealed only after extraction, so scan contents before running anything. Two technical notes: a tiny .tgz can expand enormously ('decompression bomb'), and tar members can carry '../' paths (path-traversal / 'tar slip') - modern extractors guard against this, but extract untrusted tarballs into an empty folder.

Format details

in a nutshell
FULL NAMEGzip-Compressed TAR Archiveaka tarball, tar.gz
DEVELOPERThe GNU Project (tar + gzip)since tar (1979, Unix V7); gzip (1992); .tgz is the DOS/8.3-safe form of .tar.gz
MIME TYPEapplication/gzip
TYPETAR archive wrapped in a single gzip stream (DEFLATE)
STANDARDOpen · royalty-free
MAGIC BYTES · FILE SIGNATURE
OFFSET
000102
HEX
1F8B08
ASCII
···
A .tgz IS a gzip file, so it carries the gzip signature 1F 8B 08 at offset 0. The TAR is INSIDE the gzip stream: after decompression the embedded tar shows "ustar" at offset 257 of the first 512-byte tar header. So tgz = gzip outside, tar inside.

Programs that open TGZ files

Windows4 apps
WinRAR Paid Double-click to open and Extract; handles .tgz/.tar.gz in one pass. (7-Zip/PeaZip are the free choices.)
7-Zip Open-source Right-click the .tgz > 7-Zip > Open archive (or Extract Here); 7-Zip shows the .tar, extract once more to get the files. Free; also creates .tgz/.tar.gz.
PeaZip Open-source Open the .tgz and Extract - it unwraps the gzip and tar layers in one step.
tar (built-in, Windows 10/11) Built-in In a terminal: tar -xzf file.tgz - bsdtar ships with Windows 10 1803+ and Windows 11.
macOS3 apps
The Unarchiver Free Set as default for .tgz and double-click to extract. Free on the Mac App Store.
Archive Utility (built-in) Built-in Double-click the .tgz in Finder - macOS decompresses and untars it automatically. No install needed.
Keka Free Drag the .tgz onto Keka to extract; Keka also CREATES .tgz/.tar.gz with options.
Linux2 apps
tar (CLI) Open-source tar -xzf file.tgz to extract; tar -czf out.tgz folder/ to create. Pre-installed everywhere.
Ark / File Roller / Xarchiver Open-source Default KDE/GNOME/XFCE archive managers: open the .tgz and Extract from the GUI.
Android1 app
ZArchiver Free Tap the .tgz and Extract; handles both gzip and tar layers. Also creates .tgz.

Technical details

deep spec
Container structureTAR archive wrapped in a single gzip stream; files are not compressed individually but as one solid stream
Compression algorithmDEFLATE via gzip (RFC 1952); the entire TAR payload is compressed as one contiguous block
EncodingBinary
Byte orderLittle-endian (gzip header fields stored in little-endian order)
Magic bytes`1F 8B 08` at file offset 0 (gzip ID1/ID2 bytes + DEFLATE method flag); inner TAR reveals `ustar` at offset 257 only after decompression
MIME type`application/gzip`; alternatives include `application/x-gzip`, `application/x-compressed-tar`, `application/x-gtar`
Relation to .tar.gzIdentical binary format; `.tgz` is the 8.3-filename-safe alias of `.tar.gz`, introduced for DOS/Windows compatibility
Typical useLinux/Unix software source releases, system backups, dataset distribution, package archives
EncryptionNone built-in; gzip and tar provide no encryption - encrypt separately (e.g. with GPG) before or after archiving
Integrity checkinggzip footer contains CRC-32 and ISIZE (uncompressed size mod 2^32); each 512-byte tar header also carries its own checksum field
TAR header size512 bytes per entry, storing filename, permissions, ownership, and timestamps; long filenames supported via GNU or pax extensions
TAR format variantsv7, USTAR (POSIX.1-1988), GNU tar, POSIX pax (POSIX.1-2001) - all can be wrapped in a `.tgz`
File count limitEffectively unlimited; files are appended sequentially in the tar stream with no hard cap
Random accessNot supported; the gzip stream must be decompressed from the beginning before any individual entry can be read or extracted
Typical file sizeTens of KB to several GB (source tarballs, backups, dataset archives)
Platform supportNative on Linux, Unix, and macOS; Windows 10 and 11 include a built-in `tar` command with `.tgz` support
Releasedtar (1979, Unix V7); gzip (1992); .tgz is the DOS/8.3-safe form of .tar.gz
Latest versionPOSIX.1-2001 (pax) tar + gzip RFC 1952
Open standardYes · royalty-free
Specificationwww.rfc-editor.org

TGZ conversions

Community Q&A

asked by users
Ask a quick question
Get help from people who work with TGZ files. Be specific - include your system and software version.
No account needed · answers usually within a day

No questions yet - be the first to ask about TGZ files.

Frequently asked questions

What is a TGZ file?
It's a gzip-compressed TAR archive - identical to .tar.gz, just spelled for old 8.3 filenames. Many files are bundled into one .tar, then the whole tar is gzip-compressed.
What's the difference between .tgz and .tar.gz?
None - they're the same format. '.tgz' is the short, DOS/Windows-safe spelling of '.tar.gz'. You open and create both the same way.
How do I open a TGZ file on Windows?
Explorer doesn't open .tgz natively, so use free 7-Zip or PeaZip (right-click > Extract). Windows 10/11 also has built-in tar: run tar -xzf file.tgz in a terminal.
How do I open a TGZ on Mac?
Just double-click it - macOS Archive Utility decompresses and untars it automatically. Keka or The Unarchiver work too.
How do I extract a TGZ in one step on Linux?
tar -xzf file.tgz. To create one: tar -czf archive.tgz folder/.
Why does my TGZ extract to a .tar that still needs extracting?
Because a .tgz has two layers - gzip outside, tar inside. Tools like 7-Zip remove the gzip first (giving a .tar), so you extract once more. PeaZip/Keka/tar do both at once.

References

1RFC 1952 - GZIP file format specificationwww.rfc-editor.org
2GNU tar - official manualwww.gnu.org

Keep exploring

across the database

Top extensions this week

1.AQQAQQ Instant Messenger File
2.BINCD/DVD Disc Image (BIN/CUE)
3.CRDOWNLOADChrome Partial Download File
4.MDMarkdown Document
5.RPMSGRestricted Permission Message
6.PARTPartial Download File
7.NOMEDIAAndroid No-Media Marker File
8.DBSQLite Database File
9.EXEWindows Executable (Portable Executable)
10.SWFSmall Web Format (Shockwave Flash)

Related extensions

.RARRAR Archive (Roshal ARchive)
.ZIPZIP Archive
.Z01Split ZIP Archive - First Part
.7Z7-Zip Archive
.001Split / multi-volume archive - first part (.001)
.ZIRenamed / Truncated ZIP Archive

Free file tools

An in-browser file identifier and image converter - everything runs on your device.

Open the toolbox

Browse file extensions A-Z