Are you worried about your files being accessed without your permission? Sometimes, our confidential data might be stolen due to the files not being protected. If you have some private data, files, pictures, videos and you do not want anyone to see them or access them you can password protect Zip file Mac OS X. If you don’t know how to do this, this article will explain you in simple steps.

Creating the password protected zip files

  • First of all you need to select the file or folder you wish to protect the data, it can be pictures, documents or any folder.
  • Click “Command” + “Space” keys at the same time to open the Spotlights search (default keybinds for Spotlights). Type “ter”, and click “Enter” for “Terminal” in Spotlight on your Mac to open it.
Protect Zip Files in Mac
  • Make shure that your destination folder is correct: pwd + Enter
  • If you need to change your detination path use: cd /any_destination_you_need/ (in my case the destination is / Users/username/Desktop/).
  • While destination will be correct write the following command to protect your folder with a password: zip -er <archive_name> <target_folder>”.
Protect Zip Files in Mac
  • Subsequently, you will be able to see a pop up which will prompt you to enter a password twice. Enter your desired password, make sure it is strong and not easy to break. Use a combination of upper and lowercase alphabets and number.
Protect Zip Files in Mac
  • Once you have entered the password, press “Enter”.
  • You’ll be asked to verify the password you have just entered, so enter the same password again. Then press “Enter”. Now you are done adding a password to your zip files.
Protect Zip Files in Mac

How to open password protect a zip file Mac?

Once you have password protected your zip files on Mac. You must know how to open it when you need to or otherwise the data will be locked forever. This section explains how to unzip password protected zip file mac. Follow the simple steps below to open your zipped files and access them on Max OS X.

Read more: Zip File That Turns Into a CPGZ on MAC OS X. How to Open it

To open an encrypted file, simply double click on it. A pop up will appear on the screen asking you to enter your password, once you enter the password, the zip file will decompress and it will open. You can now access the folder.

Protect Zip Files in Mac

However, in another case, if you need to open it from Terminal.

Follow the steps bellow:

  • Open the Terminal on the Mac and search for it in Spotlight.
Protect Zip Files in Mac
  • Next, in Terminal enter “unzip -P password_you_add_before <your destination folder> (in my case the destination is /Users/username/Desktop/).
Protect Zip Files in Mac
  • Afterwards, press “Enter”
Protect Zip Files in Mac

So these were the steps how you can password protect your files from being accessed by the attackers and keep them safe at all files. Also, you can decompress them whenever you want to and open these files by just entering your password in a matter of seconds. From now onwards, never worry about your data being leaked out. Stay safe at all times, under all conditions.

It’s the best time to ask questions and give us your feedback in comments.


Hi there! My Name is Vincent Lago! My goal is to share insightful reviews, guides, and manuals for people looking to know more about current solutions for Apple hardware and OS. I have years of technological background knowledge including owning a custom iMacs & PCs which was using for different types of business. And now, I want to share my experience with you.


  1. thank you very much , these article helps me for hide my pictures on mac operating system .

  2. I’m glad there is a way to lock your zipped files. However, is there a way to lock complete folders? Like if I have secure content that I’d just like to lock together for easier access?

Reply To mark Cancel Reply