How to password protect a zip file on Mac

Before talking about password protection for a zip file, ask yourself this: is your entire computer as safe and secure as it should be? Surely if you’re concerned with encrypting a single zip file, you’ll also see the value in providing the highest level of protection for all of the data on your Mac. Use MacKeeper's ID Theft Guard to prevent your personal data leakage.

System Requirements: macOS 10.11 or later

60+ million downloads

i

AV-TEST certified

AV-TEST is an independent lab that checks the effectiveness of antivirus apps against real malware samples.

i

Notarized by Apple

Notarization by Apple is a security measure to check if software is free from malicious components.

i

Trustpilot is an independent digital platform that hosts insightful and honest consumer reviews.

How to password protect a zip file on Mac
Written by   Steven John
Updated: September 13, 2025

Our computers get cluttered with dozens of documents from work, hundreds of pictures from friends, spreadsheets packed with personal information, health forms, financial paperwork, and on it goes.  

 

If your computer is slowing as it gets overloaded with data, the best thing to do is create zip files that can compress the size of many files, storing all the data in one place and occupying less space on your Mac. Zip files are easy to move from folder to folder or to transfer to other people via email or file-sharing platforms, and they’re time-tested and reliable.

 

But unless you take the steps needed to encrypt a zip file on a Mac, zipped files are not secure. That means anyone who gets access to your zip files — whether by intercepting an email or file transfer, hacking into your computer, or gaining physical access to your Mac — can open the zip file and thereby access dozens or even hundreds of files within.

 

Taking the minute or so required to password protect a zip file on Macs is, therefore, a very good idea. So if you are wondering how to password protect a folder on Mac, you’re in the right place.

A note from our experts

 

Extra protection for important zip files on Mac is a good idea. A better idea is an extra protection for your MacBook. With MacKeeper’s ID Theft Guard protections in place, you can count on the security of your personal data. If your data is ever breached and leaked, you’ll be instantly informed of the data breach so you can quickly re-secure everything.

 

To bring more protection to your data, follow these steps:

  1. Open MacKeeper and go to the ID Theft Guard section
  2. Click Scan new email and enter your email address.
  3. Now click Start Scan.
  4. Review the list of any leaked personal records  
  5. To guarantee better data protection in the real-time mode, end up with clicking Turn on Monitoring.
To protect your email from personal data leakage, run Mackeeper and select ID Theft Guard, then click Scan new email.
Step 1. MacKeeper > ID Theft Guard > Scan new email
Enter your email address in the corresponding box and click Start Scan.
Step 2. Click Start Scan

Are zipped files safe? Not without encryption

Simply put, a zip file is like a storage bin for other files, and a “bin” in which the other files are compressed. It means they take up less room on a computer, make for a smaller email attachment, and can be loaded onto a portable drive more easily.

 

A zip file may seem safer than an ordinary file, but it only offers as much security to the data within as does an unlocked door. Anyone can simply open the door and walk through, gaining access to whatever is beyond it. So, a zip file may be great for saving space on your Mac, but it adds no appreciable security for many sensitive files stored inside. Thus, do your best to form a new healthy habit—create a zip file and then encrypt it with a password.

How to create a zip file on a Mac

To create a zip file, it’s a good idea to move all the files you want housed in the new compressed file into a folder together. For your convenience, you can prepare and organize files for compression and password protection using the Finder function of your Mac. Just click File in the top corner of the screen, then click New Finder Window and use the window to search for the files to be included.

To create a zip file on a Mac, select files to be zipped, right-click, and select Compress Items

Then simply select all the files to be zipped together, right click, and select: Compress # Items (the “#” will indicate the number of files selected). A zip file will be created, and you can then rename it as you’d like.

You can rename a created zip file as you’d like.

How to encrypt a zip file on a Mac using Terminal

So, you have your zip file ready? Good, now let’s secure it with a password. First, to make things easy, move that new zipped file to the desktop.

 

Now, for the actual password addition, we’ll use the Terminal window that you can find there on your Mac. To find it, you can simply hit Command + Spacebar, then type the word “Terminal” into the Spotlight Search bar.

To find Terminal, hit Command + Spacebar, then type the word Terminal into the Spotlight Search bar.

A window will open looking like this:

The Terminal window opens on your Mac.

And yes, that may look confusing, but don’t worry, just follow these steps exactly:

  1. On the second line, after what will likely be your username (but regardless, do this after all text) type in the letters “cd desktop” and then hit Enter/Return.
  2. Now type in, exactly, albeit with your filename standing in for YOURFILENAME, of course “zip -er YOURFILENAME.zip YOURFILENAME”.
  3. You’ll then be prompted to enter a password—type it in, and note you may not be able to see any characters being added as you do so. Hit Enter.
  4. Re-enter the password to confirm it, and… you’re done!
To encrypt a zip file on a Mac using Terminal, on the second line, type in the letters cd desktop and then hit Enter/Return. Now type in, zip -er YOURFILENAME.zip YOURFILENAME. Enter a password if prompted.

Using Terminal to review an encrypted zip file

Terminal has a Previewing Files option that allows you to check the contents of an encrypted zip file without opening it. Doing this can be helpful in determining whether or not it’s safe to open a zip file, critical if you weren’t its creator. To do so, follow these steps:

  1. Open Terminal, again using Spotlight Finder and typing “Terminal”.
  2. In Terminal, type the word “zipinfo” and then add a space.
  3. Drag the zip file you wish to review behind the word “zipinfo,” then hit Enter.
To review an encrypted zip file using Terminal, open Terminal, and type the word zipinfo and then add a space. Drag the zip file you wish to review behind the word zipinfo, then hit Enter.

And that’s it! The files will be listed out for you.

How to open a password-protected zip file

To open a password protected zip file, simply click on it as you would on any other file and, when the box prompting a password pops up, type it in and hit Enter. The zip file will now open and decompress, allowing access to all the files within as usual. Just note that, once open, those files are no longer secure, so make sure you know how to protect your privacy online using MacKeeper before you reopen the locked folder.

Why encryption is the best security solution for zip files

Now you know how to encrypt a file on Mac. And when you add password encryption to a zip file on a Mac, you’re thereby securing every file within that zipped file in one fell swoop. A file thus secured is much safer for transfer, for long term storage, and for sharing. And as compression and password protection is agnostic to the desktop operating system, you can send password protected zip files to Windows users, Linux users, and other Mac users.

 

Just as you should always use MacKeeper’s ID Theft Guard to safeguard your sensitive information from any malicious actions and misuse, you should always take the extra minute to secure a zip file. It’s the perfect tool for overall better data protection, while there’s no harm that can come of it, and so much potential harm that’s prevented.

Use your Mac to the fullest! Sign up and get:
Effective tips on how to fix Mac issues
Reliable advice on how to stay safe online
Mac-world news and updates

Thank you!

You’ll love exploring your Mac with us.

Oops, something went wrong.

Try again or reload a page.

Here’s another sign you need to upgrade your macOS ASAP:

30% off your MacKeeper subscription

Сopy the code now and use it in the MacKeeper checkout after the upgrade.

Copy Code

Please be aware that this code cannot be combined with any other discounts, offers, or promotions.

Contents

Unlocked

Wish to keep your zip file safe?

Try MacKeeper’s ID Theft Guard.
PC

MacKeeper - your all-in-one solution for more space and maximum security.

Try Now

Read more

Bar1 New Tab Virus on Mac
Bar1 New Tab Virus on Mac
Can You Get a Virus from an Email on Mac
Can You Get a Virus from an Email on Mac
arrow

Run Application

step_1

Click Continue

step_2

Click Install

step_1

Your macOS version is lower than OS 10.11. We’d like to offer you MacKeeper 4 to solve the cleaning, privacy, and security issues of your macOS.