Create Password Protected Zip Files on Mac

Create Password Protected Zip Files on Mac

If you have sensitive or confidential files that you want to protect from prying eyes, password-protecting them in a compressed ZIP file is a good solution. By adding a password to the compressed file, only those with the correct password can access the contents. In this tutorial, you will learn how to password-protect a ZIP file on a Mac using Terminal.

How to Create Password Protected Zip Files on Mac

By following the below given steps, you can create password protected zip file in mac;

  • Step 1: Open Terminal
  • Step 2: Navigate to the folder containing the files
  • Step 3: Compress the files into a ZIP file
  • Step 4: Set a password for the ZIP file
  • Step 5: Verify the ZIP file

Step 1: Open Terminal

Open the Terminal application by clicking on the Spotlight Search icon in the top right corner of your screen (magnifying glass) and typing “Terminal.” Click on the Terminal app icon that appears in the results.

Step 2: Navigate to the folder containing the files

Use the “cd” command to navigate to the folder containing the files you want to compress and password-protect. For example, if your files are in a folder on your desktop called “Sensitive Files,” you would type:

cd ~/Desktop/Sensitive\ Files/

Step 3: Compress the files into a ZIP file

Once you’re in the correct folder, use the following command to compress the files into a ZIP file:

zip -er archive.zip *

This will create a new ZIP file called “archive.zip” and compress all the files in the current folder. The “-e” option tells the “zip” command to encrypt the contents of the ZIP file, and the “-r” option tells it to include all files and subfolders within the current folder.

Step 4: Set a password for the ZIP file

After entering the command to compress the files, Terminal will prompt you to enter a password for the ZIP file. Type a strong password and press enter. You will be prompted to confirm the password by entering it again.

Note: The password you enter will not be visible as you type it. This is a security measure.

Step 5: Verify the ZIP file

Once the ZIP file has been created, you can verify that it’s password-protected by trying to open it. Double-click on the ZIP file to open it, and you should be prompted to enter the password you set earlier. If you enter the correct password, you will be able to access the contents of the ZIP file.

Conclusion

Congratulations! You’ve successfully password-protected a ZIP file on your Mac using Terminal. Remember to keep your password safe and secure, as losing it will make it impossible to access the contents of the ZIP file.

Recommended Tutorials

AuthorAdmin

My name is Devendra Dode. I am a full-stack developer, entrepreneur, and owner of Tutsmake.com. I like writing tutorials and tips that can help other developers. I share tutorials of PHP, Python, Javascript, JQuery, Laravel, Livewire, Codeigniter, Node JS, Express JS, Vue JS, Angular JS, React Js, MySQL, MongoDB, REST APIs, Windows, Xampp, Linux, Ubuntu, Amazon AWS, Composer, SEO, WordPress, SSL and Bootstrap from a starting stage. As well as demo example.

Leave a Reply

Your email address will not be published. Required fields are marked *