In Excel: "The file format and Extension don’t match”.

Copper Contributor

This error is coming repeatedly even, I am clicking on Yes, and the file is corrupted. How do I repair my file? Is there any solution to recover my file?

 

Adi_Star_0-1646721184128.png

 

 

23 Replies
In what version of Excel was the file created? If in version 2007 or later, was it specifically saved in Excel 97-2003 format? If not, the default file extension would be xlsx. If you upload a copy of the file, someone may be able to open it for you.
Upload the file here let someone help you check the issue Assuming the file format is originally wrong

Or rename it as . CSV and Open it

Or Rename it as .TXT and open it via Notepad if it opens, copy the content to another new excel

@Adi_Star 

Hello Adi,

I am glad to assist you; please try the below solutions to repair your file.

Solution 1: Change the default file format.

Try changing the Excel default file format by following these steps:

  • In Excel 2010 and newer versions, click on the File menu.
  • Then, in the Info screen that appears, click on Options. 
  • In the 'Excel Options' window, under the Save workbooks section, click on the Save files in this file format: drop-down. Next, select a file format (i.e., the one supported by your Excel version).
  • Click OK.

Check if you can open your Excel file. If not, try the next solution.

Solution 2: Edit the excel file permissions

Follow these steps to change the file permissions and see if it fixes the problem:

  • Right-click on the file that will not open and click Properties.
  • In the file properties dialog box, click the Security tab and hit the Edit button.
  • When the file's permissions dialog box appears, click on the Add button.
  • Next, click on the advanced button from the 'Select Users or Groups' window.
  • Select Find Now. A list of all users and groups will be displayed in a search results box. Choose everyone's group from the list and hit OK.
  • You can see the 'Everyone' group in the 'Enter the object names to select' textbox. Click OK once again to return to the file's permission dialog box.
  • Click everyone from the Group or user names: box and check all the checkboxes under Allow.
  • Click on Apply and then OK.

Now try to open the Excel file. If you are still getting the Excel file cannot open error, you can refer  to the following thread and article:

https://social.technet.microsoft.com/Forums/office/en-US/63020ccc-51d7-46d9-b956-121c0e6efcc8/excel-...

https://www.stellarinfo.com/article/excel-cannot-open-the-file-because-the-extension-is-not-valid.ph... 

hi,
are you facing this problem with all files or specifically with this one,
i m with donald genes, upload your file or mail so to fix this problem

@Adi_Star I'm actually having this error now that I have upgraded to the latest version of Office 2013. I have actually figured out that if I shorten the filename by 4 characters the error goes away. The strange thing is the path and file name are less than 100 characters so it can't be path limit. Office version 15.5459.1000 does not give the error and Office version 15.0.5475.1001 does give the error.  If I move the file back one folder in the path it will open without the error but the path and filename are only about 85 characters total. Strange!

You are right! My Office version is 15.0.5475.1000 which gives the same error. Shorten the filename for more than 20 characters does not give the error. Path and filename have less than 75 characters. It's a really strange error!

@JavaLuigi This is caused by KB5002242, and happens when opening Excel files saved on a shared drive (or other UNC path), where the total length of the path and file name exceed about 90 characters. The normal maximum length is 218 characters. Uninstalling KB5002242 is a temporary fix for getting rid of the error message.

This is caused by KB5002242, and happens when opening Excel files saved on a shared drive (or other UNC path), where the total length of the path and file name exceed about 90 characters. The normal maximum length is 218 characters. Uninstalling KB5002242 is a temporary fix for getting rid of the error message.

@JavaLuigi Thank you for the confirmation. Glad to find someone else with the issue. I hope someone takes notice and they fix it soon. In my case the file is a master document index that has a shortcut on the desktop of all users. I would rather not have to change the path or filename especially since it is part of the quality system in our company.

Thank you for the information. I hope they just fix it in the next office update since that is what appears to have actually broke it in the first place.

@MikeRabeThank you for your information. Yes, hopefully they will fix it asap. In between we will answer the Excel question with yes. But this can only be a temporary solution. You are right the limit is exactly 90 characters (UNC path and filename).

@Doug_Robbins_Word_MVP 

Hi dear Mr. Robbins. I also have faced with this problems. could u plz guide me? the original file created in excel 97-2003 in a laboratory computer. 

thanks a lot 

hakimi

Hi

I am having a similar problem and some people on the thread mentioned to upload the file onto here to get help. How do i do that? 

Thanks in advance. 

@VijayUK When you click on Reply, use the "Drag and drop here or browse for files to attach" facility to select the file that you want to upload

 

Doug_Robbins_Word_MVP_0-1695856696957.png

 

@VijayUK 

Hi

I am having a similar problem. Have you already solved this problem? If you have, could you please help me? 

Thanks in advance. 

@April_han If you upload a copy of the file, we can investigate the problem.

I have the same problem in one of my files. I want to upload a copy of my excel file (all my files have .xls extension since i use 97-2003 version of excel), but I don't know how to upload a copy of my file. Please let me know if you can help. Thanks.

@wiser2013yahoocom When you click on Reply, you will see the facility outlined in Red that can be used to upload your file(s)

Doug_Robbins_Word_MVP_0-1706260078193.png

 

@Doug_Robbins_Word_MVP 

 

I permanently deleted an excel spreadsheet and since recovering the file it wont open due to it being created on an older version of excel. Can you change the format for me please. I've tried with no success.