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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
abksharma
Helper I
Helper I

How to Auto Login Power BI HTML Static Application

How to Login automatically the PowerBI embedded using LDAP (active directory) credentials. Using Power BI JavaScript API. I am using below embed code. (Iframe embedding) I want to avoid Login button and popup. Please help.

 

 

 

url = "https://app.powerbi.com/reportEmbed?reportId=GUID&autoAuth=true&ctid=GUID"

document.write(
    "<iframe class='hero' title='Power BI Dashboard' id='myiframe'  src='"+ url +"' frameborder='0' allowFullScreen='true'></iframe>"
  )
  

 

 

 

abksharma_0-1728275127349.png

Thanks

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Thanks for the reply from lbendlin , please allow me to provide another insight:

Hi, @abksharma 

I share the same view as lbendlin and additionally recommend using a service principal for the Power BI embedded solution to “Embed for your customers”.

1.Here are the differences between “Embed for your customers” and “Embed for your organization”:

vlinyulumsft_0-1728375298826.png

“Embed for your customers” perfectly avoids the need for Power BI account authentication, making it more suitable for your needs.

For detailed information, please refer to:

https://learn.microsoft.com/en-us/power-bi/developer/embedded/embedded-analytics-power-bi#comparison...

 

2.Below are the differences between service principal and master user authentication methods:

vlinyulumsft_1-1728375298827.png

Therefore, we recommend using service principal authentication.

For detailed information, please refer to:

https://learn.microsoft.com/en-us/power-bi/developer/embedded/embed-sample-for-customers?tabs=net-co...

 

3.Please note that what you are currently using is only suitable for testing. For production use, you will need to upgrade your capacity:

vlinyulumsft_2-1728375375382.png

For detailed information, please refer to:

Capacity and SKUs in Power BI embedded analytics - Power BI | Microsoft Learn

 

4.Of course, we also provide convenient testing tools:

Power BI Playground - Explore our APIs

vlinyulumsft_3-1728375375388.png

For detailed information, please refer to:
What is the Power BI embedded analytics playground - Power BI | Microsoft Learn

 
Of course, if you have any new ideas, you are welcome to contact us.
 

Best Regards,

Leroy Lu

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

4 REPLIES 4
Anonymous
Not applicable

Thanks for the reply from lbendlin , please allow me to provide another insight:

Hi, @abksharma 

I share the same view as lbendlin and additionally recommend using a service principal for the Power BI embedded solution to “Embed for your customers”.

1.Here are the differences between “Embed for your customers” and “Embed for your organization”:

vlinyulumsft_0-1728375298826.png

“Embed for your customers” perfectly avoids the need for Power BI account authentication, making it more suitable for your needs.

For detailed information, please refer to:

https://learn.microsoft.com/en-us/power-bi/developer/embedded/embedded-analytics-power-bi#comparison...

 

2.Below are the differences between service principal and master user authentication methods:

vlinyulumsft_1-1728375298827.png

Therefore, we recommend using service principal authentication.

For detailed information, please refer to:

https://learn.microsoft.com/en-us/power-bi/developer/embedded/embed-sample-for-customers?tabs=net-co...

 

3.Please note that what you are currently using is only suitable for testing. For production use, you will need to upgrade your capacity:

vlinyulumsft_2-1728375375382.png

For detailed information, please refer to:

Capacity and SKUs in Power BI embedded analytics - Power BI | Microsoft Learn

 

4.Of course, we also provide convenient testing tools:

Power BI Playground - Explore our APIs

vlinyulumsft_3-1728375375388.png

For detailed information, please refer to:
What is the Power BI embedded analytics playground - Power BI | Microsoft Learn

 
Of course, if you have any new ideas, you are welcome to contact us.
 

Best Regards,

Leroy Lu

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

One More Question, Will RLS (row level security) work in this case or it will stop working?
Thanks in advance.

Anonymous
Not applicable

Hi,@abksharma 
Thank you for your prompt response.

 

Your question is excellent, and it has indeed been considered by our clever engineers.

 

Below are the relevant documents, which I hope you find helpful:

 Using standard cloud based row-level security with embedded content in Power BI embedded analytics -...

Of course, if you have any new ideas, you are welcome to contact us.
 

Best Regards,

Leroy Lu

lbendlin
Super User
Super User

Power BI embedded analytics overview - Power BI | Microsoft Learn

 

You would have to use the actual Embedded setup, not just the iframe.

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.