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

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.

Reply
being_human
Regular Visitor

Embed an RLS based Direct query mode power bi report's iframe link in an web application

Hello Community,

I have created a power bi report and published it my web application, now the problem is  i have to create a role based view for my dashboard i.e., when group1 manager logs in he needs to able to see only data related to his group , i have total 16 groups like this, i have seen multiple posts regarding this question but none had clear solution, I want to embed my role based , direct query mode, power bi report to be published in an web application, kindly suggest how to achive this road block.. 

5 REPLIES 5
Anonymous
Not applicable

Hi @being_human 

 

Thanks for the reply from Poojara_D12 .

 

I need to confirm the requirement with you. Do you mean the APP of Power BI Service? Then put the link of the report into the app? As shown in the figure below?

vxuxinyimsft_0-1733205899983.png

 

Best Regards,
Yulia Xu

Thank you for the reply , My web app is built on .net frame work its not an APP of Power BI Service

being_human
Regular Visitor

also @Poojara_D12  your response looks like chatgpt answer, kindly provide proper guidance for the question

Poojara_D12
Super User
Super User

Hi @being_human 

  1. Create Roles in Power BI:

    • Go to Modeling > Manage Roles in Power BI Desktop.
    • Define roles using DAX filters, e.g., [Group] = "Group1". Repeat for all 16 groups.
  2. Use Row-Level Security (RLS):

    • Publish the report to Power BI Service.
    • Assign users to roles under Security settings of the dataset.
  3. Dynamic RLS with UPN (for dynamic filtering):

    • Use USERPRINCIPALNAME() in the DAX filter to match logged-in user emails with a mapping table of groups.
  4. Embed with Role Enforcement:

    • Pass the user's Group/Email to Power BI Embedded using the embed token.
    • Use the API to enforce the corresponding RLS role.

Done! The embedded report will now filter data based on the logged-in user's group.

 

Did I answer your question? Mark my post as a solution, this will help others!

If my response(s) assisted you in any way, don't forget to drop me a "Kudos" 🙂

Kind Regards,
Poojara
Data Analyst | MSBI Developer | Power BI Consultant
Please Subscribe my YouTube for Beginners/Advance Concepts: https://youtube.com/@biconcepts?si=04iw9SYI2HN80HKS 

Did I answer your question? Mark my post as a solution, this will help others!
If my response(s) assisted you in any way, don't forget to drop me a "Kudos"

Kind Regards,
Poojara - Proud to be a Super User
Data Analyst | MSBI Developer | Power BI Consultant
Consider Subscribing my YouTube for Beginners/Advance Concepts: https://youtube.com/@biconcepts?si=04iw9SYI2HN80HKS

Can you please share any articles or vedio link regarding it, also not getting how to achive below points

  • Pass the user's Group/Email to Power BI Embedded using the embed token.
  • Use the API to enforce the corresponding RLS role.

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.