Tech News Today
  • Hardware
    • Motherboards
    • CPUs
    • Graphic Cards
    • RAM
    • SSDs
    • Computer Cases
    • Monitors
    • Peripherals
    • Power Supply Unit
    • PC Builds
    • Computer Tips
  • Software
  • Operating System
    • Windows
    • Mac
    • Linux
  • Gaming
  • Mobile
  • Console
  • More
    • Internet
    • Networking
    • Security
    • Buyer’s Guide
    • Gadgets
    • Laptops
    • Reviews
    • How To
    • News
Facebook Twitter Instagram
Tech News Today
  • Hardware
    • Motherboards
    • CPUs
    • Graphic Cards
    • RAM
    • SSDs
    • Computer Cases
    • Monitors
    • Peripherals
    • Power Supply Unit
    • PC Builds
    • Computer Tips
  • Software
  • Operating System
    • Windows
    • Mac
    • Linux
  • Gaming
  • Mobile
  • Console
  • More
    • Internet
    • Networking
    • Security
    • Buyer’s Guide
    • Gadgets
    • Laptops
    • Reviews
    • How To
    • News
Tech News Today
Home»How To»How To Password Protect A Zip File – Step By Step Guide

How To Password Protect A Zip File – Step By Step Guide

SandeepBy SandeepSeptember 15, 2021
How To Password Protect A Zip File

Zip files are popular means of storing and sharing files. Personal files are always at the risk of unauthorized access. A password-protected zip file protects your files from prying eyes.

Zip files aren’t the ultimate solution for optimal file security. But password protection is the first line of defense when hackers get their hands on your file. It’s like someone finding a treasure chest but not being able to open it without the proper key.

Table of Contents

  • How To Password Protect A Zip File
    • Password Protect A Zip File in Windows
      • Built-in Windows Encryption
      • Third-party Apps
    • Password Protect A Zip File in Linux/MacOS
    • Password Protect A Zip File in MacOS
      • Using Command Line
      • Using WinZip
      • Using Keka
  • Frequently Asked Questions
    • How to Open a Password-protected Zip File?
    • How Safe is a Password-protected Zip File?
    • How Can I Protect My Files From Hackers?

How To Password Protect A Zip File

Password protecting a zip file depends on the use case that you’re seeking. Whether somebody else has to access the file or it is only you. It also depends on whether you want to install a third-party app or not. Read along to find out how you can password protect a zip file.

Password Protect A Zip File in Windows

Built-in Windows Encryption

This approach works on Enterprise, Education, and Pro versions of Windows. It is not available in the Home version. The good thing about this approach is that you don’t need to involve any third-party apps.

  1. Navigate to the file/folder and right-click on it.
  2. Select Send to and select Compressed(Zipped folder). zipping-in-windows
  3. You should see a zip file created along with the file/folder.
  4. Right-click on the zip file and select Properties. file-properties
  5. Under the General tab, select Advanced.windows10-file-properties
  6. Under the Compress or Encrypt attributes, check Encrypt contents to secure data. This enables encryption. encrypt-zip-windows
  7. Press OK and select Apply.
  8. On the Encryption Warning window, select the recommended “Encrypt file and parent folder”.encrypt-zip-windows-parent
  9. Click on OK.
  10. Select OK to close the Properties window.

Once you encrypt the zip file, it is accessible only if you logged in from the same user who encrypted it. This is why you will see no change when attempting to open the zip file. But, if you log in to your PC using a different user, the file is inaccessible.

One key thing to note here is using this method of password protection secures the file for a single user. It means you cannot share it with anyone else. 

This is because the file won’t open on anybody else’s Windows PC. It won’t open on your PC either if you log in under a different username.

Thus this file is now tied into your user account. If you lose access to it, you won’t be able to recover your zip file.

Third-party Apps

Third-party apps are only tied to the passwords they create during compression. Even if you lose access to the user account, you can still recover zip file contents. This also means that if the password is leaked, anyone can open the zip file’s contents. They don’t even need to open the zip file on your PC.

7Zip 
  1. Right-click the file that you want to protect.
  2. Under 7Zip, Select Add to Archive.7zipping
  3. Make sure the Archive format is set to zip.7zipping2
  4. Under encryption, enter the password twice on the displayed fields.7zip-encryption
  5. Select WinCrypto or AES and select OK.7zip-encryption
  6. There are pros and cons to using both AES and ZipCrypto.
    • With AES,
      • You can open zip files only using 7ZIP, WinZip, and a few other ZIP archivers.
      • AES-256 provides stronger encryption.
    • With ZipCrypto,
      • You can open zip files without any third-party applications in Windows.
      • Compatible with all the ZIP compressing software.
WinZip
  1. Right-click the file that you want to protect.
  2. Under WinZip, select Add/Move to Zip file. winzipping
  3. Type a name for the compressed file.
  4. Under encryption, check Encrypt files. winzip-encryption
  5. Click on the arrow next to Encrypt files.winzip-encryption-options
  6. Select 256 bit AES or Legacy(ZipCrypto) and click OK. Refer to the section above on the pros and cons of both tools.winzip-encryption-methods
  7. Click Add.
  8. Enter a password twice for verification and select OK.winzip-encryption-password

Password Protect A Zip File in Linux/MacOS

  1. Open terminal.
  2. Install zip and unzip application packages.
    • For Ubuntu-based and Debian based 
      • sudo apt install zip unzip -y
    • For RedHat/Fedora/CentOS
      • sudo dnf install zip unzip
    • For Arch Linux
      • sudo pacman -S zip unzip
    • The above commands are for Linux only. macOS ships with these packages by default.
  3. zip -er target_file.zip personal_files
    1. Replace target_file with target compressed filename and personal_files with source folder or file.linux-zipping
  4. Enter password and press Enter. Re-enter for confirmation.

Note that the password mentioned in Step 4 is not the same as the root or sudo password for your Linux/Mac OS. It is only a password that you can use to unload the zip file.

After the command completes, the file is now password protected. You should be able to find it in the current working directory.

In case you want to Extract and Install Tar.gz files, we have you covered.

Password Protect A Zip File in MacOS

Using Command Line

For this approach, see the above section on using the zip application package.

Using WinZip

  1. Download WinZip and install it.
  2. Once installed, open WinZip from Applications.
  3. Using Finder, drag and drop the file(s) and folder that needs to be zipped.
  4. On the right action pane, check Encrypt.Mac-winzip
  5. Select Encryption preferences.Mac-winzip-encryption
  6. Under the Encryption method, choose between 256 bit AES or legacy. Refer above section on the pros and cons of both.Mac-winzip-encryption-method
  7. From the top pane, click Add and select from this Mac.Mac-winzip-encryption-2
  8. Enter a password twice for confirmation.Mac-winzip-encryption-password
  9. Go to the required location.
  10. Select Zip.

Using Keka

  1. Download Keka and install it.
  2. Or search and download Keka from the Mac App Store.
  3. Once installed, open Keka from Applications.
  4. Make sure you have selected ZIP as shown.mac-keka
  5. Choose the compression method or leave it at default.
  6. Retype password twice for confirmation.mac-keka-password
  7. Check AES 256 or leave it at default for ZipCrypt.
  8. Using finder, drag and drop file(s) and folders that you want to compress.mac-keka-password-drop
  9. Enter compressed filename and location.
  10. Select Compress.

Frequently Asked Questions

How to Open a Password-protected Zip File?

To open a zip file, you can either use the graphical method or the command line method. Both methods require you to enter your password for decompression.

Graphical method

You need to have a compression application to open password-protected zip files. You can also use Windows if you don’t have a third-party application.

  • Navigate to the zip file location.
  • Double click on it to open it.
  • You can now view the contents of a zip file without having to enter the password.
  • To open a file or extract from it, select extract or double click on it.7zip-extract
  • Enter the correct password.7zip-extract-password

Command-line method

Both Linux and macOS support this method. You need to have file permissions to access the zip file.

  1. cd Downloads
    • To go to the zip file in the Downloads folder.
  2. unzip compressed_file.zip
    • Enter password and press Enter. linux-unzipp
  3. Files are now available at the current location with the same folder name.

How Safe is a Password-protected Zip File?

A password-protected zip file uses the best encryption technology available. This type of protection is generally safe against most hackers. Also, AES-256 is safer than ZipCrypto at the sacrifice of compatibility. That being said, zip files aren’t a 100 percent method of securing file contents.

  • You can still delete the password-protected content of a zip file.
  • You can still add insecure and malicious code to the content of a zip file.
  • You can delete and replace the secure content without entering a password.

Thus, password protection can only go so far as to prevent file contents from direct eyes. It cannot prevent unauthorized modification and deletion.

How Can I Protect My Files From Hackers?

There are many ways of protecting yourself from hackers. For adequate security, use a combination of more than one method from below.

  • Use a firewall in home and office networks.
  • Install antivirus software and update with the latest definitions.
  • Use complex passwords and change them every month.
  • Use spam filters and don’t click on spam email links.
  • Back up personal files at regular intervals.
  • Use two-factor authentication for security.
  • Use encryption on all drives. Use BitLocker on Windows and FileVault on Mac.
  • Update your operating system whenever possible.
  • Use secured HTTP only whenever possible.
  • Have stronger Wi-Fi passwords and install mac filters in routers.
  • Never share passwords and PC with anyone else.
  • Never connect to public free Wi-Fi hotspots.
  • Windows
    Sandeep

    Tech enthusiast. Windows. Linux. Security. Networking.

    Related Posts

    facetime-call-history

    How to Check FaceTime Call History

    January 2, 2023
    iphone-touch-screen-not-working

    iPhone Touchscreen Not Working? Try These 6 Fixes

    December 27, 2022
    partial screenshot windows

    How to Take a Partial Screenshot on Windows?

    December 12, 2022
    how to copy text from a picture

    How to Copy Text from a Picture

    December 8, 2022
    Change the orientation 1

    How To Change Screen Orientation on Windows

    December 7, 2022
    how-to-open-cfg-file

    How to Open CFG File in Windows and macOS

    December 4, 2022
    Add A Comment

    Leave A Reply Cancel Reply

    Latest Posts
    firmware vs software

    Firmware Vs Software – What’s the Difference?

    March 8, 2023
    keyboard sizes

    All the Types of Keyboard Sizes Explained

    March 8, 2023
    Memory-Compression

    What is Memory Compression in Windows? Should You Enable or Disable It

    March 1, 2023
    You may also like
    keyboard is double typing

    Keyboard is Double Typing? Here’re 6 Ways to Fix it

    March 9, 2023
    enlarge-hp-printer

    How to Enlarge Copy on HP Printer

    March 9, 2023
    reset msi bios

    How to Reset MSI BIOS

    March 9, 2023
    Recommended
    Cookie Clicker Garden Guide

    Cookie Clicker Garden Guide to Unlocking Every Seed

    September 26, 2021
    monitor no signal

    Computer Turns On But Monitor Says No Signal (9 Ways To Fix)

    November 10, 2022
    Facebook Twitter Pinterest
    • Home
    • About Us
    • Our Team
    • Editorial Guidelines
    • Privacy Policy
    • Affiliate Disclosure
    © 2023 TechNewsToday, editor@technewstoday.com | Tech Central Pvt. Ltd.

    Type above and press Enter to search. Press Esc to cancel.