Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
I'm having a problem rendering reports with custom visuals using the JavaScript API. The report is hosted in the Power BI service, rather than Power BI Embedded.
The rest of the report renders fine. Custom visuals however do not appear and I get a 401 error:
I then open the same report from within in the Power BI service and then refresh it. Then when I return to my page with the embedded report, and refresh it, everything renders successfully.
Please could someone help?
Thanks
James
Discovered smth else. When you first open your visual in powerbi.com (visual cashed) and then open same visual through javascript api, then this rendering problem does not occure. If u clear cache and try to open your custom visual again then visual is not rendered. You get bunch of unauthorized errors.
Seems , that this problem occures when using PowerBI.com(url="https://app.powerbi.com/reportEmbed").
When uploading power bi visual solution to Azure (Power BI Embedded (Azure) url="https://embedded.powerbi.com/appTokenReportEmbed"))
, then these error do not appear and visual is loaded. strange ...
What is the custom visual in your case? At the moment I post, the custom visuals such as Pyramid 3D Chart, Tachometer can be rendered well when embeded.
It affects a number of bespoke custom visuals created using the Custom Visuals API.
I'm not suprised custom visuals from the gallery render correctly as aren't these whitelisted in the service and treated differently?
this problem occurs with every custom visual. u can try with Liquid Fill Gauge, download it from visual gallery
Yesterday (some other day, too) I had the same problem with a custom R visual.
Sometimes it works with a browser but doesn't with a different one. Now it's working with both Chrome and Firefox but not in Edge (HTTP401: access denied)
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 3 | |
| 3 | |
| 2 | |
| 2 | |
| 1 |
| User | Count |
|---|---|
| 5 | |
| 5 | |
| 4 | |
| 3 | |
| 3 |