What a zip file is and why you need one

A zip file is a single container that holds one or more files or folders in a compressed format. When you zip something, the computer removes redundant data — repeated patterns, empty space, metadata — so the file takes up less room on your hard drive or transfers faster over the internet. The original files stay intact inside the zip; nothing is lost or damaged.

You create a zip file when you need to send multiple files to someone, back up a folder, or free up storage space. Most operating systems can create and open zip files without installing extra software, though the steps differ slightly between Windows, Mac, and Linux.

Key Takeaways

  • On Windows, right-click the file or folder, select "Send to", then choose "Compressed (zipped) folder" to create a zip file when ready.
  • On Mac, right-click or Control-click the file or folder and select "Compress" from the menu; the zip file appears in the same location.
  • On Linux, use the file manager's right-click menu or the command line tool zip to create archives, depending on your desktop environment.
  • Zip files preserve the original files — they are not deleted when you compress them, so you can delete the originals yourself if you want to save space.
  • The zip file size depends on what you are compressing; text files shrink more than photos or videos, which are already compressed.

Creating a zip file on Windows

On Windows 10 and Windows 11, the simplest method uses the right-click menu. Locate the file or folder you want to compress. Right-click it, and a menu appears. Look for "Send to" — hover over it, and a submenu opens. Click "Compressed (zipped) folder".

Windows creates a new zip file in the same location as the original, with the same name plus the .zip extension. If you compressed a folder called "Photos", the zip file is called "Photos.zip". The original folder and its contents remain untouched. If you want to save space, you can delete the original folder after confirming the zip file contains what you need.

If you do not see "Send to" in the right-click menu, your version of Windows may differ slightly. An alternative is to right-click, select "Compress to ZIP" if that option appears, or use the File menu in File Explorer: select the file or folder, go to the "Share" tab, and look for a compress option there.

Creating a zip file on Mac

On macOS, the process is nearly identical. Locate the file or folder you want to compress. Right-click it (or Control-click if you have a single-button mouse), and a menu appears. Select "Compress" — the exact wording may be "Compress [filename]" or just "Compress".

macOS creates a zip file with the same name as the original, plus .zip, in the same folder. The original file or folder stays where it is. If you have multiple files you want to zip together, select them all first by holding Command and clicking each one, then right-click and choose "Compress".

On newer Macs with Apple Silicon chips, compression happens almost when ready. On older machines, you may see a brief progress window. Either way, the zip file appears in Finder as soon as the process finishes.

Creating a zip file on Linux

Linux offers two main routes: the file manager's graphical menu or the command line. The graphical method depends on which desktop environment you use — GNOME, KDE, Xfce, and others have slightly different menus — but the principle is the same. Open your file manager, locate the file or folder, right-click it, and look for "Compress", "Create Archive", or "Compress Files". Select it, and a dialog may appear asking where to save the zip file and what to name it.

If the graphical menu does not offer a compress option, or if you prefer the command line, open a terminal. Navigate to the folder containing the files you want to zip. Type zip -r archive-name.zip filename-or-foldername, replacing "archive-name" with what you want to call the zip file and "filename-or-foldername" with the actual file or folder. The -r flag tells zip to include subfolders. Press Enter, and the zip file is created in your current directory.

For example, if you want to zip a folder called "Documents" and name the result "backup.zip", type zip -r backup.zip Documents. The original folder remains unchanged.

What happens to file size when you zip

The amount of space a zip file saves depends entirely on what you are compressing. Text files, spreadsheets, and word documents often shrink to 10 to 30 percent of their original size because they contain a lot of repetitive data. Images, videos, and audio files are already compressed by their format — a JPEG or MP4 file is already squeezed as tightly as the format allows — so zipping them saves little or no space.

If you zip a folder containing a mix of file types, the overall size reduction reflects the mix. A folder with mostly documents and a few photos might shrink by 20 percent. A folder with mostly videos might shrink by 2 percent or not at all. You can check the size of the original and the zip file by right-clicking each and selecting "Properties" (Windows) or "Get Info" (Mac) to see the difference.

Opening a zip file you have created

To verify that your zip file contains what you intended, you can open it without extracting everything. On Windows, double-click the zip file, and it opens in File Explorer showing the contents as a folder. On Mac, double-click it, and it opens in Finder. On Linux, double-click it in your file manager, or type unzip -l archive-name.zip in the terminal to list the contents without extracting.

If you want to extract all the files back to their original form, double-click the zip file on Windows or Mac and select "Extract All" or let it extract automatically. On Linux, type unzip archive-name.zip in the terminal. The files appear in a new folder or in the current directory, depending on how the zip was created.

Sending a zip file to someone else

Once you have created a zip file, you can email it, upload it to cloud storage, or transfer it to another device. The zip file is a single file, so it is easier to send than a folder full of separate files. Most email services accept zip files as attachments, though very large files may hit size limits — check your email provider's maximum attachment size.

If the zip file is too large to email, consider uploading it to a cloud service like Google Drive, Dropbox, or OneDrive, then sharing the link. The recipient can read the zip file and extract it on their end using the same method you used to create it — right-click and extract, or use the command line.

Frequently Asked Questions

Does zipping a file damage it or change it permanently?

No. Zipping is reversible. The original file is not changed, and when you extract it from the zip, it is identical to the original. The zip file is just a container; nothing inside it is altered or lost.

Can I edit a file inside a zip without extracting it?

Most programs require you to extract the file first. Some advanced tools on Windows and Mac allow you to open and edit files directly from a zip, but the safest approach is to extract, edit, and then re-zip if you need to send it again.

What if I zip a folder with subfolders inside?

The entire folder structure is preserved. When you extract the zip, all the subfolders and files appear exactly as they were, in the same arrangement. Use the -r flag on Linux to may support subfolders are included.

Can I password-protect a zip file?

Windows and Mac do not offer password protection in their built-in zip tools. On Linux, you can use the command zip -e archive-name.zip filename to create an encrypted zip. For Windows and Mac, you would need third-party software like 7-Zip or WinRAR.

Why is my zip file almost the same size as the original?

This usually means you are zipping files that are already compressed, like photos, videos, or PDFs. These formats remove redundant data during their own compression, so zipping them again saves little space. Zipping works best on text-based files.