Password-protecting a worksheet is different from protecting the whole file
When you password-protect a worksheet, you lock down what people can change within that sheet — they can still open the file and see the data, but they cannot edit cells, insert rows, delete columns, or modify formulas unless they know the password. This is useful when you share a spreadsheet with colleagues who should view certain sheets but not alter them, or when you want to prevent accidental changes to a sheet with critical calculations.
The worksheet protection feature is built into Excel on Windows, Mac, and the web version. It takes about 30 seconds to set up and does not require you to save the file in a special format — it works with standard .xlsx files.
Key Takeaways
- Worksheet protection prevents editing, inserting rows, and deleting columns, but does not hide the data or prevent file opening.
- You can choose which specific actions to allow — for example, you can let people sort and filter while blocking cell edits.
- The password is optional; you can protect a worksheet without one, though anyone can unprotect it by right-clicking.
- Protected worksheets remain protected when you share the file, but the protection applies only to that single sheet, not the whole workbook.
How to protect a worksheet in Excel on Windows
Open the spreadsheet and click on the sheet tab you want to protect at the bottom of the window. Go to the Review tab in the ribbon at the top. Click Protect Sheet — it is in the middle section of the ribbon, usually near buttons for tracking changes.
A dialog box will open. Type a password in the first field if you want one — the password field is optional, but adding one means only someone who knows it can unprotect the sheet later. Leave it blank if you just want to prevent accidental changes. Below the password fields, you will see a list of checkboxes showing what users can do: "Select locked cells", "Select unlocked cells", "Format cells", "Format columns", and so on. By default, most actions are blocked. Check the boxes for anything you want to allow — for example, if you want people to sort and filter data, check Sort and AutoFilter. Click OK.
If you entered a password, Excel will ask you to type it again to confirm. Do that and click OK. The sheet is now protected. The sheet tab will show a small padlock icon next to its name.
How to protect a worksheet in Excel on Mac
Click the sheet tab at the bottom. Go to the Review tab in the ribbon. Click Protect Sheet. The dialog that opens is the same as on Windows — enter a password if you want one, choose which actions to allow by checking boxes, and click OK. Confirm the password if you set one.
The Mac version works identically to Windows for worksheet protection. Once the sheet is protected, the padlock icon appears next to the sheet tab name, and all the same restrictions explore. If you need to allow specific actions like sorting or filtering, use the same checkboxes in the dialog.
How to protect a worksheet in Excel on the web
Open your file in Excel Online. Click the sheet tab you want to protect. Go to the Review tab. Click Protect Sheet. Enter a password if you want one and click OK. The web version offers fewer granular options than the desktop version — you cannot choose which specific actions to allow — but the sheet will still be protected from editing.
When you protect a sheet in Excel Online, the protection syncs across all devices. If someone opens the same file on a desktop computer, they will see the same protected sheet. The web version applies a standard protection that blocks most editing actions without letting you customize which ones.
What happens when someone tries to edit a protected sheet
If a user tries to click on a locked cell and type, nothing will happen — the cell will not accept input. If they try to insert a row, delete a column, or perform another blocked action, a small dialog will pop up saying the sheet is protected and asking them to contact the sheet owner. They cannot proceed without the password.
Users can still select cells, read formulas in the formula bar, copy data, and print the sheet — they just cannot change anything. If you want to allow sorting or filtering, those actions will work even on protected sheets if you checked those boxes when you set up the protection.
Allowing specific actions while keeping the sheet locked
When you open the Protect Sheet dialog, the checkboxes control what people can do. The most common setup is to block all editing but allow sorting and filtering — this lets people reorganize the view without changing the underlying data. To do this, check only Select locked cells, Select unlocked cells, Sort, and AutoFilter, then uncheck everything else.
If you want people to fill in certain cells (like a form), you can unlock those specific cells first, then protect the sheet. To unlock cells before protecting: select the cells you want people to edit, right-click, choose Format Cells, go to the Protection tab, and uncheck Locked. Then protect the sheet. Now only the unlocked cells can be edited.
Removing worksheet protection
To unprotect a sheet you own, go to the Review tab and click Unprotect Sheet. If you set a password, Excel will ask you to type it. If you did not set a password, the sheet unprotects when ready with no prompt.
If you forgot the password, there is no built-in recovery — you cannot unprotect the sheet without it. Some third-party tools claim to remove Excel passwords, but they are unreliable and may not work on newer Excel files. The safest approach is to keep a record of any passwords you set, or to protect sheets without passwords if you do not need that level of security.
Frequently Asked Questions
Does protecting a worksheet hide the data?
No. People can still see all the data, read formulas in the formula bar, and copy cells. Protection only prevents editing, inserting rows, deleting columns, and other structural changes. If you need to hide data, you would hide columns or rows separately before protecting the sheet.
Can I protect some sheets and leave others unprotected in the same file?
Yes. You protect each sheet individually. One sheet can be locked while another in the same workbook is open for editing. Just click the sheet tab and protect it separately.
What if I protect a sheet and then share the file with someone?
The protection travels with the file. When they open it, the sheet will still be protected and they will not be able to edit it unless they have the password. The protection does not depend on who owns the file or where it is stored.
Can I protect a worksheet without a password?
Yes. Leave the password field blank when you set up protection. The sheet will still be locked, but anyone can unprotect it by going to Review and clicking Unprotect Sheet — no password needed. Use this when you want to prevent accidental changes but do not need security against intentional ones.
Does worksheet protection work the same way in Google Sheets?
Google Sheets has a similar feature called "Protect sheets and ranges" but it works differently — you can restrict editing to specific people by email address, not just with a password. The steps are different and the options are not identical to Excel.