Home > Microsoft Office > Microsoft Office How To

How to lock cells in Excel – 2 simple methods

Time to protect your data!
Last Updated on May 16, 2024
The image displays the Microsoft Excel logo on a gradient blue background, with the letters "PCWer" and a small dot above it, hinting at instructions on how to lock cells in Excel.
You can trust PCWer: Our team of experts use a combination of independent consumer research, in-depth testing where appropriate - which will be flagged as such, and market analysis when recommending products, software and services. Find out how we test here.

Are you wondering how to lock cells in Excel? If so, then we’ve got you covered with two methods.

Learning how to lock cells in Excel prevents anyone from messing around with sensitive data, as it allows users to input and change only the data allowed by the workbook or spreadsheet owner. Why should anyone need to learn how to lock cells in Excel, though?

There are plenty of reasons to lock down certain cells. Perhaps the information in the spreadsheet is incredibly important and, if altered, may ruin companies’ projected targets and revenue. To help you out, we’ll go over two methods that can get the job done.

How to lock a cell using the Format button

Here’s how you can quickly lock a cell using a single button.

Step

1

Select the cells

First, open your Excel sheet and select the cell or cells you wish to lock.

Step

2

Click on Format

Now, go to the Home tab and click on Format. This can be found in the ‘Cells’ box.

Step

3

Lock the cell

From the drop-down menu that will appear, click on ‘Lock Cell.’

A screenshot of an Excel spreadsheet toolbar showing a drop-down menu with various options. The "Lock Cell" option is highlighted with a red box, demonstrating how to lock cells in Excel.
Lock cell

Once done, the cell will be locked.

How to lock cells using the Format Cells menu

Alternatively, you can use the Format Cells menu to lock the cells.

Step

1

Open the Format Cells menu

First, select all cells and right-click on them. Then, click on Format Cells.

A dropdown menu with options including Cut, Copy, Paste Options, Insert, Delete, Clear Contents, and Format Cells—highlighted with a red box—provides essential tools. Learn how to lock cells in Excel to protect your data effectively.
Format Cells

Step

2

Lock the cells

Now, go to the Protection tab and check the box next to ‘Locked.’

The "Format Cells" dialog box in Excel is open, displaying the "Protection" tab with options on how to lock cells in Excel or hide them. "Locked" is checked by default. Text explains that protection settings require worksheet protection to work.
Format Cells menu

Once done, click on OK.

Step

3

Protect the sheet

Next, right-click on your sheet and click ‘Protect Sheet.’

A context menu in a spreadsheet application is shown, with the "Protect Sheet..." option highlighted in red, guiding users on how to lock cells in Excel.
Protect Sheet option

Choose a password to unprotect sheet, check the box next to ‘Select Locked Cells,’ and click OK.

Dialog box for protecting an Excel sheet. Options to "Select locked cells" and "Select unlocked cells" are selected. Other options such as "Format cells" and "Insert rows" are unchecked. Learn how to lock cells in Excel easily with this setup.
Select Locked Cells

Conclusion

Now that you have learned how to lock cells, you can finally protect the important data in your spreadsheet. Both methods mentioned in this guide should work flawlessly, and no one will be able to mess with the information inside the cells after you make the changes.

If you want to continue learning about Excel and how its features work, give these guides a read:

Christian 'Reggie' Waits' is a contributor to PCWer, having written a wide array of how to and buying guide content.