Technical Anshu
Tutorials Blog
Excel Fix Guide

Remove Sheet Protection From Your Own Excel File the XML Inside Every XLSX

A forgotten sheet password feels like a locked door, but on a modern .xlsx file there is no door. The file is a ZIP archive of XML parts, and sheet protection is a single element written inside one of them. Delete that element from a copy of your own file, and Excel opens it unprotected, with every formula and value intact.

By Technical AnshuMicrosoft Excel8 minute read
Watch the full video: the Excel password recovery from this video, shown step by step

This guide works because of how a modern Excel file is built. An .xlsx file is not a solid block of data; it is a ZIP container holding XML documents, one per sheet, plus shared parts. When you protect a sheet, Excel does not scramble anything. It writes a sheetProtection element into that sheet's XML, and on opening, Excel reads the element and enforces it. Remove the element and there is nothing left to enforce. The steps below do exactly that, on a copy, so your original stays untouched whatever happens.

Inside xl/worksheets/sheet1.xml (recreated, shortened)
<worksheet ...> <sheetViews>...</sheetViews> <sheetFormatPr .../> <sheetProtection algorithmName="SHA-512" hashValue="..." saltValue="..." spinCount="100000" sheet="1" objects="1" scenarios="1"/> <sheetData> ... your rows, values and formulas ... </sheetData> </worksheet> The sheetProtection element is the whole lock. Delete that one element, re-zip, and the sheet opens unprotected.
What sheet protection physically is inside an .xlsx file: one XML element sitting above your untouched data. The hash inside it is checked by Excel, but the data itself was never encrypted.
Ethics first: every method in this guide is for files that are yours, or files you are formally authorised to open. Removing or guessing the password of someone else's file without permission is not a favour, it can be a crime and a sackable offence at work.
1

Why This Works: The Lock Is a Note, Not a Safe

Sheet protection was designed to prevent accidents, and its design shows it. Excel stores a hashed password inside the sheet's XML and checks what you type against that hash when you click Unprotect Sheet. But the cell values and formulas sit in the same file in plain, readable XML. Nothing about the protection touches them. That is why the honest description of sheet protection is a do not edit sign, and why removing the sign from your own file is quick, complete and safe for the data.

The same design covers workbook structure protection, which lives as a workbookProtection element in the file xl/workbook.xml. If your problem is that sheets cannot be added, deleted or renamed, that is the element to remove instead, using the same routine.

2

The Steps, on a Copy of Your File

Do every step on a duplicate. Keep the original exactly as it is until the unprotected copy has been opened and checked.

  1. Copy the file and work only on the copy, for example Report - Copy.xlsx.
  2. Change the copy's extension from .xlsx to .zip, then open it with Windows Explorer or a tool like 7-Zip.
  3. Go into the folder xl, then worksheets. Each sheet is a file like sheet1.xml. Open the one for the protected sheet in a text editor such as Notepad.
  4. Find the element that starts with <sheetProtection and delete the whole element, from its opening bracket to its closing />.
  5. Save the XML, put it back into the ZIP in exactly the same place, and change the extension back to .xlsx.
  6. Open the file in Excel. The sheet is now unprotected. Check the values and a few formulas before you trust it, then keep the original untouched as your fallback.
3

The Mistakes That Make Excel Complain

Two errors cause almost every failure. The first is zipping the wrong level: if you extract everything and then zip the outer folder, the archive contains a folder inside it instead of the parts at the top level, and Excel reports the file as corrupt. The parts, including the xl folder and [Content_Types].xml, must sit at the root of the ZIP. Editing the XML inside the archive with 7-Zip avoids the problem entirely, because the structure never changes. The second error is a text editor that saves the XML with extra formatting or a changed encoding. Use a plain editor, change nothing except deleting the element, and save.

If Excel still offers to repair the file, do not save the repaired version over anything. Go back to the untouched original, make a fresh copy, and redo the edit more carefully. This is exactly why the copy-first rule exists.

4

What This Does Not Do

Honesty matters here. This routine removes protection: sheet protection and workbook structure protection. It does nothing at all for a file that asks for a password before opening, because that file is encrypted and its XML is not sitting there to edit. If you rename an encrypted .xlsx to .zip, you will not find readable worksheets inside at all. That is a different problem with a different, harder answer, covered in the guide on forgotten file-open passwords. Also note the legacy format: an old .xls file is not a ZIP. Open it in Excel and save it as .xlsx first, then use this routine on the converted copy.

Watch the Recovery in the Video

The video shows this recovery on a real file, step by step, including which password type it works on.

Watch Full Video
Frequently Asked Questions

Will removing the sheetProtection element damage my formulas or data?

No, when done carefully. The element contains only protection settings and the password hash. Your rows, values and formulas live in a separate part of the same XML and are not touched. The real risks are structural: zipping the folder at the wrong level, or an editor mangling the XML. Work on a copy, and verify the result by opening it and checking a few known values before relying on it.

Excel says the file is corrupt after my edit. What went wrong?

Almost always the ZIP structure. When the parts were re-zipped, a folder ended up inside the archive, so Excel finds a folder where it expects the file parts at the root. The fix is to start again from the untouched original and either zip the contents at the correct level or edit the XML in place inside the archive with a tool like 7-Zip, which never disturbs the structure.

Can I use the same trick on a file that asks for a password to open?

No. A file with an open password is encrypted; its contents are scrambled bytes, and there is no readable XML and no protection element to remove. The ZIP test is actually a quick way to tell the two locks apart: if you can browse worksheets inside the ZIP, it was protection. If you cannot, it is encryption, and only guessing the password can help.

This guide is based on the Technical Anshu video on Excel password recovery. Stuck on a step? Ask in the video comments and you will get a reply.