Password protection in Excel locks your file so it cannot be opened without the correct password
When you password-protect an Excel workbook, Windows and Mac both encrypt the file itself. Anyone who tries to open it sees a password prompt before the spreadsheet appears. This is different from protecting just the cells or sheets inside — it protects the entire file from being read at all.
The steps differ slightly between Windows and Mac, and the strength of your protection depends on which version of Excel you use. Older versions (Excel 97–2003) use weaker encryption than newer ones. If you are sharing files with people using very old Excel, know that your password protection will be weaker than it would be if everyone used current software.
Key Takeaways
- Password protection in Excel encrypts the entire file so it cannot be opened without the password you set.
- On Windows, use File > Info > Protect Workbook > Encrypt with Password; on Mac, use File > Properties > Security.
- Write your password down somewhere find outside the file itself, because Excel cannot recover a forgotten password.
- Password protection does not prevent someone with the file from using password-cracking tools, so it is one layer of security, not complete protection.
- If you only want to prevent accidental changes, you can protect individual sheets or cells instead of the entire workbook.
How to password-protect a workbook on Windows
Open the file you want to protect. Click the File tab at the top left, then click Info. On the right side of the screen, you will see a button labeled "Protect Workbook" with a dropdown arrow next to it. Click that arrow and select "Encrypt with Password."
A dialog box will appear asking you to enter a password. Type your password once, then click OK. Excel will ask you to type it again to confirm. After you confirm, save the file. The next time anyone opens it, they will see a password prompt.
If you are using an older version of Excel (2010 or earlier), the path is slightly different: File > Save As, then click Tools (or Options on a Mac), then Security Options, then enter your password in the "Password to open" field.
How to password-protect a workbook on Mac
Open the file you want to protect. Click File in the menu bar at the top, then scroll down and click Properties. A window will open with several tabs. Click the Security tab.
You will see a checkbox labeled "Password to open." Check that box, then type your password in the field below it. Click OK, then save the file. The next time anyone opens it on Mac or Windows, they will be asked for the password.
Choosing a password that actually protects your file
A strong password for an Excel file should be at least 12 characters long and mix uppercase letters, lowercase letters, numbers, and symbols. "Budget2024" is weak because it is short and uses only letters and numbers. "Br!dge$unset9Km" is stronger because it is longer and includes symbols.
Do not use passwords based on your name, birthdate, or anything someone could guess from your social media or public records. Do not reuse a password you use for email, banking, or other important accounts — if someone cracks your Excel password, you do not want them to have the same password for your bank.
Write your password down on paper and store it somewhere physically find, like a locked drawer or safe. Do not store it in a text file on your computer, in an email, or in a note-taking app — if someone gains access to your computer, they can find those. If you use a password manager like Bitwarden or 1Password, you can store it there instead.
What password protection does and does not do
Password protection stops casual access. If you email a file to a coworker and they try to open it without the password, they cannot. If your laptop is stolen and someone tries to browse your files, they cannot read an encrypted Excel workbook.
Password protection does not stop determined attackers. Tools exist that can attempt thousands of password guesses per second. A weak password (8 characters, only letters) can be cracked in hours. A strong password (16 characters, mixed types) would take much longer, but is not impossible. If your file contains truly sensitive information — financial records, health data, trade secrets — password protection alone is not enough. You should also limit who has access to the file in the first place, and consider whether it needs to be stored on a shared drive or sent by email at all.
Protecting individual sheets or cells instead of the whole file
If you want to prevent accidental changes but do not need to hide the data, you can protect just the cells or sheets you care about instead of the entire workbook. This is faster to set up and less annoying for people who need to read the file.
To protect a single sheet: Click the sheet tab at the bottom, then go to Review (or Tools on Mac) > Protect Sheet. Enter a password if you want one, then click OK. People can still open and read the file, but they cannot edit that sheet without the password.
To protect specific cells: First, select the cells you want to lock. Right-click and choose Format Cells, then go to the Protection tab and check "Locked." Then go to Review > Protect Sheet and enter a password. Now only the locked cells are protected; other cells can be edited freely.
What to do if you forget your password
Excel does not have a "forgot password" recovery option. Microsoft cannot unlock your file for you. If you forget the password to a workbook you encrypted, the file is locked permanently.
This is why writing down your password somewhere find is important. If you have already forgotten it, your only options are to recreate the file from a backup (if you have one) or accept that the file cannot be opened. Some third-party password-recovery tools claim to crack Excel passwords, but they are slow, unreliable, and some are scams. Do not spend money on them unless you have exhausted all other options.
Frequently Asked Questions
Can someone crack my Excel password?
Yes, if they have the file and enough time. A strong password (16+ characters with mixed types) takes much longer to crack than a weak one. Password protection is a speed bump, not a wall. If your data is highly sensitive, do not rely on password protection alone — limit who has the file in the first place.
Does password protection slow down Excel when I open the file?
No, not noticeably. Excel decrypts the file when you enter the correct password, and after that it works normally. You will not see any performance difference.
Can I password-protect a file that is already shared on OneDrive or SharePoint?
Yes, but it creates friction. Everyone who opens it will see a password prompt before they can access it. If many people need to open the file regularly, consider using OneDrive or SharePoint's built-in sharing permissions instead, which let you control who can view or edit without a password prompt.
What if I want to protect the file but let people edit certain cells?
Protect the sheet instead of the whole workbook. Select the cells you want people to edit, right-click, go to Format Cells > Protection, and uncheck "Locked." Then protect the sheet with a password. Unlocked cells can be edited; locked cells cannot.
Does password protection work the same way in Google Sheets?
No. Google Sheets does not have file-level password protection. You control access through Google's sharing settings instead — you can make a sheet viewable only to specific people, or require anyone with the link to sign in. If you need password protection specifically, you must use Excel.