Guides / File format or extension not valid

“Excel cannot open the file because the file format or file extension is not valid”: what it means and how to fix it

Updated August 29, 2026

Excel cannot open the file 'report.xlsx' because the file format or file extension is not valid. Verify that the file has not been corrupted and that the file extension matches the format of the file.

This is Excel refusing the file at the front door. It hasn't looked at your data at all: it couldn't even recognize the container the data lives in. That distinction matters, because a container problem is very often survivable.

What the error actually means

A modern Excel file (.xlsx) is not one big blob. It's a ZIP archive holding a folder of XML files: one XML part per worksheet, one shared table for text, plus styles and bookkeeping. Before Excel opens anything, it checks that the container is a well-formed ZIP: the PK signature at the start, and a “table of contents” (the central directory) at the very end of the file.

This error fires when that check fails. In practice that means one of three things:

Before anything else: make a copy of the file and work only on copies. Every fix below is safe on a copy, and you keep the original as evidence of what you started with.

The free fixes, in order

  1. Check what the file really is. Right-click a copy and open it with Notepad (or any text editor). If it starts with PK, it really is a ZIP-based file, so skip to step 2. If you see <html or <table, it's a web export: rename the copy to .html and open it in a browser, then copy the table into a fresh workbook. If you see plain rows of comma- or tab-separated values, rename to .csv and open that. If it starts with unreadable characters beginning ÐÏ, it's an old-format .xls: rename the copy from .xlsx to .xls and try again.
  2. Use Excel's built-in Open and Repair. In Excel: File → Open → Browse, click the file once to select it, then click the small arrow on the Open button and choose Open and Repair… → Repair. If Repair fails, repeat and choose Extract Data, which abandons formatting and pulls out values and formulas only.
  3. Try LibreOffice Calc (free). LibreOffice's parser is more tolerant of damaged archives than Excel's. Install it free from libreoffice.org, open the copy, and if it loads (even partially) immediately File → Save As a new .xlsx.
  4. Try Google Sheets. Upload the copy to Google Drive, right-click it → Open with → Google Sheets. Sheets re-parses the file with its own engine and sometimes succeeds where Excel fails. Caveat: this does upload the file to Google, so skip it for confidential data.
  5. Hunt for an earlier or cleaner copy. If the file lived in OneDrive or SharePoint: right-click → Version history and restore the last good version. If it arrived by download or email, download it again. Truncated transfers are a top cause of this exact error. Also check File → Info → Manage Workbook → Recover Unsaved Workbooks in Excel, and any backup tool you run. A good copy beats any repair.

When those fail: rebuild the archive itself

Excel and LibreOffice both need the ZIP's table of contents to be readable. When it's missing or torn, they give up even though the worksheet data further up the file is often intact. FileQuiet's Excel repair works one level lower: it scans the raw bytes for each entry's local header, reconstructs the archive without trusting the table of contents, salvages worksheet rows up to the damage, and re-emits a clean workbook.

It runs entirely in your browser; the file is never uploaded, which you can verify in the network tab. You see a free preview of your actual recovered data first; if we can't show your data, there's no pay button. $12 one-time to download the rebuilt file.

Try the free preview

Honest limits: data whose bytes are truly missing or overwritten can't be recovered by anyone. Formulas come back as their last calculated values, most formatting is lost, and password-protected files are out of scope.

Frequently asked

Does this error mean my data is gone?

No. The error means Excel could not recognize the file's container and says nothing about the data inside. Renamed files, mislabeled exports and partially damaged archives all trigger it, and in those cases most or all of the cell data is usually still in the file. Data is only truly gone when the bytes that held it were overwritten or never copied.

Why does a file that opened fine yesterday suddenly show this error?

Something interrupted the last write of the file. Common causes: Excel or the computer crashed mid-save, the file was saved over a flaky network or VPN connection, a USB drive was unplugged before the write finished, or a cloud sync client uploaded a partial copy. The file on disk is now an incomplete archive, so Excel refuses it at the door.

Will renaming the file extension fix this error?

Only when the file is mislabeled rather than damaged. If a web app exported HTML or CSV and called it .xlsx, renaming it to .html or .csv (on a copy) lets the right program open it. If the file is a legacy .xls renamed to .xlsx, renaming it back works. If the archive itself is damaged, renaming changes nothing: the contents need to be repaired.

Is it safe to use an online repair tool for a confidential spreadsheet?

Most online repair services work by uploading your spreadsheet to their server, so read their privacy and retention policy before sending anything sensitive. FileQuiet takes the other approach: the repair engine is JavaScript that runs inside your browser tab, the file never leaves your machine, and you can confirm that in your browser's network tab while it runs.

Related guides