Locking cells in Google Sheets prevents accidental changes to data you want to protect — formula cells, header rows, summary tables, anything that shouldn't be edited by people using the sheet.
Google Sheets calls this "protected ranges." You can protect a single cell, a range, or an entire sheet.
---
Lock a Range of Cells
- Select the cells you want to protect
- Right-click and choose Protect range, or go to Data > Protect sheets and ranges
- A sidebar opens. Add a description (optional but helpful — "Header row" or "Formula cells")
- Click Set permissions
You get two options:
Show a warning when editing this range — anyone can still edit, but gets a warning popup first. Use this for cells that shouldn't normally be changed but occasionally need to be.
Restrict who can edit this range — only people you specify can edit. Everyone else sees an error if they try. Use this for formula cells, totals, and data that must stay intact.
For the restricted option, choose Only you to lock it to yourself, or add specific editors by email.
- Click Done
---
Lock an Entire Sheet Tab
To protect a whole tab:
- Right-click the tab name at the bottom
- Choose Protect sheet
- Click Set permissions
- Choose who can edit — you, specific people, or anyone
If you want to allow edits to specific cells (like a data entry column) while locking the rest of the sheet, check Except certain cells and specify which cells should remain editable.
This is useful for shared templates: lock the formulas and structure, leave the input cells unlocked.
---
The Difference Between Warning and Lock
Warning only:
- Anyone can edit
- A popup asks "Are you sure?" before the edit goes through
- The person can click "OK" and proceed
- Good for: cells that need occasional manual correction, summary rows, headers
Full lock (restricted):
- Only specified editors can change the cell
- Other users see "You are trying to edit a protected range" and cannot proceed
- Good for: formula cells, totals, any cell that must stay intact
---
How to See What's Protected
- Go to Data > Protect sheets and ranges
- All protected ranges in the spreadsheet are listed in the sidebar
- Click any protection to edit or remove it
---
Removing a Protection
- Open Data > Protect sheets and ranges
- Click the protection you want to remove
- Click the trash icon
---
Common Problems
I locked cells but I can still edit them
You're the owner of the spreadsheet. Owners can always edit protected ranges. The lock applies to other users. To test how it looks for others, share the sheet with a test account.
Someone got the warning but edited anyway
The warning mode only shows a prompt — it doesn't block editing. If you need to actually prevent changes, use the "Restrict who can edit" option instead.
I want to lock formulas but let people type in the input cells
Use "Protect sheet" with the "Except certain cells" option. Check that box and enter the cells or range that should remain editable (your input columns). The rest of the sheet is locked.
---
What to Build on Top of This
- How to Use Conditional Formatting in Google Sheets — lock the formatting after setting it up, so collaborators can't accidentally overwrite rules
- How to Create a Project Tracker in Google Sheets — lock the formula columns in your tracker while keeping the data entry columns open
- How to Create Dependent Dropdowns in Google Sheets — after building dependent dropdowns, lock the reference tables so dropdown options can't be accidentally deleted
Don't want to set this up yourself? Describe what should be locked and it'll be configured for your sheet. Get it installed