Protect a worksheet - Microsoft Support (2024)

To prevent other users from accidentally or deliberately changing, moving, or deleting data in a worksheet, you can lock the cells on your Excel worksheet and then protect the sheet with a password. Say you own the team status report worksheet, where you want team members to add data in specific cells only and not be able to modify anything else. With worksheet protection, you can make only certain parts of the sheet editable and users will not be able to modify data in any other region in the sheet.

Important:Worksheet level protection isn'tintended as a security feature. It simply prevents users from modifying locked cells within the worksheet.Protecting a worksheet is not the same as protecting an Excel file or a workbook with a password. See below for more information:

  • To lock your file so that other users can’t open it, see Protect an Excel file.

  • To prevent users from adding, modifying, moving, copying, or hiding/unhiding sheets within a workbook, see Protect a workbook.

  • To know the difference between protecting your Excel file, workbook, or a worksheet see Protection and security in Excel.

WindowsWeb

The following sections describe how to protect and unprotect a worksheet in Excel for Windows.

Here's what you can lock in an unprotected sheet:

  • Formulas: If you don’t want other users to see your formulas, you can hide them from being seen in cells or the Formula bar. For more information, see Display or hide formulas.

  • Ranges: You can enable users to work in specific ranges within a protected sheet. For more information, see Lock or unlock specific areas of a protected worksheet.

Note:ActiveX controls, form controls, shapes, charts, SmartArt, Sparklines, Slicers, Timelines, to name a few, are already locked when you add them to a spreadsheet. But the lock will work only when you enable sheet protection. See the subsequent section for more information on how to enable sheet protection.

Worksheet protection is a two-step process: the first step is to unlock cells that others can edit, and then you can protect the worksheet with or without a password.

Step 1: Unlock any cells that needs to be editable

  1. In your Excel file, select the worksheet tab that you want to protect.

  2. Select the cells that others can edit.

    Tip:You can select multiple, non-contiguous cells by pressing Ctrl+Left-Click.

  3. Right-click anywhere in the sheet and select Format Cells (or use Ctrl+1, or Command+1 on the Mac), and then go to the Protection tab and clear Locked.

    Protect a worksheet - Microsoft Support (1)

Step 2: Protect the worksheet

Next, select the actions that users should be allowed to take on the sheet, such as insert or delete columns or rows, edit objects, sort, or use AutoFilter, to name a few. Additionally, you can also specify a password to lock your worksheet. A password prevents other people from removing the worksheet protection—it needs to be entered to unprotect the sheet.

Given below are the steps to protect your sheet.

  1. On the Review tab, click Protect Sheet.

    Protect a worksheet - Microsoft Support (2)
  2. In the Allow all users of this worksheet to list, select the elements you want people to be able to change.

    Protect a worksheet - Microsoft Support (3)

    Option

    Allows users to

    Select locked cells

    Move the pointer to cells for which the Locked box is checked on the Protection tab of the Format Cells dialog box. By default, users are allowed to select locked cells.

    Select unlocked cells

    Move the pointer to cells for which the Locked box is unchecked on the Protection tab of the Format Cells dialog box. By default, users can select unlocked cells, and they can press the TAB key to move between the unlocked cells on a protected worksheet.

    Format cells

    Change any of the options in the Format Cells or Conditional Formatting dialog boxes. If you applied conditional formatting before you protected the worksheet, the formatting continues to change when a user enters a value that satisfies a different condition.

    Note:Paste now correctly honors the Format cells option.In older versions of Excel, paste always pasted with formatting regardless of the Protection options.

    Format columns

    Use any of the column formatting commands, including changing column width or hiding columns (Home tab, Cells group, Format button).

    Format rows

    Use any of the row formatting commands, including changing row height or hiding rows (Home tab, Cells group, Format button).

    Insert columns

    Insert columns.

    Insert rows

    Insert rows.

    Insert hyperlinks

    Insert new hyperlinks, even in unlocked cells.

    Delete columns

    Delete columns.

    Note:If Delete columns is protected and Insert columns is not protected, a user can insert columns but cannot delete them.

    Delete rows

    Delete rows.

    Note:If Delete rows is protected and Insert rows is not protected, a user can insert rows but cannot delete them.

    Sort

    Use any commands to sort data (Data tab, Sort & Filter group).

    Note:Users can't sort ranges that contain locked cells on a protected worksheet, regardless of this setting.

    Use AutoFilter

    Use the drop-down arrows to change the filter on ranges when AutoFilters are applied.

    Note:Users cannot apply or remove AutoFilter on a protected worksheet, regardless of this setting.

    Use PivotTable reports

    Format, change the layout, refresh, or otherwise modify PivotTable reports, or create new reports.

    Edit objects

    Doing any of the following:

    • Make changes to graphic objects including maps, embedded charts, shapes, text boxes, and controls that you did not unlock before you protected the worksheet. For example, if a worksheet has a button that runs a macro, you can click the button to run the macro, but you cannot delete the button.

    • Make any changes, such as formatting, to an embedded chart. The chart continues to be updated when you change its source data.

    • Add or edit notes.

    Edit scenarios

    View scenarios that you have hidden, making changes to scenarios that you have prevented changes to, and deleting these scenarios. Users can change the values in the changing cells, if the cells are not protected, and add new scenarios.

  3. Optionally, enter a password in the Password to unprotect sheet box and click OK. Reenter the password in the Confirm Password dialog box and click OK.

    Important:

    • Use strong passwords that combine uppercase and lowercase letters, numbers, and symbols. Weak passwords don't mix these elements. Passwords should be 8 or more characters in length. A passphrase that uses 14 or more characters is better.

    • It is critical that you remember your password. If you forget your password, Microsoft cannot retrieve it.

The Protect Sheet option on the ribbon changes to Unprotect Sheet when a sheet is protected. To view this option, click the Review tab on the ribbon, and in Changes, see Unprotect Sheet.

Protect a worksheet - Microsoft Support (4)

Protect a worksheet - Microsoft Support (5)

To unprotect a sheet, follow these steps:

  1. Go to the worksheet you want to unprotect.

  2. Go to File > Info > Protect > Unprotect Sheet, or from the Review tab > Changes > Unprotect Sheet.

  3. If the sheet is protected with a password, then enter the password in the Unprotect Sheet dialog boxand click OK.

The following sections describe how to protect and unprotect a worksheet in Excel for the Web.

  1. Select Review >Manage Protection.

  2. To turn on protection, in the Manage Protection task pane, select Protect sheet.

    Note Although you can selectively protect parts of the sheet by setting various options in the Options section, these settings only apply when the Protect sheet setting is on.

    Protect a worksheet - Microsoft Support (6)
  3. By default, the entire sheet is locked and protected. To unlock specific ranges, select Unlocked ranges, and then enter a range name and cell range. You can add more than one range.

    Protect a worksheet - Microsoft Support (7)
  4. Optionally, to require a password to edit a range, select Range password, enter and confirm the password, and then select Save. Make sure sheet protection is turned on.

    Protect a worksheet - Microsoft Support (8)
  5. Optionally, to control the ability to edit protections for the entire sheet with a password, select Sheet protection password, enter and confirm the password, and then select Save.

    Protect a worksheet - Microsoft Support (9)

    Important

    • Use strong passwords that combine uppercase and lowercase letters, numbers, and symbols. Weak passwords don't mix these elements. Passwords should be 8 or more characters in length. Make sure the CAPS LOCK key is off and use correct capitalization. Passwords are case-sensitive.

    • It is critical that you remember your password.If you forget your password, Microsoft cannot retrieve it.

  6. Optionally, if you want to selectively enable and disable specific sheet elements, select the Options section, and then select one or more options.

    Option

    Allows users to

    Select locked cells

    Move the pointer to cells for which the Locked box is checked on the Protection tab of the Format Cells dialog box. By default, users are allowed to select locked cells.

    Select unlocked cells

    Move the pointer to cells for which the Locked box is unchecked on the Protection tab of the Format Cells dialog box. By default, users can select unlocked cells, and they can press the TAB key to move between the unlocked cells on a protected worksheet.

    Format cells

    Change any of the options in the Font and Alignment groups of the Home tab.

    Note If cell formatting and hidden properties were previously protected by using the Format Cells or Conditional Formatting dialog boxes, they remain protected, but you can only modify options in these dialog boxes by using Excel for Windows. If you applied conditional formatting before you protected the worksheet, the formatting continues to change when a user enters a value that satisfies a different condition.

    Format columns

    Use any of the column formatting commands, including changing column width or hiding columns (Home tab, Cells group, Format button).

    Format rows

    Use any of the row formatting commands, including changing row height or hiding rows (Home tab, Cells group, Format button).

    Insert columns

    Insert columns.

    Insert rows

    Insert rows.

    Insert hyperlinks

    Insert new hyperlinks, even in unlocked cells.

    Delete columns

    Delete columns.

    Note:If Delete columns is protected and Insert columns is not protected, a user can insert columns but cannot delete them.

    Delete rows

    Delete rows.

    Note:If Delete rows is protected and Insert rows is not protected, a user can insert rows but cannot delete them.

    Sort

    Use any commands to sort data (Data tab, Sort & Filter group).

    Note:Users can't sort ranges that contain locked cells on a protected worksheet, regardless of this setting.

    Use AutoFilter

    Use the drop-down arrows to change the filter on ranges when AutoFilters are applied.

    Note:Users cannot apply or remove AutoFilter on a protected worksheet, regardless of this setting.

    Use PivotTable reports

    Format, change the layout, refresh, or otherwise modify PivotTable reports, or create new reports.

    Edit objects

    Doing any of the following:

    • Make changes to graphic objects including maps, embedded charts, shapes, text boxes, and controls that you did not unlock before you protected the worksheet. For example, if a worksheet has a button that runs a macro, you can click the button to run the macro, but you cannot delete the button.

    • Make any changes, such as formatting, to an embedded chart. The chart continues to be updated when you change its source data.

    • Add or edit notes.

    Edit scenarios

    View scenarios that you have hidden, making changes to scenarios that you have prevented changes to, and deleting these scenarios. Users can change the values in the changing cells, if the cells are not protected, and add new scenarios.

    Notes

    • If you don’t want other users to see your formulas, you can hide them from being seen in cells or the Formula bar. For more information, seeDisplay or hide formulas.

    • ActiveX controls, form controls, shapes, charts, SmartArt, Sparklines, Slicers, Timelines, and so on, are already locked when you add them to a spreadsheet. But the lock works only when you enable sheet protection. For more information, seeProtect controls and linked cells on a worksheet.

There are two ways to unprotect a sheet, disable it or pause it.

Disable protection

  1. Select Review >Manage Protection.

  2. To turn off protection, In the Manage Protection task pane, turn off Protect sheet.

    Protect a worksheet - Microsoft Support (10)

Pause protection

Pausing protection turns off protection for the current editing session while maintaining the protection for other users in the workbook. For example, you can pause protection to edit a locked range but maintain protection for other users.

  1. To pause sheet protection, select Review >Pause Protection.

    Protect a worksheet - Microsoft Support (11)

    Note If the sheet has a protection password, you must enter that password to pause protection.

  2. To resume sheet protection, select Review >Resume Protection.

    Protect a worksheet - Microsoft Support (12)

At the bottom of the sheet, the sheet tab displays a locked icon if the sheet is protected (Sheet1), and an unlocked icon if it is paused (Sheet2).

Protect a worksheet - Microsoft Support (13)

See Also

Protection and security in Excel

Protect an Excel file

Protect a workbook

Lock or unlock specific areas of a protected worksheet

Lock cells to protect them

Display or hide formulas

Protect controls and linked cells on a worksheet

Copy and paste in a protected worksheet

Video: Password protect workbooks and worksheets (Excel 2013)

Protect a worksheet - Microsoft Support (2024)

FAQs

Protect a worksheet - Microsoft Support? ›

Select File > Info. Select the Protect Workbook box and choose Encrypt with Password. Enter a password in the Password box, and then select OK. Confirm the password in the Reenter Password box, and then select OK.

How do I protect a specific worksheet? ›

Protect a sheet. Select Review > Manage Protection. To turn on protection, in the Manage Protection task pane, select Protect sheet. Note Although you can selectively protect parts of the sheet by setting various options in the Options section, these settings only apply when the Protect sheet setting is on.

What can a worksheet be protected by? ›

To prevent other users from viewing hidden worksheets, adding, moving, deleting, or hiding worksheets, and renaming worksheets, you can protect the structure of your Excel workbook with a password.

How do you protect worksheet but allow editing? ›

On the Review tab, select Protect Sheet. In the Allow all users of this worksheet to list, choose the elements that you want users to be able to change.

How do I protect an Excel workbook in Office 365? ›

Require a password to open or modify a workbook
  1. Open the sheet or workbook that you want to protect.
  2. On the Review tab, click Protect Sheet or Protect Workbook.
  3. In the Password box, type a password, and in the Verify box, type the password again.
  4. Choose any other protection options you want and click OK.
  5. Click Save.

What are the three different ways you protect your worksheet? ›

You can protect Excel workbooks at the file level or at the worksheet level. There are three levels of password protection in Excel: password protection to open a file, password protection to change data, or password protection for changing the file's structure, such as adding, deleting, or hiding worksheets.

Is it possible to protect a worksheet without assigning it any password? ›

Right click a worksheet tab at the bottom of your screen and select Protect Sheet… from the context menu. Or, click the Protect Sheet button on the Review tab, in the Changes group.

What are the two ways by which a user can protect a worksheet? ›

You have two choices here:
  • File encryption: When you choose this option, you specify a password and lock the Excel file. ...
  • Setting a password to open or modify a file: You specify a password to open or modify a file.

How do I protect a worksheet in Word? ›

Protect a document with a password
  1. Go to File > Info > Protect Document > Encrypt with Password.
  2. Type a password, press OK, type it again and press OK to confirm it.
  3. Save the file to make sure the password takes effect.

What does a protect workbook do? ›

Protecting Excel workbooks is a method where we save the whole workbook rather than a single sheet. It means saving the entire structure of the workbook. If a workbook is protected with a password, no other user can insert a new sheet or delete any sheet.

How do you protect a workbook from editing? ›

Protect a Worksheet from Editing

Click on the "Review" tab on the main Excel ribbon. Click "Protect Sheet." Enter the password you would like to use to unlock the sheet in the future. Select the permissions you would like users to have for the worksheet after it is locked.

How do I protect files in Microsoft 365? ›

Restrict changes to files

Open a document you want to protect, then: Select File > Info. Select Protect Document. Choose how you want to protect the document.

How do I protect workbook permissions in Excel? ›

Open the file. Select File > Info. Select Protect Workbook, point to Restrict Permission by People, and then select Restricted Access.

How do you protect a workbook in Excel 365 but allow read only? ›

1. Select File > Info > Protect Document. 2. Select Always open Read-Only.

Can you protect part of a worksheet in Excel? ›

Follow these steps to lock cells in a worksheet: Select the cells you want to lock. On the Home tab, in the Alignment group, click the small arrow to open the Format Cells popup window. On the Protection tab, select the Locked check box, and then click OK to close the popup.

How do I protect an Excel workbook from editing by others? ›

To do this, open the file in Microsoft Excel, click the File tab, and then select the Info option. On the Info page, you'll see a Protect Workbook option. Click this and you'll be prompted to enter a password. Once you've created the password, no one can open the file without it.

Top Articles
Latest Posts
Article information

Author: Saturnina Altenwerth DVM

Last Updated:

Views: 6089

Rating: 4.3 / 5 (44 voted)

Reviews: 91% of readers found this page helpful

Author information

Name: Saturnina Altenwerth DVM

Birthday: 1992-08-21

Address: Apt. 237 662 Haag Mills, East Verenaport, MO 57071-5493

Phone: +331850833384

Job: District Real-Estate Architect

Hobby: Skateboarding, Taxidermy, Air sports, Painting, Knife making, Letterboxing, Inline skating

Introduction: My name is Saturnina Altenwerth DVM, I am a witty, perfect, combative, beautiful, determined, fancy, determined person who loves writing and wants to share my knowledge and understanding with you.