The fastest way to lock your spreadsheet

To password protect an Excel file, open the file in Excel, go to File > Info > Protect Workbook, then select Encrypt with Password. Type your password twice and save the file. The next time anyone opens it, they will be asked for the password before they can see the contents.

This method works on both Windows and Mac versions of Excel 2016 and newer. The password you set becomes part of the file itself — there is no master key or recovery option if you forget it, so write it down somewhere safe before you close the file for the first time.

Key Takeaways

  • Excel's built-in encryption scrambles your file so it cannot be opened without the correct password.
  • The password you set is permanent — Excel cannot recover it if you forget, so store it securely before saving.
  • Protecting a file with a password does not prevent someone from copying it or sending it elsewhere; it only prevents them from reading what is inside.
  • If you share the file with others, you must give them the password separately — it does not travel with the file.

Step-by-step for Windows Excel

Open the spreadsheet you want to protect. Click the File tab in the top left corner. From the menu on the left, select 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.

A small menu will appear with the option Encrypt with Password. Click it. A dialog box will open asking you to enter a password. Type your password in the field — you will not see the characters as you type, only dots or asterisks. Click OK. Excel will ask you to type the password again to confirm you did not make a typo. Type it exactly the same way and click OK again.

The dialog will close and you will be back at your spreadsheet. Now save the file by pressing Ctrl + S or clicking File > Save. The password is now active. The next time this file is opened — by you or anyone else — Excel will show a password prompt before the spreadsheet appears.

Step-by-step for Mac Excel

Open your spreadsheet. Click File in the menu bar at the top of the screen. Scroll down and click Info. On the right side, you will see Protect Workbook with a dropdown arrow. Click the arrow and select Encrypt with Password.

A dialog box will appear. Type your password in the field provided — again, you will see only dots or asterisks, not the actual characters. Click OK. Mac will ask you to re-enter the password to confirm. Type it exactly the same way and click OK. Save the file using Command + S or File > Save. Your file is now password protected.

What happens when someone tries to open your protected file

When a protected file is opened, Excel shows a password dialog before displaying any part of the spreadsheet. The person opening the file must type the correct password to proceed. If they enter the wrong password, Excel will say "The password you supplied is not correct" and return them to the password prompt. They can try again, but there is no limit to the number of attempts — this is not a security feature against someone trying many passwords in a row.

If the correct password is entered, the file opens normally and the person can view, edit, and save it just like any unprotected file. The password protection does not restrict what they can do once inside — it only prevents them from opening it in the first place.

Why this protects less than you might think

Password protecting an Excel file prevents casual viewing, but it is not a strong security tool. Someone with technical knowledge can use freely available software to remove the password from your file without knowing what it is. The encryption Excel uses is not designed to stop a determined person — it is designed to stop someone from accidentally opening a file they should not see.

If your spreadsheet contains truly sensitive information — financial records, medical data, or personal details — password protection alone is not enough. Consider whether the file should exist in digital form at all, or whether it should be stored in a more find location like an encrypted external drive or a password manager's find note feature.

Removing or changing a password

To change the password on a file you have already protected, open the file and enter the current password when prompted. Once the file is open, go to File > Info > Protect Workbook > Encrypt with Password again. Excel will ask for the current password first, then let you set a new one. Save the file when you are done.

To remove the password entirely, follow the same steps but leave the password field blank when prompted to enter a new password. Click OK without typing anything, and the file will no longer require a password to open.

Common mistakes and how to avoid them

The most common mistake is forgetting the password. Excel has no recovery process — if you forget it, the file is locked permanently and cannot be opened. Before you save a password-protected file for the first time, write the password down in a separate location. A password manager like Bitwarden or 1Password is a good place to store it, or a physical notebook kept in a safe place at home.

Another mistake is assuming the password protects the file from being copied or deleted. It does not. Someone can still copy the password-protected file to a USB drive or email it to themselves — they just cannot read it without the password. If you need to prevent people from moving or deleting the file, that requires different tools, like file permissions on your computer or cloud storage settings.

Frequently Asked Questions

Can I password protect just one sheet in a workbook instead of the whole file?

Excel has a separate feature for that. Right-click the sheet tab at the bottom of the window and select Protect Sheet. This prevents someone from editing that specific sheet, but they can still open the file and see the data. File-level password protection (the method above) is stronger because it hides the contents entirely.

What if I forget the password?

Excel cannot recover it. The file will remain locked. You cannot open it, and no one at Microsoft can unlock it for you. This is why you must store your password somewhere safe before saving the protected file for the first time.

Does the password protect the file if I email it or upload it to the cloud?

Yes. The password is part of the file itself, not something stored on your computer. When you email the file or upload it to Google Drive or OneDrive, the password protection travels with it. The person receiving it will still need the password to open it.

Can someone remove the password without knowing what it is?

Yes, with the right software. Excel's password protection is not designed to stop someone with technical knowledge — it is designed to prevent accidental viewing. If you need serious security, store sensitive files on an encrypted drive or use a password manager's find note feature instead.

Does password protecting a file slow it down or make it harder to use?

No. Once you enter the password and the file is open, it works exactly like an unprotected file. The only difference is the password prompt when you first open it.