Fix 'Excel cannot open the file' error for .xlsx files

Software – Microsoft Office Intermediate 👁 0 views 📅 May 25, 2026

When Excel fails to open an .xlsx file, it's often due to file corruption, blocked content, or compatibility issues. This guide provides step-by-step fixes including repair, safe mode, and recovery options.

Symptoms

When attempting to open an .xlsx file in Microsoft Excel, you may encounter one of the following error messages:

  • "Excel cannot open the file 'filename.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."
  • "Excel found unreadable content in 'filename.xlsx'. Do you want to recover the contents of the workbook?"
  • The file opens as a blank workbook or with garbled data.
  • Excel freezes or crashes when trying to open the file.

Root Causes

The issue typically arises from one or more of the following:

1. File Corruption

The .xlsx file may be partially damaged due to improper saving, network interruptions, or disk errors. This is the most common cause.

2. Blocked File from Internet

Files downloaded from the internet or received via email may be marked as unsafe by Windows, preventing Excel from opening them.

3. Incorrect File Extension

If the file extension does not match the actual file format (e.g., a .csv file renamed to .xlsx), Excel will reject it.

4. Add-in Conflicts

Third-party add-ins or outdated COM add-ins can interfere with Excel's ability to open files.

5. Excel or Office Corruption

Damaged Excel installation files or missing updates may cause opening failures.

Step-by-Step Fix

Step 1: Unblock the File

  1. Right-click the .xlsx file in File Explorer and select Properties.
  2. On the General tab, look for a Security section at the bottom.
  3. Check the Unblock checkbox if present, then click Apply and OK.
  4. Try opening the file again.

Step 2: Open in Safe Mode

  1. Press Win + R, type excel /safe, and press Enter.
  2. In Safe Mode, go to File > Open and select the problematic file.
  3. If it opens, disable add-ins: File > Options > Add-ins. At the bottom, set Manage to COM Add-ins and click Go. Uncheck all add-ins and restart Excel normally.

Step 3: Repair the File Using Excel's Built-in Tool

  1. Open Excel (a blank workbook).
  2. Go to File > Open > Browse.
  3. Select the corrupted .xlsx file, but do not double-click it. Instead, click the arrow next to the Open button and choose Open and Repair.
  4. In the dialog, select Repair to attempt recovery. If that fails, try Extract Data to retrieve values and formulas.

Step 4: Recover Data with Open XML SDK or Third-Party Tools

  1. If built-in repair fails, use a tool like DataNumen Excel Repair or SysTools Excel Recovery.
  2. Alternatively, change the file extension from .xlsx to .zip (ensure file extensions are visible in File Explorer).
  3. Extract the ZIP folder and navigate to xl > sharedStrings.xml or worksheets folder to retrieve raw data. This is an advanced step.

Step 5: Repair Office Installation

  1. Go to Settings > Apps > Microsoft Office (or Microsoft 365).
  2. Click Modify and choose Quick Repair. If that doesn't work, select Online Repair.
  3. Restart your computer and try opening the file.

Alternative Fixes

  • Use a different version of Excel: Try opening the file in Excel Online (free) or Google Sheets to see if the file is accessible.
  • Copy to a new workbook: If you can open the file partially, copy all data to a new workbook and save.
  • Disable hardware acceleration: Go to File > Options > Advanced > under Display, check Disable hardware graphics acceleration.
  • Update Excel and Windows: Install the latest updates for Office and Windows.

Prevention

  • Save frequently and enable AutoSave if using OneDrive or SharePoint.
  • Use file versioning in cloud storage to revert to earlier versions.
  • Avoid abrupt shutdowns while Excel is running.
  • Scan for viruses regularly to prevent file corruption.
  • Keep Office updated to benefit from bug fixes.
  • Export critical files as PDF for archival purposes.

By following these steps, you should be able to recover your data and prevent future occurrences. If the problem persists, consider contacting Microsoft Support or a data recovery specialist.

Was this solution helpful?