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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
dan-stuart
Frequent Visitor

Using htmlViewer to display webpage

Hi all, 

 

I'm fairly new to Power BI and am struggling to find an answer to the following problem either here or using Google! Basically, I'm trying to use HTML viewer to embed elements of a non-static webpage in my report and then as the source is updated, the report would auto update also. Unfortunately though, it only seems to half work and I'm not sure if it's a mistake I'm making or a restriction on the use of the data. 

 

I'm trying to embed some visuals from an open data site called LG Inform (Link) and the site helpfully provides URLS/scripts that seem to allow you to achieve this (if you click the 3 horizontal line ellipsis above each visual, you can generate the relevant html code). For this example, I'm trying to pull the first two visuals i.e. the total resident population table and the total resident population graph.

 

I've imported the provided URLS (population table and population graph) into my pbi file and used the following script to derive the 'content' of my htmlViewer visualisation: "<iframe src="& [URL] & " style='width:100%; height:100%'> & </iframe>"

 

After publishing to my workspace the output appears as below i.e. the first visualisation (table) has loaded and the second (graph) has not (although seems to have tried).

 

LGInformPBI.PNG

Does anybody have any experience working with the htmlViewer visualisation and therefore some idea of what's gone wrong? I'm sure there's some key information I've left out so please let me know if there's anything else I need to explain 🙂

 

Thanks in advance for any tips.

 

Dan

1 ACCEPTED SOLUTION
v-alq-msft
Community Support
Community Support

Hi, @dan-stuart 

 

I failed to reproduce your scenario. I'd like to suggest you remove X-Frame-Options header if possible. As a workaround, you may add a hyperlink as below.

 

Best Regards

Allan

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-alq-msft
Community Support
Community Support

Hi, @dan-stuart 

 

I failed to reproduce your scenario. I'd like to suggest you remove X-Frame-Options header if possible. As a workaround, you may add a hyperlink as below.

 

Best Regards

Allan

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thanks @v-alq-msft, I appreciate your help.

 

As a fairly new user, I'm not yet familiar with things such as X-Frame-Options and edits such as this might be restricted by my organisational account (I don't have a personal Power BI account). However your workaround (add hyperlink) was successful, so I've opted to use that, thanks!

 

Dan

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.