Two Easy Practical Ways To Protect Your Files & Folder On macOS

how to Secure your data on Mac
For macOS or Hackintosh users, there may be some users still feel confused with the problem of protection of files or folders that are inside their computer.
Not without reason, maybe some users have some files that are private and do not want to be accessed by anyone other than himself.

Therefore, here I will explain two easy ways to protect the file or maybe a folder that contains important data so that can not be accessed by other parties. Namely by hiding files or folders, and the second way is to provide a password on the data or folders that we will protect.
With this method I will discuss, we do not need any third party applications. So we can save wallet expenses just to buy software that can answer those needs.

For the first method, we can hide the files or folders that we want to hide through the Terminal app.
In this step, there are two commands that we can choose one. Here's the explanation.

Hiding File or Folder on macOS

First Command Line:
First, open the Terminal application via the Application >> Utilities folder.
When the Terminal is open, you need to prepare the first file or folder you want to hide, where it is located and access using Finder.
After the Finder has been opened and you navigate to where the file or folder you will hide.
Then type below command:
mv your_folder_or_file_path/ .your_new_folder_or_file_name/

Do not forget to put a dot in front of the file name or folder you just created.
After that, press Enter or Return key on your keyboard to confirm the change, after that the files or folders that you rename with the new name will not appear. But do not worry ... actually the file or folder you have hidden by macOS system.

Second Command Line:
For the second command line, the process is the same. But there is a difference on the command line. The following command line you need to write on the Terminal screen.
chflags hidden your_folder_or_file_path/

To unhide your file or folder back, write below command:
chflags nohidden your_folder_or_file_path/

After we successfully hide the file or folder, of course, we are confused to access it.
Then to bring up the file or folder, we simply write the command line below on the Terminal screen. And press the Enter or Return key on the keyboard on each command line you write:
defaults write AppleShowAllFiles TRUE
killall Finder

After that, the file you hide will reappear. And to hide again, you just write command line like below:
defaults write AppleShowAllFiles FALSE

If we look, we just need to change TRUE to FALSE. then restart the Finder by writing command line below then press Enter or Return key:
killall Finder

The above is a way to hide a file or folder. Of course, there are weaknesses, because, for anyone who can bring up the hidden files, it will be able to see the data we have hidden.
And if you want more secure, using the second method, namely by providing passwords on the data that we will protect. Follow the steps below.

Give The Password to The macOS File or Folder:

To provide passwords on files or folders of your data on macOS computers, applications you need to use only with Disk Utility.

But after we provide the password on your data, the resulting encryption of Disk Utility is not in the form of a folder or file as it originated. But the file will be changed to a file with the .dmg extension. To open it, need to enter the password in accordance with the password that we set at the beginning of its manufacture. After that, the file will be mounted and you can access through Finder.

The steps are as follows:
Open Disk Utility apps from quick launch or manually open it from Application folder then open Utilities folder, and click on Disk Utility.

Once open, click the New Image menu >> Image from Folder... (you can also choose the option Blank Image, but here I just choose the second option).

After that you will be faced with the look like the picture below, then choose the folder that contains your personal data that you want to give the password. select the folder and then click the Open button.
how to give password protection on folder
And then you will be given a choice like the picture below:
imachak-how to give password protection on folder
in Save as a field, give with a new name, and at Encryption, click the little triangle to select an option, then select 128-bit AES encryption (recommended). then you will be prompted to enter the password protection. And type the password in the field already provided. see the photo example below:

Two Easy Practical Ways To Protect Your Files & Folder On macOS
After completing the password on two fields that have been provided, then click the Choose button, then press the Save button. And wait for the compression process to complete.
imachak-file and folder pasword protection with disk utility on macos

imachak-file and folder pasword protection with disk utility on macos-2
Then you will see a new file with the .dmg extension, and that's the result of your personal data encryption that you've been working on. Then next you can delete the original folder.
And to access the files you have encrypted, you simply to double-click the dmg file, and you are required to enter a password that you have configured in the manufacturing process earlier.
If the password is written correctly, then the MacOS will mounting data and you can access it using the Finder.

Well, pretty easy is not it ?! And in this way, you do not need additional costs to buy applications that have these functions.
And you can choose one of the two methods as I have explained above.

If you feel the hassle of following the article above, you can see the guide on the video below:

Such is the step by step the process of hiding or giving passwords on your personal data to avoid other people's access on MacOS or Hackintosh computers. Hopefully, this guide is useful for those of you who do not know it yet.

Warm greetings and good luck is always for you. See you later in another article.

Subscribe to receive free email updates: