File can be compressed directly using Windows OS system, but capability to protect files with a Password was removed by Microsoft after Windows 7 (yes it was possible in Windows XP).

However now I would recommend to use 7zip for this purpose. 7zip is an OpenSource freeware which can be downloaded from 7zip.org.

7zipIconThis software is tiny in size (1MB) and can extract almost all compression formats (including rar and iso). It can compress files in two formats – zip and 7zip, where 7zip is considered to have highest compression ratio (better than zip and rar). 7zip comes with absolutely no Bloatware or Adware, so pretty safe to install even on servers.

Here are the steps to password protect your zip files with 7zip –

1) Once you install 7zip, it starts to appear in Context menu of Windows. Select the files you want to compress, and right click on it.

7zipMenu

2) From 7zip context menu > click ‘Add to archive…’ option.

3) This will open options dialog box. Here you can put password under ‘Encryption’ segment.

7zipSettings

7zip Archive Options Box

4) Make sure that you have selected zip format in ‘Archive Format’ combo box.

Click on ‘OK’ and you will have your password protexted zip file ready.

Now if you try extract this compressed file by using 7zip or by Windows Explorer, it will ask you to enter password first.

7zipAskPassword

7zip Password Box

WindowsExplorerPassword

Windows Explorer Password Box