To partially protect an Excel sheet, unlock the cells people should be able to edit, then protect the worksheet. In Excel for Microsoft 365 on Windows, select the input cells, press Ctrl+1, clear Locked on the Protection tab, and choose Review > Protect Sheet. The sheet protection then prevents changes to the remaining locked cells while allowing edits in the unlocked cells.
This is useful for forms, templates, and shared workbooks where users need to enter data without accidentally overwriting headings, formulas, or instructions. Worksheet protection helps prevent unintended edits; it is not a security feature for confidential information. Anyone who can open the workbook may still be able to view its contents.
What You’ll Need
- An Excel workbook with the cells you want to protect and the cells you want people to edit identified.
- Excel for Microsoft 365 on Windows for the steps below. Excel for Mac has similar controls, noted where they differ. Excel for the web has more limited protection controls, so use the desktop app to configure the sheet if a setting is missing.
- Optionally, a password you can store safely. A password is not required, but without one anyone can remove sheet protection.
Step-by-Step
- Plan which cells users can change. Open the worksheet and identify the input areas, such as blank cells for names, dates, or quantities. Treat formula cells, labels, instructions, and layout cells as protected. If the sheet is already in use, consider saving a separate copy before changing its protection settings, so you can restore the original if needed.
- Select the cells that should remain editable. Click and drag over a continuous input area. To select separate areas, hold
Ctrlwhile selecting each range on Windows. You can also select a whole column or row if every cell in it should be editable, but avoid doing that if it includes formulas or headings that need protection. Check the selection before changing its settings. - Open the cell-formatting controls. Press
Ctrl+1on Windows to open the Format Cells dialog. You can also right-click the selected cells and choose Format Cells. On a Mac, useCommand+1or open Format > Cells. In the dialog, select the Protection tab. - Unlock the selected input cells. Clear the Locked checkbox and choose OK. This does not immediately let users edit the cells: the Locked setting only takes effect after you protect the worksheet. The setting is stored for each cell, so changing it for an input range does not unlock other cells in the sheet.
- Confirm that cells to protect are locked. Excel normally marks cells as locked by default, including cells that already contain formulas. To check, select a formula or heading cell, open Format Cells > Protection, and confirm that Locked is selected. If a cell was previously unlocked, select it or its range and select Locked before continuing. Do not select the entire sheet and change this setting unless you intend to change the status of every cell.
- Choose what users may do while the sheet is protected. Go to Review > Protect Sheet. In the dialog, leave Protect worksheet and contents of locked cells selected. Under the list of permitted actions, decide what users need. For a simple form, allowing selection of unlocked cells is usually enough. You can also allow selection of locked cells, formatting, inserting rows, or other listed actions when the task requires them. Allow only the actions that make sense for your sheet.
- Add a password if appropriate, then protect the sheet. Enter a password in the password field if you want one, and select OK. Excel will ask you to enter it again to confirm. The password is optional; if you leave it blank, protection can be removed without a password. If you use one, store it somewhere secure and accessible to the people responsible for maintaining the workbook. Losing it can make editing the protected sheet difficult.
- Test both kinds of cells. Click an unlocked input cell and type a temporary value. Then try changing a locked formula or heading cell; Excel should prevent the change. Undo or remove the test value afterward. Also check any actions you allowed, such as sorting or filtering. Testing catches a mistaken range selection or a permission setting that does not match how the sheet will be used.
- Save the workbook. Save after testing. If others will use the file, explain which cells they can edit and how to request a change to protected content. To make later changes yourself, use Review > Unprotect Sheet, enter the password if prompted, make the changes, and protect the sheet again.
Common Mistakes
- Protecting the sheet before unlocking the input cells. Because cells are locked by default, protecting the sheet first can make every cell uneditable. Unprotect it, unlock the intended ranges, then protect it again.
- Assuming Locked prevents edits on its own. The Locked checkbox has no practical effect while the worksheet is unprotected. You must turn on sheet protection for Excel to enforce it.
- Unlocking too much. If you select an entire column that contains formulas, those formulas become editable too. Review the selected range and, after changing the setting, verify a representative formula cell is still locked.
- Confusing sheet protection with workbook protection. Protect Sheet controls edits on one worksheet. Protect Workbook controls certain workbook-level changes, such as adding, deleting, or moving sheets. Protecting one does not automatically protect the other.
- Using sheet protection as a way to hide sensitive data. Protection is intended to guard against accidental changes, not to encrypt or securely conceal information. Do not rely on it to keep confidential data from someone who can access the workbook.
- Allowing more actions than necessary. Extra permissions can let users change formatting or structure in ways that make a template confusing. Start with the minimum permissions and add an option only when there is a real need.
Tips
- Make input cells obvious. Use a consistent fill color, border, or instruction such as Enter values in shaded cells. Visual cues reduce questions and help users avoid trying to edit locked areas.
- Keep formulas visibly distinct. You can color formula cells differently or add a note explaining that they calculate automatically. If you want to hide formulas from the formula bar, select those cells, open Format Cells > Protection, select Hidden, and then protect the sheet. Hidden only takes effect while the sheet is protected; it is not a substitute for data security.
- Use permissions that fit the job. If people need to use existing filter arrows, enable Use AutoFilter in the protection options. The filter should be set up before protecting the sheet. Sorting protected ranges can be restricted, especially when the sort would move locked cells, so test the exact workflow before sharing.
- Keep a maintainable source copy. Store an unprotected version in a controlled location if the workbook needs frequent structural changes. Clearly distinguish it from the protected copy to prevent people from entering live data into the wrong file.
- Use a password deliberately. A password can discourage casual removal of protection, but it also adds a recovery responsibility. If several people maintain the file, agree on a secure way to share and retain the password rather than placing it in a visible worksheet cell.
- Review protection after changing the layout. Inserting or copying cells can carry formatting and protection settings with them. After modifying a template, check that new input cells are unlocked and new formula or label cells are locked before distributing it again.
Troubleshooting
- I cannot type in an input cell. The cell may still be locked, or it may not have been included in the unlocked range. Choose Review > Unprotect Sheet, enter the password if requested, select the cell, and check Format Cells > Protection. Clear Locked, protect the sheet again, and test it.
- I can edit a formula or heading. Unprotect the sheet and check the cell’s Locked setting. Select Locked for the affected cell or range, then protect the worksheet again. Make sure the cell was not accidentally included in an input range that you unlocked.
- The Protect Sheet command is unavailable or protection behaves unexpectedly. Check whether the workbook is in a mode or format that limits editing, and confirm you are working in the desktop Excel app rather than a restricted web view. If the file is shared or opened read-only, save a working copy you are authorized to edit. Reopen the copy and check the Review tab.
- Users cannot sort, filter, or format cells. Unprotect the sheet and review the allowed actions in Review > Protect Sheet. Enable only the relevant options, and set up features such as filter arrows before applying protection. Some actions remain restricted by how the range is protected; test with the same range and task users will use.
- You forgot the password. Check your password manager, team documentation, or the person who set up the workbook. Excel does not provide a normal password-recovery button for protected sheets. If no authorized copy or password is available, use an unprotected backup if one exists rather than experimenting on the only copy.
- Excel for the web does not show the setting you need. Open the workbook in the desktop app and set the cell lock states and protection options there. Web capabilities and controls can differ from the Windows and Mac desktop versions, so do not assume a missing option means the cells were configured as intended.
Frequently Asked Questions
Can I protect only certain cells in Excel?
Not directly as a separate protection boundary. Excel protects the worksheet, then uses each cell’s Locked setting to determine which cells are editable. Unlock the cells users need and protect the sheet to create a partially editable worksheet.
Are Excel cells locked by default?
Usually, yes. Most cells start with Locked selected in Format Cells, but that setting does not restrict editing until you protect the worksheet. Existing workbooks may have cells with different settings, so check important ranges.
Can I protect a sheet without a password?
Yes. You can protect the sheet and leave the password blank. This helps prevent accidental edits, but anyone can remove protection through the Unprotect Sheet command without entering a password.
Can users enter data in unlocked cells and still use formulas?
Yes. A common setup is to unlock input cells and leave formula cells locked. After protection is enabled, users can enter values in the inputs while Excel blocks edits to the locked formulas.
Does protecting a worksheet stop people from viewing its data?
No. Sheet protection is not encryption and should not be used to secure confidential information. Use appropriate file access controls and encryption for sensitive workbooks.
How do I edit a protected sheet later?
Choose Review > Unprotect Sheet. Enter the password if one was set, make the necessary changes, and protect the sheet again. Save the workbook after confirming that the editable ranges and allowed actions are still correct.
Related
- Generate a Heat Map in Excel: Color Scales and Tips
- Four-Quadrant Scatter Plot in Excel: How to Make One
- Flash Fill Settings in Excel: How to Enable or Disable
Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.
More in How-to basics
- Excel Named Range to Table: What Works and What Doesn’tExcel does not have a command that directly converts a named range into a table by name. Select…
- Excel Shortcut Desk Mat: What It Is and How to ChooseAn Excel shortcut desk mat is a large mouse-and-keyboard surface printed with keyboard commands for Microsoft Excel. It…
- Track Changes in Word on SharePoint: A Practical GuideTo track changes in a Word document stored on SharePoint, open it in Word, go to Review >…
- How to Record a PowerPoint Presentation With SubtitlesYes. In PowerPoint for Microsoft 365, record your slides and narration, export the presentation as a video, then…
- Snowball Debt Payoff Spreadsheet: Free Excel SetupYes—you can make a free snowball debt payoff spreadsheet in Excel by listing each debt, its balance, annual…
- How to Flip a Table Upside Down in Excel by Reversing RowsTo flip a table upside down in Excel, reverse the order of its data rows while keeping each…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.