How to lock cells in Excel

To lock one or more cells in Microsoft Excel, you must first select the cells you want to lock. Remember to use the CTRL key for non-adjacent cells:

Selected cellsSelected cells

Now, right-click on one of the selected cells, and in the context menu that appears, click Format Cell:

Cell format selectionCell format selection

There, go to the Protection tab:

Location of the Protection tabLocation of the Protection tab

In this tab, select the Locked check box so that the contents of the selected cells cannot be altered. Click on OK to apply the changes:

Checkbox to lock cellsCheckbox to lock cells

Again, locking a cell means that it is impossible to modify what is written in the cell; it is not possible to rewrite or change attributes of the cell, such as formatting.

Cell locking can be useful in situations where you are working with a large amount of sensitive data, where changing a number or a character by mistake can ruin a huge amount of working hours by changing the final result, and therefore, its interpretation. It is also locked to prevent users who do not have permission to work on a document from rewriting data. The operation can be undone, but it has to be done by the user who did it in the first place.

It is also interesting that if you are working with a document where there is sensitive information, you can lock all the document's cells and then unlock only those that can be modified without the risk of changing the final result.