- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

The input couldn't be recognized as a valid Excel document
Hello everyone. Long time lurker, first time poster.
I'm working with another department on getting some of their data into PowerBI from excel spreadsheets. When I load the file to PowerBI I get a simple yet very frustrating error message of...
The input couldn't be recognized as a valid Excel document
Now this is a very complex spreadsheet with multiple tabs and lots of data. Any commonly known issues that would prompt this error?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

One of the reason could be that the data that you are importing to PBI is not in excel table. Select the rows and columns from the sheet that you want to import >> Insert Table in excel and try importing it should be able to read the data then .
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Please use the Issues Forum for reporting bugs or issues like this one. Link: http://aka.ms/issues.powerbi.com
This Community Forum is aimed at allowing users to interact/share solutions or questions for how to achieve something with Power BI, rather than reporting specific bugs (we have a whole separate forum for that :))
When reporting the issue, it would be good to clarify whether you're using PowerBI.com directly or are using Power BI Desktop to import your Excel Workbook. If you're using Power BI Desktop, any spreadsheet data is supported (does not need to be a table), so if you're running into this issue there, chances are that the Excel document has some invalid parts that make it unrecognizable.
Thanks,
M.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Actually I don't think it is a bug. The user that supplied the excel spreadsheet had hidden the tabs that had the actual data. So technically PowerBI was correct. Might want to wait to hear back from the user before closing out and not getting all the information.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

After I installed the Aug 15, 2018 release of Power BI I experienced this issue with a couple of Excel files. I have recreated these files as Excel tables (no formulas, no formatting) and I was able to refresh the files successfully.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Hy,
I had this problem myself.
After deleting sheet by sheet, I found out that the Power BI/ Q can load the excel.
After deleting row by row in the problem sheets, I found out that the Power BI/ Q gave this error,
when there were Active hyperlinks in cells.
After removing hyperlinks the xlsx just loaded.
So if you store www.google.com in a cell it's working.
But when the www.google.com is an active hyperlink (clickable, blue underlined text, which goes to specified address) it says:
Unable to connect
We encountered an error while trying to connect.
Details: "The input couldn't be recognized as a valid Excel document."
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Please use the Issues Forum for reporting bugs or issues like this one. Link: http://aka.ms/issues.powerbi.com
This Community Forum is aimed at allowing users to interact/share solutions or questions for how to achieve something with Power BI, rather than reporting specific bugs (we have a whole separate forum for that :))
When reporting the issue, it would be good to clarify whether you're using PowerBI.com directly or are using Power BI Desktop to import your Excel Workbook. If you're using Power BI Desktop, any spreadsheet data is supported (does not need to be a table), so if you're running into this issue there, chances are that the Excel document has some invalid parts that make it unrecognizable.
Thanks,
M.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Actually I don't think it is a bug. The user that supplied the excel spreadsheet had hidden the tabs that had the actual data. So technically PowerBI was correct. Might want to wait to hear back from the user before closing out and not getting all the information.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

One of the reason could be that the data that you are importing to PBI is not in excel table. Select the rows and columns from the sheet that you want to import >> Insert Table in excel and try importing it should be able to read the data then .
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

This isn't really a good solution for .xslx files that are already set tables. I have many files that a very simple tables. The nuance is that this file is being generated by a third party program (R) and the workaround is opening the file manually and saving it. No changes to the table/format etc. We want to automate this process but it's going to be a huge headache with no long term solution in place.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Have you found a solution to this ? I have the exact same issue.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Yes the best solution is running Powershell script and automated it through SQL Agent on a server or automating via window scheduler if on your personal computer. If you are running several files you can use the following two files
Config file
{
"LogFile" : "OpenSaveExcel.log",
"Files":
[
"C:\Program Files\test1.xlsx",
"C:\Program Files\test2.xlsx",
"C:\Program Files\test3.xlsx"
]
}
Powershell script:
$config = Get-Content 'config.json' | Out-String | ConvertFrom-Json
$fileList = $config.Files
$logFile = $config.LogFile
function WriteLog
{
param ([string]$logString)
Write-Host $logString
Add-content $logFile -value $logString
}
$excelComObject = New-Object -COM "Excel.Application"
$excelComObject.DisplayAlerts = $false
foreach ($file in $fileList) {
$timeStamp = (Get-Date).toString("yyyy/MM/dd HH:mm:ss")
WriteLog "$timeStamp Processing file $file"
try {
$fileHandle = Get-Item -Path $file -erroraction stop
$fileHandle.IsReadOnly = $false
$wb = $excelComObject.Workbooks.Open($file, $true, $false)
$wb.Save()
$wb.Close()
} catch {
WriteLog "$timeStamp Error: $_"
}
WriteLog "$timeStamp Done processing file $file"
}
$excelComObject.Quit()
[System.Runtime.Interopservices.Marshal]::ReleaseComObject($excelComObject)
Remove-Variable excelComObject
This creates a error log and also runs the command to open the file, save, then closes the file.
Risks are permission issues if running on a virtual machine or server you may need to adjust for that when running remotely.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

I put all my data in tables. It still does not work.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Hy,
I had this problem myself.
After deleting sheet by sheet, I found out that the Power BI/ Q can load the excel.
After deleting row by row in the problem sheets, I found out that the Power BI/ Q gave this error,
when there were Active hyperlinks in cells.
After removing hyperlinks the xlsx just loaded.
So if you store www.google.com in a cell it's working.
But when the www.google.com is an active hyperlink (clickable, blue underlined text, which goes to specified address) it says:
Unable to connect
We encountered an error while trying to connect.
Details: "The input couldn't be recognized as a valid Excel document."
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Hi,
I am facing the same issue as above, However i am copying the whole file and paste it as value.
However its giving me sam error.
Kinldy suggest!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

This problem arises when the Excel workbooks have cells with malformed URLs.
As a workaround, you can create an environment variable named "PQ_DisableNet45Containers", with a value of "true".
We are working on a fix that we hope to include in the September release of Power BI Desktop.
Sorry for the incovenience this is causing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Will this be fixed for Power Query in Excel too, that's where I'm having the error and where most will too.
@SidJay wrote:This problem arises when the Excel workbooks have cells with malformed URLs.
As a workaround, you can create an environment variable named "PQ_DisableNet45Containers", with a value of "true".
We are working on a fix that we hope to include in the September release of Power BI Desktop.
Sorry for the incovenience this is causing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

We believe this should have been addressed in all Power Query hosts.
Which version of Excel are you currently using? Which version of Power Query does that version of Excel currently have (available via Get Data -> Query Options -> Diagnostics).
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Just updated an hour ago and am still getting the error message (which only pops up when loading a table that's an append of multiple tables that all load just fine otherwise)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

I was having the same issue - the workbooks were very simple but I believe the issue was probably caused by malformed urls as previously mentioned.
However, after downloading version 2.62.5222.761 published Sep 18, I found everything to be working. 64-bit version in case that matters.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

@tkr_office Thanks for sharing this. This was the cause of the issue for me as well. At least the fix was easy!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Just had the same problem, but our data was already in the table format.
Oddly enough, changing it back to a standard data range ended up fixing it for us.
An alternate solution for anyone else getting stuck with this.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Spot on, just ran into this today, that was the cause for my error. Appreciate the response.

Helpful resources
Join us at the Microsoft Fabric Community Conference
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Power BI Monthly Update - February 2025
Check out the February 2025 Power BI update to learn about new features.

Subject | Author | Posted | |
---|---|---|---|
11-01-2024 05:50 AM | |||
02-28-2017 01:24 PM | |||
07-20-2024 01:28 AM | |||
01-09-2025 11:43 PM | |||
02-11-2025 01:10 AM |
User | Count |
---|---|
27 | |
25 | |
25 | |
13 | |
9 |
User | Count |
---|---|
24 | |
19 | |
16 | |
13 | |
10 |