How to Password Protect Files and Folders in macOS in 2022

How to Password Protect Files and Folders in macOS

Want to protect your files and folders with a password on Mac? Check out How to Password Protect Files and Folders in macOS in this guide.

Knowing how to password guard a folder on a Mac will surely come in handy. It means you can keep sensitive information such as your financial information or a secret work project without the danger of it being accessed by anyone who does not have a password.

Standard security features like this help to make Macs some of the best laptops and computers available, and you can do it without installing any additional software simply using the Mac’s Disk Utility tool.

It does not password secure the folder itself but instead creates a separate folder disc image with the same effect. You can open the disc image folder and move files in and out as usual.

It’s also possible to share the folder disc image with others, and if you provide them with the password, they’ll be able to access the folder’s files as well.

Here’s How to Password Protect Files and Folders in macOS. You can protect your files and folders with a password using the following tools,

  • Disk Utility
  • Open a Password Protected Folder on Mac
  • Encrypto
  • F-Vault
  • Terminal and compression
  • Terminal and OpenSSL

If you don’t know how to use the above tools, then continue reading for a step-by-step explanation of the tools.

Related: How to Manage iCloud Keychain Passwords

How to Password Protect Files and Folders in macOS

Use Disk Utility to Password Protect Folders on Mac

An encrypted disc image can be used to password protect a folder. This will generate a new DMG file that will require you to provide a password to open it. Furthermore, because the original folder is included in the package, you can delete it after encryption.

How to Password Protect Files and Folders in macOS
  • Launch Disk Utility from Spotlight.
Password Protect Files and Folders in macOS
  • Once it’s open, go to the menu bar and select “File -> New Image -> New Image from Folder… “
  • Choose the password-protected folder and either encryption option from the drop-down menu.
Protect Files and Folders in macOS
  • The 256-bit option is more secure, but it takes longer to encrypt and decrypt your data; however, both formats safeguard your data sufficiently, so 128-bit AES is sufficient here.
Password Protect Files and Folders
  • When prompted, enter a password. This is the password you’ll need to input in order to unlock the disc image. It should be strong and different from your Mac password.
See also  How To Ctrl + Alt + Del On Mac? | 2022 Guide
How to Password Protect Files and Folders in mac
  • Select “read/write” from the “Picture Format” menu to allow you to add files to the image; otherwise, you won’t be able to add or remove them.
  • To build the encrypted disc image, click “Save.” When Disk Utility has finished building the disc image from your folder, it will display a success message.
  • Unless you choose a different save location in the preceding stages, the disc image will display next to the folder you choose.

This DMG file is not the same as your folder; it is a disc image containing a copy of the folder’s contents. The password is required to mount and decrypt the DMG. The original folder exists on its own.

Open a Password Protected Folder on Mac

Of course, after a folder has been password locked, you must know how to access and use it.

  • To open the disc image folder, double-click it (it will have the suffix .dmg).
  • Enter the password you used to create the disc image.
  • Don’t check “Remember password” in my keychain because doing so will render having a password useless (unless you want to share the folder with someone else).
  • Once the disc image has been mounted, double-click it. You may then drag and drop files into and out of it.
  • Close the mounted disc image after you’re finished. Eject the disc image by right-clicking it.

When you’re certain that everything is working properly, delete the unencrypted folder.


  • This disc image will have about the same capacity as the original folder. You are free to delete old content and replace it with new content.
  • This.dmg file should not be deleted. Everything will be gone if you do.
  • To permanently delete the locked folder (and its contents), launch Disk Utility, select the disc image from the left sidebar, right-click it, and select ‘Delete APFS Volume.’

Password Protect Files and Folders Using Encrypto

Encrypto is a third-party encryption utility that can be downloaded from the Mac App Store. It provides an improved User Experience (UX) for encrypting and decrypting files with a drag-and-drop interface.

Password Protect Files and Folders using Encrypto
  • To begin, download and install Encrypto from the Mac App Store.
  • When you’re finished, launch Encrypto from Spotlight or the Applications folder.
  • Drag the folder you want to encrypt onto the Encrypto app window to begin.
  • Enter the password you’d want to use to secure the folder. If you’re worried about forgetting your password credentials, you can provide an optional clue.
  • When you’re finished, click “Encrypt” to start creating your archive.
  • When the encryption is finished, move the archive to a safe location. You may also use the “Share File” and “Save As…” options to transport the Encrypto archive to another location.
  • Double-click the archive to open it, then enter your password and click “Decrypt” to unlock the folder.

Password Protect Files and Folders Using F-Vault

You can easily password secure a PDF or document on Mac, and you can also encrypt your starting disc with FileVault. However, there is no option to add a password to the folder. Fortunately, third-party folder encryption applications such as F-Vault are available. F-Vault is an excellent application for password-protecting folders and files on your Mac.

  • To start with, download F-Vault through the Mac App Store.
  • Set a password the first time you open it. If you need to recover your password, enter your email address.
  • You’ll notice a vault folder called Default. You can also make your own vault folders.
  • Drag the Mac folder to be protected into the Vault or a vault folder.
  • When prompted to delete the original files, select Delete. You can also do it manually later.
See also  How to Cancel or Delete all Alarms on iPhone or iPad in 2022

The folder and its contents are in an encrypted vault that no one can access without the correct password. Furthermore, whether you search for the folder (or a file within it) in Spotlight or Finder, it does not display in the search results.

Launch F-Vault, enter the password, and then click OK to gain access to the folder and its contents. It’s really that simple. Quit F-Vault to make them unreachable again.

If you no longer want to keep a folder private, you can remove password protection by dragging it from the vault to a preferred location, such as the Desktop.

Use Terminal and compression to Password Protect Files and Folders

The solution described above involves putting the folder you want to secure in an encrypted vault. If you need to encrypt a folder but don’t want to use Disk Utility, you can use Terminal, macOS‘s free terminal emulator. You can use Terminal to convert a folder into a password-protected ZIP archive file.

Simply use this way to password protect a folder to send in an email.

  • Start up Terminal on your Mac. Use Spotlight or navigate to Finder > Applications > Utilities.
  • Assume you need to password secure the Documents folder “Sample Folder” In Finder, control-click “Sample Folder” and select Get Info.
  • Back to the Terminal. Paste the path after typing cd and a space. “Return” should be pressed.
  • Enter ls and press Return.
  • Use the command zip -er SampleFolderProtected “Sample Folder”.
  • “Sample Folder” is compressed. The ZIP file is named “SampleFolderProtected” in this case. “Return“ should be pressed.
  • It will now prompt you to enter a password. Enter a password and press the “Return” key. 
  • Go to your Mac’s Documents folder and look for a ZIP archive file called
  • When you double-click the archive, the Archive Utility dialogue box appears, prompting you to enter the password.

Use Terminal and OpenSSL to Password Protect Files and Folders

This is a way that can be performed on a Mac without the use of third-party software. It uses a built-in Mac feature to safeguard your files and directories. If you want to place new files on a specific encrypted folder on Mac, you must use this tool. Check out the instructions below to learn how to do it:

  • The first step should be to launch Terminal.
  • Enter the following command. “openssl aes-256-cbc -in /Desktop/SamplePhoto.jpg -out /Desktop/Encrypted.file” without the quotes and the end period. Make sure the portion labelled /Desktop/SamplePhoto.jpg is changed with the file you want to encrypt, including its location. The part named jpg -out /Desktop/Encrypted.file, on the other hand, will tell you where the real encrypted file will be saved.
  • Enter the command and the password. After that, enter the command and, when requested, input the password for encryption. To proceed to the next step, you must confirm the actual password.
  • Make use of the Encrypted File. You will now be able to see its Encrypted.file on your Desktop. It is dependent on your personal requirements and preferences. You can, however, configure the directory and its encryption techniques.
See also  Desktop icons are Missing or Disappeared on Mac | How to Fix in 2023

Now you know how to password lock a folder on your Mac without using Disk Utility. In this case, we used the Terminal and its built-in OpenSSL tool.

How to Password Protect Files and Folders in macOS – Conclusion

The Disk Utility approach for password protecting a folder on a Mac works, although it’s a little clumsy. The Encrypto software is simpler to use, but it generates a proprietary archive format that may be insecure in the future.

As a result, you should select your solution based on your requirements and security concerns. Hide files and directories instead of low-level protection is sufficient.

We hope this guide offered all the answers you needed for How to Password Protect Files and Folders in macOS. Let us know which method you prefer the most in the comments below.

Also Read: