Fix Power Query Cannot Recognize a Valid Excel Document in Excel 2016
Question details
The user needs to resolve Power Query errors when combining multiple Excel files from a folder in Excel 2016, specifically the error that the input cannot be recognized as a valid Excel document.

- Product
- Microsoft Excel 2016 Power Query
- Device & OS
- not provided
- Scenario
- Using Power Query in Excel 2016 to combine multiple Excel files from a folder.
- Observed behavior
- Power Query returns an error saying the input cannot be recognized as a valid Excel document, even though the selected files appear valid.
Before you change the query, confirm that every file in the source folder has a correct Excel extension such as .xlsx, and open each file manually to check for corruption. Remove temporary files such as ~$ files and move password-protected or non-Excel files out of the folder.
Check Each Source File and Remove the Problem File
Use this method first to isolate the corrupted, password-protected, or incorrectly named file that causes the recognition error.
The folder-level error often disappears after the unreadable file is moved out of the source folder. Power Query processes every file in the folder, so a single temporary or incompatible file can block the entire query.
In File Explorer, navigate to the folder you are using as the Power Query source and make sure file name extensions are visible from the View tab.
Double-click each .xlsx or .xls file to open it in Excel 2016. If a file opens, close it; if Excel reports corruption, repair or remove that file.
Move out files that start with ~$ or end with .tmp, and remove or unlock files that are password-protected or encrypted.
In Excel, go to Data > Show Queries, right-click the folder query, select Refresh Preview, or re-create the query with Data > New Query > From File > From Folder.

Use the Folder Path as the Power Query Source and Review Filters
Use this if you selected files individually or the folder source contains extra non-Excel files that interfere with recognition.
Update Excel and Power Query, Then Retest
Use this method when files are valid but Power Query still fails because of an outdated Excel 2016 or Power Query add-in.
Switch to WPS Office for Reliable Excel File Editing
If Power Query errors in Excel 2016 continue to block your work, WPS Office offers a free, lightweight alternative that opens and edits .xlsx files with a familiar ribbon interface, making it easy to continue working while you resolve the Power Query issue.

Frequently Asked Questions
Why does Power Query say the input cannot be recognized as a valid Excel document even when all files are .xlsx?
The message often means one file is corrupted, password-protected, encrypted, or has a hidden or wrong extension. Open each file manually in Excel and remove any file that does not open normally.
Can temporary Excel files cause this Power Query folder error?
Yes. Files beginning with ~$ are owner or lock files and can make folder import fail. Close all Excel workbooks and remove temporary files before refreshing the query.
How do I test which file is causing the error?
Move half the files out of the source folder and refresh the query, then repeat until the failing file is isolated. You can also open each file manually to check for corruption.
Does WPS Office include Power Query?
WPS Office does not include Microsoft Power Query, but it can open and edit .xlsx and .xls files and is useful for reviewing files when Excel Power Query cannot recognize them.
How do I update Power Query in Excel 2016?
Go to File > Account > Update Options > Update Now in Excel, or download the latest Power Query add-in from Microsoft and restart Excel.




