HomeWinBuzzer TipsHow to Add or Remove a Password from Excel Workbooks, Worksheets and...

How to Add or Remove a Password from Excel Workbooks, Worksheets and Cells

We explain the different types of password protection in Excel, how they work, and how secure they are.

-

One of the features that Excel offers is password protection, which can help users to protect their sensitive or confidential information from unauthorized access or modification. However, not all password protection options in Excel are equally secure, and some of them can be easily bypassed or cracked by hackers or malicious software. In this blog post, we will explore the different types of password protection in Excel, how they work, and how secure they are.

There are three main types of password protection in Excel:

  • Excel Workbook password: This option allows users to set a password for opening or modifying the entire workbook file.  Users will then be prompted to enter and confirm a password of their choice. Once a workbook password is set, anyone who tries to open or modify the workbook file will need to enter the correct password first.
  • Excel Worksheet password: This option allows users to set a password for protecting specific worksheets within a workbook from being viewed, edited or deleted. To set a worksheet password, users need to right-click on the worksheet tab and select Protect Sheet. Users will then be prompted to enter and confirm a password of their choice, and select the actions that they want to allow or disallow on the protected worksheet. Once a worksheet password is set, anyone who tries to view, edit or delete the protected worksheet will need to enter the correct password first.
  • Excel Cell password: This option allows users to set a password for locking specific cells or ranges of cells within a worksheet from being edited or formatted. To set a cell password, users need to select the cells or ranges of cells that they want to lock. Then, users need to protect the entire worksheet by following the steps for setting a worksheet password. Once a cell password is set, anyone who tries to edit or format the locked cells will need to enter the correct password first.

While these password protection options can provide some level of security for Excel files, they are not foolproof and can be easily broken by various methods. Some of the common ways that hackers or malicious software can bypass or crack Excel passwords are:

  • Brute force attack: This method involves trying every possible combination of characters until the correct password is found. This can take a long time depending on the length and complexity of the password, but it is guaranteed to work eventually.
  • Dictionary attack: This method involves trying a list of common or likely passwords based on words, phrases or patterns that users may use. This can be faster than brute force attack if the password is simple or predictable, but it may not work if the password is random or obscure.
  • Password recovery software: This method involves using specialized software tools that can exploit vulnerabilities in Excel’s encryption algorithm or file format to recover or remove passwords from Excel files. This can be very fast and effective, but it may require some technical skills or knowledge.

Therefore, users who want to protect their Excel files from unauthorized access or modification should not rely solely on password protection options in Excel, but also use other security measures such as:

  • Choosing strong and unique passwords that are long, complex and random, and changing them regularly.
  • Storing passwords securely in encrypted vaults or managers, and not writing them down or sharing them with anyone.
  • Encrypting Excel files with third-party software or services that use stronger encryption methods than Excel’s built-in ones.
  • Backing up Excel files regularly and keeping them in safe locations such as cloud storage or external drives.
  • Scanning Excel files for viruses or malware before opening or downloading them from unknown sources.

Password protection in Excel can be useful for preventing accidental or casual access or modification of Excel files, but it is not enough for ensuring high-level security of sensitive or confidential information. Users should be aware of the limitations and risks of using password protection in Excel, and take additional precautions to safeguard their data from potential threats.

How to Protect an Excel Worksheet/Workbook With a Password

The following steps show how to protect an Excel workbook which is the whole Excel file with all its contents.

  1. Click “File” on the top left
     
    Windows 11 - Excel - File
  2. Switch to “Info” and click “Protect Workbook” – ” “Encrypt with Password”
     
    Windows 11 - Excel - File - Info - Protect Workbook - Encrypt with Pass
  3. In the pop-up “Encrypt Document”, enter your password and click “OK”
     
    A good password to protect your Excel workbook should have at least 8 characters, and include a mix of uppercase and lowercase letters, numbers, and symbols. A good password should not be based on personal information, common words, or sequential patterns. A good password should be changed regularly, and not reused for different accounts.
     
    Windows 11 - Excel - File - Info - Protect Workbook - Encrypt with Pass - Accept
  4. Reenter the password an click “OK”
     
    Windows 11 - Excel - File - Info - Protect Workbook - Encrypt with Pass - Reenter Pass - Accept
  5. Your workbook in Excel is now encrypted and password protected
     
    Windows 11 - Excel - File - Info - Protect Workbook - Result

How to Remove a Password From an Excel Worksheet/Workbook

The following steps show how to unprotect an Excel workbook which is the whole Excel file with all its contents.

  1. When you open a password-protected Excel file, you will have to unlock the workbook first
     
    Windows 11 - Excel - Password
  2. Then click “File” to open the options menu
     
    Windows 11 - Excel - File
  3. Select “Info” and click “Protect Workbook” – “Encrypt with Password”
     
    Windows 11 - Excel - File - Info - Protect Workbook - Encrypt with Password
  4. Remove the existing Password and click “OK”
     
    Windows 11 - Excel - File - Info - Protect Workbook - Encrypt with Password - Delete Password - Accept
  5. Your Excel workbook is now unprotected and can be used without a password
     
    Windows 11 - Excel - File - Info - Protect Workbook - Encrypt with Password - Delete Password - Result

How to Lock a Sheet in Excel Using a Password

Use the following step for locking an Excel spreadsheet / a single Excel worksheet inside an Excel Workbook).

  1. Right-click the tab for your Excel sheet which you want to assign a password for
     
    Windows 11 - Excel - Protect Sheet
  2. Enter a password, select “Protect worksheet and content of locked cells” and what you want the password to apply for

    When you protect a sheet in Excel, you have several options to customize the level of access that users have. Two of these options are “Select locked cells” and “Select unlocked cells”. Here’s what they mean:

    • Select locked cells: If this option is checked, users can select (click on) locked cells, but they can’t edit them unless they have the password to unprotect the sheet. If this option is unchecked, users can’t even select locked cells.

    • Select unlocked cells: If this option is checked, users can select and edit unlocked cells, even if the sheet is protected. If this option is unchecked, users can’t select or edit unlocked cells.

    The difference between these options is about what users can select and potentially edit:

    • If you only check “Select locked cells“, users can select locked cells but can’t edit them, and they can’t select or edit unlocked cells.
    • If you only check “Select unlocked cells“, users can’t select or edit locked cells, but they can select and edit unlocked cells.
    • If you check both options, users can select both locked and unlocked cells, but they can only edit unlocked cells.
    • If you uncheck both options, users can’t select or edit any cells on the sheet.
       

    Remember, these options only take effect when the sheet is protected. If the sheet is not protected, users can select and edit all cells, regardless of these settings.
     
    Windows 11 - Excel - Protect Sheet - Password - Allow - Accept

  3. Confirm the password and click “OK” to secure the Excel sheet
     
    Windows 11 - Excel - Protect Sheet - Password - Allow - Reenter Password - Accept

How to Unlock an Excel Sheet Removing a Password

Use the following steps to unprotect Excel sheets (single spreadsheet inside of an Excel Workbook).

  1. Right-click the tab of the Excel sheet and select “Unprotect Sheet”
     
    Excel - Sheet - Unprotect Sheet
  2. Enter the password and click “OK” to unprotect the Excel sheet
     
    Excel - Sheet - Unprotect Sheet - Enter Password

How to Lock or Unlock Specific Cells in an Excel Worksheet/Workbook

This feature allows you to lock specific cells in a worksheet. When a cell is locked, it cannot be edited. However, cell locking only takes effect when the worksheet is protected. This means you can lock cells in a worksheet, but if the worksheet is not protected, users can still edit those cells.

When you use a worksheet password in combination with cell locking, you’re adding an extra layer of protection. You can lock certain cells that contain important data or formulas that you don’t want to be changed, and then protect the entire worksheet with a password. This way, even if someone knows the password and can make changes to the worksheet, they still cannot edit the locked cells.

  1. Select the cell(s) you want to lock and click “Format” in the “Home”-Ribbon
     
    Excel - Select Cells - Format
  2. Click “Format Cells”
     
    Excel - Select Cells - Format Cells
  3. Switch to “Protection” and select or unselect “Locked”
     

How to Encrypt an Excel File Using Encrypting File System (EFS)

When you choose to encrypt an Excel file with EFS as shown in our other guide, Windows will generate a unique encryption key for that file. This key is used to convert the data in the file into a format that can’t be understood without the key. This process is transparent to you as a user – you don’t need to manually encrypt or decrypt the file.

When you, as the owner of the file, try to access it, Windows will automatically use your encryption key to decrypt the file and allow you to view and edit it as normal. This decryption process is also transparent – you don’t need to manually decrypt the file.

If someone else tries to access the file – for example, if they gain unauthorized access to your computer or if they steal your hard drive – they won’t be able to read the file. Without your unique encryption key, the data in the file will appear as gibberish.

If you want to share the file with someone else, you’ll need to decrypt it first, or the recipient will need to have an encryption certificate that matches the one used to encrypt the file. If the recipient doesn’t have the appropriate certificate, they won’t be able to read the file.

FAQ – Frequently Asked Questions About Excel Password Protection

Can I recover a forgotten password for an Excel file?

Unfortunately, Excel does not provide a direct method for recovering forgotten passwords, which emphasizes the importance of keeping a secure record of your passwords. If you forget a password, third-party password recovery tools are available, but their effectiveness varies, and they often employ methods like brute-force or dictionary attacks, which might not always be successful, especially with strong passwords. Additionally, using such tools can pose security risks and might violate privacy policies. It’s advisable to maintain backups of important data and consider using a password manager to securely store your passwords.

How can I share a password-protected Excel file securely with others?

When sharing a password-protected Excel file, it’s crucial to transmit the password through a secure, separate channel from the file itself. Options include encrypted messaging apps, secure email services with end-to-end encryption, or a phone call. For an additional layer of security, consider using a one-time password or a secure file-sharing service that offers password protection and encryption for files during transit and at rest. This approach minimizes the risk of interception and unauthorized access.

Is it possible to set expiration dates for passwords in Excel, so they need to be changed periodically?

Excel does not support automatic expiration for passwords, so it’s up to users to manually update their passwords at regular intervals to enhance security. Establishing a routine for changing passwords can help, such as setting calendar reminders. For organizations, implementing policies that require regular password updates can be effective. Using a password manager can facilitate managing and updating passwords by storing them securely and reminding you when it’s time to change them.

Can I specify different editing permissions for different users within the same protected Excel sheet?

Excel’s standard features do not allow for setting user-specific permissions within a protected sheet. However, you can approximate this functionality by creating separate sheets for each user’s needs or utilizing the Shared Workbook feature, which allows multiple users to make changes simultaneously while tracking each user’s modifications. For more granular control, consider using Excel services on SharePoint or Microsoft 365, which offer advanced permissions settings and collaboration features.

How can I protect my Excel file if I need to send it via email?

In addition to applying Excel’s password protection, consider encrypting the email itself or using a secure file transfer service that provides end-to-end encryption. For file-level protection, tools like WinRAR or 7-Zip can encrypt the file with a password before sending. It’s also wise to use digital signatures when possible to ensure the integrity and authenticity of the document. Inform the recipient of the password through a separate, secure communication channel.

What’s the best practice for creating a strong password for Excel files?

A strong password is crucial for protecting sensitive information in Excel files. It should be at least 12 characters long and include a mix of uppercase and lowercase letters, numbers, and symbols to increase complexity. Avoid using personal information, common words, or simple sequences. Consider using a passphrase, which is a sequence of words or a sentence that is easy to remember but hard to guess. Regularly updating your passwords and using a unique password for each file enhances security further. A password manager can assist in generating and storing complex passwords securely.

How do I handle password protection for Excel files containing macros?

To secure Excel macros, apply a password to the VBA (Visual Basic for Applications) project. This is done within the VBA editor by accessing the project properties and setting a password under the Protection tab. This password restricts access to the macro code, preventing unauthorized viewing or modifications. It’s important to use a strong, unique password for the VBA project, different from the one used for worksheet or workbook protection, to ensure layered security. Remember to keep a backup of your VBA code and the password in a secure location.

Can Excel passwords be bypassed using macros or VBA scripts?

While certain low-complexity passwords might be vulnerable to bypass methods using VBA scripts or macros, especially in older versions of Excel, it’s crucial to use strong, complex passwords to mitigate this risk. Keeping your Excel and Office suite updated ensures you have the latest security patches. Be cautious when using or enabling macros, especially from unknown sources, as they can pose security risks. Implementing additional security measures, such as file-level encryption, can provide an extra layer of protection.

Is there a way to audit who has accessed or attempted to access a protected Excel file?

Excel itself does not provide built-in access or audit logs for protected files. For auditing purposes, consider using a document management system or a secure, cloud-based file-sharing platform that offers detailed access logs and audit trails. These systems can track who accessed a file, when, and what actions they took, providing valuable insights for security and compliance. Ensure that any system you use complies with your organization’s security policies and data protection regulations.

How do I ensure backward compatibility when setting passwords in Excel, considering different versions of Excel?

When setting passwords in Excel, it’s generally expected that they will be backward compatible with earlier versions. However, some newer encryption algorithms introduced in recent versions may not be supported by much older Excel versions. If backward compatibility is a concern, test the protected file in the older version of Excel to ensure accessibility. For critical compatibility, consider using a lower level of encryption that is supported across all required versions, but be aware this may reduce security.

Can I use Excel’s password protection in combination with other encryption methods for enhanced security?

Combining Excel’s password protection with additional encryption methods can significantly enhance the security of your Excel files. This can include using Windows’ Encrypting File System (EFS) to encrypt the file at the operating system level or employing third-party encryption tools that offer advanced encryption standards (AES) and other robust encryption algorithms. When using multiple layers of encryption, manage your passwords carefully to ensure that they are strong and securely stored, preferably in a reputable password manager.

What should I do if the password protection feature in Excel is not working as expected?

If you encounter issues with Excel’s password protection, first ensure that your Office suite is up to date, as updates often include fixes for known issues. If problems persist, try repairing your Office installation through the Control Panel or Settings app. For further troubleshooting, consult Microsoft Support or seek assistance from IT professionals. Documenting the issue, including any error messages and steps taken, can aid in resolving the problem more efficiently.

How can I protect sensitive data in Excel when collaborating on a shared network or cloud service?

When collaborating on sensitive Excel files over a shared network or cloud service, ensure that both the network and the cloud service have robust security measures in place, such as encrypted connections (SSL/TLS), strong authentication mechanisms, and access controls. Utilize Excel’s password protection for individual files and consider additional encryption for highly sensitive data. Regularly review and update access permissions, and educate collaborators about secure data handling practices to minimize the risk of unauthorized access or data breaches.

Is it possible to automate the process of locking and unlocking sheets in Excel for regular updates?

Automating the locking and unlocking of sheets in Excel can be achieved through VBA scripts. These scripts can programmatically apply or remove protection from sheets based on certain conditions or triggers. However, this approach requires a basic understanding of VBA programming and should be used cautiously, as it might introduce potential security vulnerabilities if not implemented correctly. Always test your scripts in a safe environment before applying them to important files and consider consulting with an Excel VBA expert if needed.

How does Excel’s password protection compare to third-party encryption tools in terms of security?

Excel’s built-in password protection offers a basic level of security suitable for preventing casual access but may not be sufficient for highly sensitive data. Third-party encryption tools typically provide stronger encryption algorithms, such as AES-256, and additional features like key management, multi-factor authentication, and compliance with various security standards. When dealing with highly confidential information, using these tools in conjunction with Excel’s password protection can offer a more robust security solution. It’s important to evaluate the security features of these tools and ensure they meet your specific security requirements and compliance standards.

Extra: How to Password Protect Excel, Word, PowerPoint, or PDF Files with Microsoft Office

When you password protect documents with modern versions of Office, they’re typically encrypted. This means that anybody who tries to read them that doesn’t have your password will just see random strings of letters and numbers. This persists even if you send the document to another person. In our other guide, we show you how to password protect Excel, Word, PowerPoint and PDF files in Microsoft Office so that you can keep your documents private.
 

Extra:  How to Use Windows BitLocker Encryption for System Disks or Other Drives

BitLocker is a proprietary encryption program for Windows that prevents unauthorized access to your drives and can protect against malware. When you perform BitLocker encryption on a drive, it’s transformed into random numbers and letters until you enter your BitLocker password or a USB key, which decrypts the drive. Check out our other guide to learn how to use BitLocker encryption.
 
windows  bitlocker featured

Extra: How to Password-Protect Files in Windows

If you want to encrypt and password-protect Excel files, you can use methods other than the built-in Excel password protection or in combination to add another level of security. Check out our other guide how to protect folders of Excel files or other documents with passwords.
 

Markus Kasanmascheff
Markus Kasanmascheff
Markus is the founder of WinBuzzer and has been playing with Windows and technology for more than 25 years. He is holding a Master´s degree in International Economics and previously worked as Lead Windows Expert for Softonic.com.

Recent News

Table of Contents: