Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Join the FabCon + SQLCon recap series. Up next: Power BI, Real-Time Intelligence, IQ and AI, and Data Factory take center stage. All sessions are available on-demand after the live show. Register now

Reply
rpalexf
Regular Visitor

CORS error when viewing Published PowerBI Report

Hi,


We are planning to embed PowerBI in an Angular2 app and have started publishing reports using the "Publish to Web" function.

When we load just the published url in the browser (eg. https://app.powerbi.com/view?r=eyJrIjoiM2QwOGU3YmMtMjlkNC....) we receive CORS errors in the browser.

 

The errors displayed are purely from the PowerBI site with no extra embedding used.

"XMLHttpRequest cannot load https://wabi-south-east-asia-redirect.analysis.windows.net/powerbi/metadata/models. Request header field X-PowerBI-ResourceKey is not allowed by Access-Control-Allow-Headers in preflight response."

These also occur multiple times after the load and sometimes causes the report to crash and then reload.

 

Is this an issue with the report or configuration we are using, or is this a known issue?

 

Thanks in advance for your time,

 

Alex

1 ACCEPTED SOLUTION

@rpalexf

 

Thanks for that clarification. I can verify that the url can be accessed from China and USA.
As I don't have much knowledge on CDN, I'd suggest you submit that issue and ask MS for support.

View solution in original post

3 REPLIES 3
Eric_Zhang
Microsoft Employee
Microsoft Employee

@rpalexf

 

I don't get that error when load the published url in a brower, could you try this url?

The eg url is truncated, please post the completed one so that I can test and try to reproduce the error.

Thanks for the reponse.

 

I just tried your url in my browser and I get a CORS error in your URL.

Failed to load resource: the server responded with a status of 404 (Resource Not Found)
XMLHttpRequest cannot load https://df-msit-scus-api.analysis.windows.net/powerbi/metadata/models. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'https://msit.powerbi.com' is therefore not allowed access. The response had HTTP status code 404.
Failed to load resource: the server responded with a status of 404 (Resource Not Found)
XMLHttpRequest cannot load https://df-msit-scus-api.analysis.windows.net/powerbi/metadata/models. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'https://msit.powerbi.com' is therefore not allowed access. The response had HTTP status code 404.
Failed to load resource: the server responded with a status of 404 (Resource Not Found)

 

I work in Australia, so maybe the CDN where the JS is hosted is not a trusted site for the .com domain.

But I cant be sure.

I also tested your URL in Edge and have the same issue.

 

Here is the stack track from Chrome;

ai.0.js:1 OPTIONS https://df-msit-scus-api.analysis.windows.net/powerbi/metadata/models XMLHttpRequest.send @ ai.0.js:1(anonymous function) @ powerbiportal.dependencies.bundle.min.js:115n @ powerbiportal.dependencies.bundle.min.js:111(anonymous function) @ powerbiportal.dependencies.bundle.min.js:108(anonymous function) @ powerbiportal.dependencies.bundle.min.js:143$eval @ powerbiportal.dependencies.bundle.min.js:157$digest @ powerbiportal.dependencies.bundle.min.js:154$apply @ powerbiportal.dependencies.bundle.min.js:158(anonymous function) @ powerbiportal.dependencies.bundle.min.js:171e @ powerbiportal.dependencies.bundle.min.js:57(anonymous function) @ powerbiportal.dependencies.bundle.min.js:60
view?r=eyJrIjoiNzAyMThlZGMtOTc4NS00YWM1LTkwOWYtYjYyNzVkZjdkODg2IiwidCI6IjcyZjk4OGJmLTg2ZjEtNDFhZi05…:1 XMLHttpRequest cannot load https://df-msit-scus-api.analysis.windows.net/powerbi/metadata/models. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'https://msit.powerbi.com' is therefore not allowed access. The response had HTTP status code 404.

 

Is there anything else I can try here?

 

Thanks again for your time,

 

Alex

@rpalexf

 

Thanks for that clarification. I can verify that the url can be accessed from China and USA.
As I don't have much knowledge on CDN, I'd suggest you submit that issue and ask MS for support.

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

Check out the April 2026 Power BI update to learn about new features.

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

FabCon and SQLCon Highlights Carousel

FabCon &SQLCon Highlights

Experience the highlights from FabCon & SQLCon, available live and on-demand starting April 14th.