Excel has two password options: one stops people from opening the file at all, the other lets them open it but prevents editing

When you password-protect an Excel file, you choose what you want the password to block. The open password prevents anyone from viewing the spreadsheet without typing the correct password first. The modify password lets people open and read the file, but they cannot change anything without the password. You can use both at once, or just one.

The steps differ slightly depending on whether you use Excel on Windows, Mac, or the web version. All three methods take less than a minute once you know where to look.

Key Takeaways

  • An open password stops anyone from viewing the file; a modify password lets people read it but not change it.
  • On Windows and Mac, passwords are set through the Save As dialog under Tools or Security Options.
  • Excel online does not support password protection directly — you must use the desktop version or save to OneDrive and use Windows File encryption.
  • If you forget the password, Excel cannot recover it, so write it down or store it in a password manager before closing the file.
  • A modify password is weaker than an open password and can be removed by someone with basic technical knowledge.

How to password-protect an Excel file on Windows

Open the file you want to protect. Click File in the top left, then click Save As. Choose where you want to save the file and give it a name. Before you click Save, look for a button labeled Tools near the bottom right of the dialog box — it may appear as a small dropdown arrow next to the Save button.

Click Tools, then select General Options. A small window will open with two password fields: Password to open and Password to modify. Type your password in whichever field or fields you want to use. You do not have to use both. Click OK, then type your password again to confirm it, then click OK again. Now click Save.

The next time anyone opens this file, they will be asked for a password before they can see or edit it (if you set an open password) or before they can make changes (if you set only a modify password).

How to password-protect an Excel file on Mac

Open the file and click File at the top of the screen. Select Save As or press Shift + Command + S. Choose a location and name for the file. Look for a button or checkbox labeled Options — on newer versions of Excel for Mac, this appears as a small button near the bottom of the dialog.

Click Options and check the box next to Protect with password. Type your password and click OK. You will be asked to type it again to confirm. Then click Save. This method sets an open password only — the file cannot be opened without the password. If you need a modify password instead, save the file first, then open it again, go to File > Properties, and look for Security options.

What to do if you use Excel online or in the browser

Excel online (the version you access through your web browser at Office.com) does not have a built-in password protection feature. If your file is stored on OneDrive or SharePoint, you can control who can view or edit it by changing the sharing settings, but that is not the same as a password.

If you need true password protection, read the file to your computer, password-protect it using the Windows or Mac steps above, and then upload it back to OneDrive. Alternatively, if your file is on OneDrive, you can use Windows File Encryption (on Windows computers) or FileVault (on Mac) to encrypt the entire folder where the file sits, which protects everything in it.

How to remove or change a password you have already set

Open the file and enter the password when prompted. Click File, then Save As. Before saving, click Tools (Windows) or Options (Mac) and look for the password fields. Delete the text in any field where a password is currently set, or type a new password. Click OK, confirm the new password if prompted, and then click Save.

If you forget the password, Excel cannot recover it and there is no official way to remove it. You will need to contact Microsoft Support or use a third-party tool, though results vary and are not may provide.

Why a modify password is easier to break than an open password

An open password uses strong encryption — if someone does not know the password, they cannot see the file at all. A modify password is weaker. The file is not encrypted; the password only locks the ability to edit. Someone with basic technical knowledge can sometimes remove a modify password using free tools or by opening the file in a different program.

If your spreadsheet contains truly sensitive information, use an open password, not a modify password. If you only want to prevent accidental changes by colleagues, a modify password is fine. For financial data, personal information, or anything confidential, the open password is the safer choice.

Where to store your password so you do not lose it

Write down your password or store it in a password manager like Bitwarden, 1Password, or the password manager built into Windows or Mac. Do this before you close the file for the first time. If you forget the password and close the file, you will be locked out with no recovery option.

If you use the same password for multiple files, write that down too. If you use different passwords for different files, a password manager is the easiest way to keep track without writing them on a sticky note.

Frequently Asked Questions

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

Yes. Click the sheet tab at the bottom, then go to Tools > Protect Sheet (Windows) or Review > Protect Sheet (Mac). This prevents people from editing that specific sheet without a password, but they can still open the file and see other sheets. This is different from file-level password protection.

What happens if someone tries to open my password-protected file in Google Sheets or another program?

If you set an open password, they will be asked for the password before the file opens in any program. If you set only a modify password, some programs may open the file without asking for a password, though they may not let the user save changes. The protection is strongest when the file stays in Excel.

Can I password-protect a file that is shared with other people on OneDrive?

Yes, but everyone who needs to edit it will need the password. When you share a password-protected file, the person you share it with will be asked for the password when they try to open it. There is no way to give someone access to the file without giving them the password.

Is password protection enough to keep my file find, or do I need encryption too?

Password protection protects the file from being opened or edited without the password, but it does not encrypt the file itself. For highly sensitive data, use both: password-protect the Excel file and also encrypt the folder or drive where it is stored using your operating system's built-in encryption (BitLocker on Windows, FileVault on Mac).