RAR and ZIP often compress large files for easy storage and sharing. Similar to these extensions is the GZ file. It is far rarer than the other alternatives because it originates from Linux and Unix operating systems.
If you encounter the file as a Windows user, you’ll be stuck with one question – how to open GZ files on Windows? Unzipping these files is quite easy; once you understand the method, it’ll be a matter of minutes.
Let us first understand what GZ files are and then jump into how to read the GZ file in Windows 7/10/11.
What Is a GZ File?
TAR.GZ, TGZ, or GZ files are typically found in Unix-based operating systems like macOS and Ubuntu and are usually used for compressing large files, backups, and data archiving. They’re also employed for regular data archiving purposes, thus making an appearance in Windows 7, 10, and 11 systems.
Since it originates from the Unix-based operating system, you’ll find the process of how to open a GZ file in Linux to be fairly simple. All you need to do is:
- Launch Terminal Utility.
- Type command GZip-dk SOURCE.GZ. Replace the SOURCE.GZ with the actual path of your GZ file.
- Press Enter.
- The file would be extracted.
Note – If it’s a .TAR.GZ file, use the command tar-xf SOURCE.tar.GZ in the terminal.
How to Open GZ Files in Windows?
While it is simply a matter of typing commands in Linux, extracting GZ files in Windows has a few more extra steps. The operating system offers several methods of unzipping. If you prefer commands, then there’s the command prompt method. In case you favor GUI (graphical user interface), then third-party applications can help you.
The solutions for how to open GZIP file in windows 10, 11, and 7 are:
Method 1 – Through Command Prompt
Windows has a built-in command called tar that can be used within the command prompt to extract the GZ archive contents. It is a foolproof and straightforward method for “how to open GZ files in windows 10.”
Once you have your file handy, follow the given steps:
1.From the Start menu, find Command Prompt and run it as administrator.
2.Select Yes from the prompt.
3.Enter the command tar-xvzf SOURCE -C DESTINATION. Replace DESTINATION with the target folder and SOURCE with the GZ file’s source.
4.Press Enter.
5.If the command works, you’ll find the extracted files in the selected target folder.
If, even after a successful run, you cannot find the extracted files in the target location, then you must not have run the prompt using admin privileges. Try running the program again as an administrator; it should work now.
Method 2 – Using the 7-Zip Tool
Third-party apps are an effective and easy answer to “how to open GZ files on Windows.” One such software is 7-Zip. It is a free and open-source file archiver. Due to its high compression ratio, it can be used in any computer, especially commercial ones. The program is beneficial in extracting files and even creating new ones in your preferred extension.
The steps to extract TAR files using 7-zip are:
- First, download the 7-zip extractor from the official site.
- Launch the software.
- Under the app, navigate to the GZ file.
- Click Extract present on the top left corner.
5.Right-click on the file, go to 7-zip, and then Extract Files. A new window will open.
6.You’ll notice that a path is already given in the Extract to box. If you wish to change it, overwrite it with your preferred destination.
7.Click OK after completion.
8.Within the app, double-click on the extracted folder to open it.
Method 3 – Through Winzip Tool
Winzip is another prevalent GZ file extractor with an intuitive and lightweight GUI. It integrates itself seamlessly into the system and works with precision. The software also offers features like file encryption, splitting and un-splitting big files, extracting multiple archives, and much more.
Here’s how you can use it to extract your files:
- Download the software according to your system type (32 or 64-bit).
- Open the app.
- Navigate to the GZ folder and select Open from the right side Actions windows.
4.Choose the location in the “Would you like to unzip the contents of this Zip file now?” prompt.
5.The files will open based on your choice.
Method 4 – How Can I Unzip GZ Files With Powershell?
Powershell is a task-based command-line scripting and shell language built with .NET. The system administrators can process and automate tasks using the programming language’s different commands.
It comes preinstalled with the Windows operating system. However, it can be downloaded from Microsoft’s official site if you find it absent. To use Powershell for unzipping GZ files, follow the given steps:
- From the Start menu, find Powershell.
- Launch the app with Administrative privileges.
- Type the following commands:
4.Press Enter.
5.You should now be able to extract all GZ files.
Method 5 – Converting through online TGZ converter
Windows 10 and 11 have an in-built ZIP extractor that allows automatic retrieval. One way of opening the contents of GZ files is simply converting them to ZIP. Once the files are converted, users can use the Extract All function to decompress the file.
What you need to do is:
Open Convertio on your preferred web browser. It is a free website for converting TGZ (TAR.GZ) into any other file format and vice versa.
2.Click on Choose Files and select a TGZ archive for conversion.
3.Click Open to proceed and add the file to the website.
4.From the Conversion Type, select “Zip.”
5.Press the Convert button.
6.After Convertio completes the process, click Download. It’ll get saved in the Downloads folder.
7.Open the folder and double-click on the extracted files to open the Extract tab.
8.Click on Extract all; a new pop-up window will appear.
9.Select the destination for the extracted file and tap on Extract.
Conclusion
As Unix-based software like macOS becomes more prevalent, it is better to acquaint yourself with these extraction methods if you’re a Windows user. They’re quite handy and easy to use, and if you follow them to the T, the files will be yours in minutes.
Try these methods once, and let us know which one worked the best for you!
Code:
function unzip($path,$to) {
$7z = “$env:TEMP\7z”
if (!(test-path $7z) -or !(test-path “$7z\7za.exe”)) {
if (!(test-path $7z)) { md $7z | out-null }
push-location $7z
try {
write-host “Downloading 7zip” -foregroundcolor cyan
$wc = new-object system.net.webClient
$wc.headers.add(‘user-agent’, [Microsoft.PowerShell.Commands.PSUserAgent]::FireFox)
$wc.downloadFile(“http://softlayer-dal.dl.sourceforge.net/project/sevenzip/7-Zip/9.20/7za920.zip”,”$7z\7z.zip”)
write-host “done.” foregroundcolor green
add-type -assembly “system.io.compression.filesystem”
[io.compression.zipfile]::extracttodirectory(“$7z\7z.zip”,”$7z”)
del .\7z.zip
}
finally { pop-location }
}
if ($path.endswith(‘.tar.GZ’) -or $path.endswith(‘.tGZ’)) {
# This is some crazy s**t right here
$x = “cmd”
$y = “/C `”^`”$7z\7za.exe^`” x ^`”$path^`” -so | ^`”$7z\7za.exe^`” x -y -si -ttar -o^`”$to^`””
& $x $y
} else {
& “$7z\7za.exe” x $path -y -o”$to”
}
}