Extract tar gz on windows

A file using .tar.gz format is a file that has been created using the Unix-based archival application tar and then compressed using the gzip compression. These files are often referred to as “tarballs.” While you can find them with a double extension (.tar.gz), the extension can also be shortened to .tgz or .gz.

Usually, tar files are more common with Ubuntu (other Linux distros) and macOS users for data archival and backups. However, Windows 10 users may also come across these files, which is a reason to have a way to extract their contents.

Although you can use third-party apps (such as 7-Zip and PeaZip), these apps do not always work as expected with tarballs created on another platform, and they are slow to uncompress many files. However, Windows 10 includes native support for tar files, and you can use Command Prompt to extract these files. Or you can even use the Windows Subsystem for Linux (WSL) that includes native support for Ubuntu, Fedora, SUSE, and many other distros. Therefore, you can also access many Linux tools, including tar, to quickly extract content from tarballs.

This guide will teach you the steps to use native tar commands on Windows 10 from Command Prompt and Ubuntu to extract the content of a .tar.gz file.

  • Extract .tar.gz, .tgz, .gz tarballs using tar on Windows 10
  • Extract .tar.gz, .tgz, .gz tarballs using tar on Linux on Windows 10

To extract .tar.gz, .tgz, .gz, as well as .zip files using tar on Windows 10, use these steps:

  1. Open Start on Windows 10.

  2. Search for Command Prompt, right-click the top result, and select the Run as administrator option.

  3. Type the following command to use tar to extract the files and press Enter:

    tar -xvzf C:\PATH\TO\FILE\FILE-NAME.tar.gz -C C:\PATH\TO\FOLDER\EXTRACTION

    Native tar support on Windows 10

    Quick tip: Change the syntax to include the source and destination paths. Also, because you are using tar on Windows 10, you do not need to specify the path as if you were running Linux. You can use the path format used by Windows.

Once you complete the steps, you will have all the files and folders extracted to the destination path you specified after a few moments.

It is assumed that you are extracting a tarball created on another system. We are skipping some arguments usually necessary to preserve permissions, which on Windows 10 are not required to access the files. 

On Windows 10, to use tar on Linux, you need to install the Windows Subsystem for Linux (WSL) and a distro like Ubuntu from the Microsoft Store.

To extract a .tar.gz file using Linux on Windows 10, use these steps:

  1. Open Start.

  2. Search for Ubuntu and click the top result to open the app.

  3. Type the following command to extract the content of the .tar.gz file and press Enter:

    sudo tar -xvzf /mnt/c/PATH/TO/TAR-FILE/Desktop/FILE-NAME.tar.gz -C /mnt/c/PATH/TO/DESTINATION/FOLDER

    WSL tar command on Windows 10

    Quick tip: Update the syntax to include the source and destination paths. If it’s only a .tar file, you can use the same command described above but omit the z argument.

In the above command, sudo runs the app as an administrator, tar calls the app, and then we feed it some arguments, including:

  • x — instructs tar that you want to extract content.
  • v — verbose. This is an optional argument to display the extraction process. Otherwise, you will only see a blinking cursor until the process is complete.
  • z — tells tar to uncompress the content of a .tar.gz file with gzip.
  • f — instructs tar the name of the file you’re about to extract.

Then you need to specify the path of the tarball file to extract. You’ll notice that the path starts with /mnt/c/, instead of c:\ because you are now in the Linux world.

-C — (hyphen and capital C) is used to tell tar to change folders. When executing a command, you start in the source folder, and then you need to specify the destination folder, which is the path we specified to complete the command. You can extract the files to any folder you want, but remember to start the path with /mnt/ followed by the Windows path.

You must pay attention to uppercase and lowercase while typing a Linux command, as “Desktop” is not the same as “desktop.”

This guide outlines the basic steps to perform a specific task. If you are not a Linux user, you can learn more about this tool in the Ubuntu console by typing the tar --help command.

Last Updated :
30 Sep, 2024

If you’re trying to extract a TAR file on Windows, particularly a .tgz or tar.gz file, there are several ways to do it easily. Although Windows doesn’t natively support extracting these files, there are plenty of TAR file extraction tools for Windows that can help you. This guide will show you how to open .tgz files on Windows and outline the steps to effectively unpack TAR files using third-party tools or commands.

Table of Content

  • Steps to Extract TAR Files (.tgz) in Windows
    • Method 1: Extract TAR Files Using Command Prompt
    • Method 2: Extract TAR Files Using Third-Party Applications
    • Method 3: Extract TAR Files Using Online Converters
  • How to Extract a TAR File (.tgz) on Windows — FAQs

For unzipping TAR Files on Windows, the following methods should be used. We will start with one simple command where no third-party application help will needed.

Method 1: Extract TAR Files Using Command Prompt

Step 1: Search for the Command Prompt in the Search Bar. Open the prompt in the Administrative Format.

Step 2: Execute the following command. It will help to convert the TAR File to File Explorer Format without having much time. It will take some time to complete the process.

 Command: tar -xvzf <TAR-FIle-Location> -C <New-Location>

2--Execute-Command

If you want to extract the TAR Files on your local device, then have any third-party application on your device. There are many third-party applications present like 7-Zip or WinZip, etc. Using any one of those, you can Open TAR FIle on Windows.

You have to download & install the third-party apps on the device. Later, select any one TAR file & it will be directly converted to the simple folder structure. To open any TAR Folder inside the new one, select it again.

Hooray! You now have one third-party application installed on the device to Unzip Linux TAR Format on Windows.

Now, if you want to get your job reduced to some folds, there is another option present. It is to Extract the TGZ File Online. There are many Online Converters present on the internet that can be used for successful conversion.

You have to select the TAR File & want to choose the operation. If you want, it will convert the TAR File to RAR file which is the Native File Compressor for Windows. Or it can directly extract the files on your desktop.

4--Converter

Conclusion

Extracting TAR files on Windows is simple with the right tools. Whether you’re using a third-party utility or command-line options, knowing how to extract .tgz files can help you manage compressed files efficiently. By following these steps, you’ll be able to unzip TAR files on Windows with ease and have access to the data you need without any hassle.

A .tar.gz file, also known as a tarball, is a compressed archive used in UNIX and Linux systems. This format involves multiple files bundled into a single archive and compressed using gzip compression.

Although .tar.gz is commonly associated with UNIX and Linux distributions, you can also extract these files in Windows using various third-party tools.

This tutorial will show you how to extract .tar.gz files in a Windows environment.

How to Extract a .tar.gz File in Windows

Requirements

  • A Windows system (this tutorial uses Windows 11).
  • WinRAR, WinZip, and 7-Zip installed (for specific examples).
  • The tar tool (for some examples).
  • Access to Command Prompt.

How to Extract .tar.gz File in Windows

Since Windows doesn’t natively support .tar.gz files, extracting involves third-party tools or non-native commands. The following text outlines the process of extracting a .tar.gz file in a Windows environment.

Extract .tar.gz File in Windows Using tar Command

The tar (tape archive) command is a command-line utility for archiving files. 

The command bundles multiple files and directories into a single file archive but doesn’t compress data on its own. Therefore, it is often used with compression tools, such as gzip (tar.gz files) or bzip2 (tar.bz2 files), to reduce the overall archive size.

The tar command is not a native Windows command. It usually doesn’t come preinstalled in older Windows systems. However, newer versions (starting from Windows 10) have it preinstalled.

The following example shows how to extract a .tar.gzip file called archive_1 using the tar command. The archive_1 consists of three files: sample_file1, sample_file2, and sample_file3.

To extract the files using tar:

1. Open the Command Prompt.

2. Use the cd command to navigate to the directory the archive is in. In this case:

cd C:\files
cd command terminal output

3. Use the following syntax to extract files:

tar -zxvf [archive_name.tar.gz]

This command consists of:

  • -z. Specifies the input is compressed with gzip.
  • -xStands for extract.
  • -vEnables verbose mode to provide detailed output during extraction.
  • -fSpecifies the filename to be extracted.

For instance, in our case:

tar -zxvf archive.tar.gz
tar -zxvf archive.tar.gz terminal output

The output lists extracted files.

Note: Master the Command Prompt with our cmd commands guide which features a free downloadable cheat sheet.

Extract .tar.gz File in Windows Using 7-Zip

For a more GUI-friendly approach to extracting .tar.gz files, use 7-Zip.

Follow these steps to extract files from a .tar.gz archive:

1. Right-click the archive.

2. Find and hover over 7-Zip.

Right-click archive 7 zip

3. Choose Extract Here to extract files to the archive folder.

Extract here option in 7-Zip

4. Alternatively, select Extract files to pick where to extract the files.

Extract Files option in 7-zip

 A new window opens to manage where and how to extract files.

Extract files 7-Zip window

Extract .tar.gz File in Windows Using WinRAR

Another way to access archive files is to extract them via WinRar. To accomplish this, follow these steps:

1. Right-click the archive.

2. Hover over the WinRar icon.

Access WinRAR

3. Choose Extract Here to extract the file to your current location.

choose WinRAR extract here

Alternatively, select one of the offered locations or set one up by clicking the Extract files… option.

WinRAR extract options

Extract .tar.gz File in Windows Using WinZip

Extracting .tar.gz files using WinZip is also quite straightforward.

To get the files, follow these steps:

1. Right-click the archive file and hover over WinZip.

right-click archive Winzip

2. Choose whether to unzip to one of the offered locations or define one with the Unzip to… option.

Unzip to different options window

The Unzip to…option opens up another window with extra settings.

Winzip options window

3. Select Unzip to start the process.

Conclusion

After reading this article, you know how to extract .tar.gz files in Windows using the tar command, 7-Zip, WinZip, or WinRAR.

Next, learn how to extract .tar.gz files in Linux.

Was this article helpful?

YesNo

Extract .tar.gz, .tgz, or .gz tarballs using tar on Windows 10

To extract .tar.gz, .tgz, .gz as well as .zip files using tar on Windows 10, use these steps:

  1. Open Start on Windows 10.
  2. Search for Command Prompt, right-click the first result and select the Run as administrator option.
  3. Type the following command to use tar to extract the files and press Enter:
tar -xvzf C:\PATH\TO\FILE\FILE-NAME.tar.gz -C C:\PATH\TO\FOLDER\EXTRACTION

Extract .tar.gz, .tgz, or .gz tarballs using tar on Linux on Windows 10

To use tar on Linux, you need to install a distro (such as Ubuntu) by enabling the Windows Subsystem for Linux (WSL) using the Windows Features experience, and then installing Ubuntu from the Microsoft Store.

To extract a .tar.gz file using Linux on Windows 10, use these steps:

  1. Open Start.
  2. Search for Ubuntu and click the top result to open the app.
  3. Type the following command to extract the content of .tar.gz file and press Enter:
sudo tar -xvzf /mnt/c/PATH/TO/TAR-FILE/Desktop/FILE-NAME.tar.gz -C /mnt/c/PATH/TO/DESTINATION/FOLDER

TAR or Tape Archive file is an archive created by a Unix-based utility tar. These files are saved in an uncompressed format and include information about the files. However, mostly we see this file with the .gz extension, which is the GNU zip compression. GNU zip compression reduces the size of the archive to save disk space.

Extracting .tar.gz file in Windows

Which tools are recommended to extract a tar.gz file?

7Zip and WinRAR are both excellent tools for extracting TAR.GZ files. We recommend using 7Zip as it is a free and open-source file archiver software for compressing and decompressing files. If 7Zip doesn’t work for you, you can use WinRAR.

How to extract tar.gz files using 7Zip?

To extract TAR.GZ files using 7Zip, follow these simple steps:

  1. Go to the 7Zip official site and download the setup file.

    Downloading the 7-Zip
  2. Install 7Zip by following the installation steps.
  3. Go to your .tar.gz file location, right-click on it, and choose the Extract files option.
    Note: You can also set another location for extracting the files.

    Extracting the file through 7-Zip
  4. Click the OK button to extract the files in the same location.

How to extract tar.gz files using WinRAR?

To extract TAR.GZ files using WinRAR, follow these simple steps:

  1. Go to the WinRAR official site and download the setup file.

    Downloading WinRAR
  2. Install WinRAR by following the installation steps.
  3. Open the File Explorer and go to the location where your .tar.gz file is located.

    Extracting file through WinRAR
  4. Right-click on it and choose the Extract Files or Extract Here option.

In addition to 7Zip and WinRAR, there are other tools and methods available for extracting TAR.GZ files in Windows. However, these two applications are user-friendly and efficient. By following the steps provided in this article, you can easily extract TAR.GZ files and access their contents on your Windows machine.

Muhammad Zubyan

Muhammad Zubyan is a certified Google IT Support Professional with over 7 years of extensive experience. He has worked on more than 1500 computers, gaining valuable insights that enable him to detect and troubleshoot any complicated root cause of Windows-related issues and errors. In addition to managing Appuals as a Senior Editor, he is currently developing his own Game Optimization program that caters to both gamers and casual users alike.

Понравилась статья? Поделить с друзьями:
0 0 голоса
Рейтинг статьи
Подписаться
Уведомить о
guest

0 комментариев
Старые
Новые Популярные
Межтекстовые Отзывы
Посмотреть все комментарии
  • Синие курсоры для windows 10
  • Opera mini dlya windows 7
  • Asus f3j драйвера для windows 7
  • Разграничение прав доступа в локальной сети windows
  • Z83ii mini pc windows 10