Site: US UK AU |

How to decompress files in gzip

How to decompress files in gzip

This article explains how to use the Linux or UNIX command line to decompress gzip files.

Method for .gz files

Use the following procedure to decompress gzip files from the command line:

  1. Use SSH to connect to your server.

  2. Enter one of the following:

    gunzip file.gz


    gzip -d file.gz
  1. To see the decompressed file, enter: 

    ls -1

Method for tar.gz and .tgz files

Files with the extension tar.gz or .tgz represent tar files compressed with gzip. Observe the following procedure to decompress these files from the Linux command line:

Use SSH to connect to your server.

For tar.gz files, enter:

gunzip < file.tar.gz | tar xvf -=

For .tgz files, enter:

gunzip < file.tgz | tar xvf -

If you use the GNU operating system also known as GNU Tar, use one of the following commands, depending on whether the file uses the tar.gz or .tgz extension:

tar xvzf file.tar.gz
tar xvzf file.tgz


For 24-hour assistance any day of the year, contact our Support Team by email or through the Client Portal.

Article Rating (1 Votes)
Rate this article
  • Icon PDFExport to PDF
  • Icon MS-WordExport to MS Word
Attachments Attachments
There are no attachments for this article.
Related Articles RSS Feed
Facility Access Policy (OTR)
Added on Mon, Jan 22, 2018
Colocation Access Card Request Form
Added on Tue, Oct 6, 2015
What is the DMCA?
Added on Mon, Dec 29, 2014
How to find a development partner
Added on Mon, Feb 16, 2015
How to flush Redis
Added on Thu, Apr 7, 2016
What is SOAP?
Added on Tue, Jan 6, 2015
How to request and revoke facility access (MEL, TMR)
Added on Mon, Jul 27, 2015
How to create SSH keys in macOS and Linux
Added on Tue, Oct 20, 2015
How to transfer domains
Added on Wed, Nov 23, 2016
What are the benefits of dedicated IP addresses?
Added on Thu, Jan 14, 2016