# How to unzip files in the command line

Examples on how to extract files in the command line (Sandbox Terminal Emulator). To extract a zipped file move to the directory where the file is or use the full path to the file.

The file will be extracted to the working directory. See working directory `pwd`

Move to desired directory

`cd /path/to/directory`

To extract a .gz file

`gzip -d filename.gz`

To extract a .tar file

`tar -xvf filename.tar`

To extract a tar.gz file

`tar -xzvf filename.tar.gz`

To extract .zip file

`unzip filename.zip`

Note that extracting large files will consume memory on your IVM and space in your home disk. If zipped files are large extracting may fail or your IVM may get stuck because it used all the memory. See [Managing memory in Sandbox](/working-in-the-sandbox/running-analyses-in-sandbox/managing-memory-in-sandbox-and-data-filtering-tips.md).


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.finngen.fi/faq/about-sandbox/how-to-unzip-files-in-the-command-line.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
