Power BI: row-level security (RLS) and report sharing

Published · Updated · 15 min read

Dylan Arnaud, founder of Datafuji

Row-level security (RLS) is a filter in the Power BI data model: each reader sees only the rows their role allows, totals included. But an Admin, Member or Contributor of the workspace (the shared folder where the team publishes its reports) sees everything, and an export or a public link takes the data out. Most of the time, it is the sharing, not the rule, that exposes the numbers.

What is RLS in Power BI?

RLS restricts data access for specific users of a Power BI semantic model: filters, defined in roles, keep only certain rows. Everything else disappears from tables, charts, totals and exports.

The semantic model, called a dataset until late 2023, holds the tables, their relationships and the measures; reports connect to it. A role is a name and a rule: a short DAX formula that returns true or false for each row.

The filter lives in the data model, not in the pages: every report built on that model respects it. Hiding a page or a visual protects nothing: “hiding isn’t a security measure,” Microsoft writes.

Static or dynamic RLS

A static rule compares a column with a fixed value: one role per branch, simple with two, tedious with ten. A dynamic rule compares a column with the identity of the signed-in person: a single role serves every sales rep, and the permissions live in a table. Microsoft says this is the most common approach.

Static RLS:
  [Branch] = "Lyon"
Dynamic RLS:
  [Email] = USERPRINCIPALNAME ()

USERPRINCIPALNAME returns the sign-in name, which looks like an email address; USERNAME returns the same thing in the service (Power BI online), but “DOMAIN\user” in Desktop (the Windows application where reports are built). In the role editor, DAX function arguments are separated by commas, even on a computer set to a locale that normally uses semicolons, such as French.

Setting it up, in four steps

  1. Define the roles and their rules in Power BI Desktop: “Modeling” tab, “Manage roles.”
  2. Publish the model and the report to the Power BI service.
  3. Add people or groups to each role, in the service: the semantic model’s “More options” menu, then “Security.”
  4. Test: “View as” in Desktop, “Test as role” in the service.

What RLS looks like: the same report seen by three profiles

With dynamic RLS, three people who open the same report see three totals, all correct. The CEO sees the month’s 12 sales, the Lyon manager the 5 of his branch, a sales rep her 3.

The SME in our example is a fictional distributor: three branches, six sales reps, 12 sales in March 2026 for €53,700 excluding VAT. Its model chains three tables, Branches, Sales Reps and Sales; the first two hold the sign-in addresses, and therefore the permissions. The diagram shows where the filter applies.

Data model with three tables related in a chain: Branches, Sales Reps, Sales. The rule of the Branch Manager role, [ManagerEmail] = USERPRINCIPALNAME (), filters only the Branches table on the signed-in person’s address, hugo.bernard@negoce.example: the Lyon branch remains. The filter flows down the relationships to the two Lyon sales reps, Inès Petit and Tom Leroy, then to their 5 sales out of 12, i.e. €23,000; the other rows are filtered out.Data model with three tables related in a chain: Branches, Sales Reps, Sales. The rule of the Branch Manager role, [ManagerEmail] = USERPRINCIPALNAME (), filters only the Branches table on the signed-in person’s address, hugo.bernard@negoce.example: the Lyon branch remains. The filter flows down the relationships to the two Lyon sales reps, Inès Petit and Tom Leroy, then to their 5 sales out of 12, i.e. €23,000; the other rows are filtered out.
The rule filters a permissions table; the relationships carry the filter down to the sales.

The rule keeps one branch row; the model does the rest, and three roles cover the whole company.

Signed-in personRoleDAX rule, and its tableVisible rowsRevenue shown
Claire Morel, CEOManagementTRUE (), on Branches12 of 12€53,700
Hugo Bernard, Lyon branch managerBranch Manager[ManagerEmail] = USERPRINCIPALNAME (), on Branches5 of 12€23,000
Inès Petit, sales rep in LyonSales Rep[Email] = USERPRINCIPALNAME (), on Sales Reps3 of 12€16,000

Side by side, the three screens tell three stories.

Three screens of the same “March 2026 Sales” report. Claire Morel, management, sees €53,700 on 12 rows out of 12, and three branches: Nantes €17,000, Lyon €23,000, Lille €13,700. Hugo Bernard, branch manager, sees only Lyon, €23,000, on 5 rows: 7 rows and €30,700 are hidden from him. Inès Petit, sales rep, sees Lyon at €16,000, on her 3 sales: 9 rows and €37,700 are hidden from her. Neither of the last two screens shows that the report is filtered.Three screens of the same “March 2026 Sales” report. Claire Morel, management, sees €53,700 on 12 rows out of 12, and three branches: Nantes €17,000, Lyon €23,000, Lille €13,700. Hugo Bernard, branch manager, sees only Lyon, €23,000, on 5 rows: 7 rows and €30,700 are hidden from him. Inès Petit, sales rep, sees Lyon at €16,000, on her 3 sales: 9 rows and €37,700 are hidden from her. Neither of the last two screens shows that the report is filtered.
Lyon is worth €23,000 to Hugo and €16,000 to Inès: two correct numbers that will contradict each other in a meeting.

For Hugo, 7 rows and €30,700 do not exist; for Inès, 9 rows and €37,700. No visual, no total, no export contains them.

Key takeaways

  • One fix works for everyone: there is only one report, not a copy per branch.
  • A filtered total does not say it is filtered: put the scope in the visual’s title (“your sales,” “your branch”).
  • Hugo cannot benchmark his branch: Lyon accounts for 43% of sales, but for him the total is €23,000. You need a summary table that RLS does not filter, with a limit Microsoft points out: if there were only two branches, the total minus his own figure would reveal the other one’s.
  • A new hire is handled in the data: one more row in the permissions table.
  • No role usually means nothing: a reader who is not in any role generally opens an empty report.

And the FP&A analyst (contrôleur de gestion in France) who published the report? As a workspace Contributor, they see all 12 rows: that is the first limit. The same setup works for an HR dashboard, where each manager sees only their team.

Who does RLS apply to?

RLS restricts only readers: the Viewer role, or a simple read permission on the model. It does not apply to workspace Admins, Members or Contributors, nor to anyone who can edit the model.

A workspace is the shared folder in the Power BI service where a team keeps its models, reports and dashboards. It has four roles, and only one lets RLS apply.

RoleWhat it allowsRLS applies
AdminEverything, including adding or removing people (Admins included) and deleting the workspace.No
MemberAdd people with the same or a lower role, publish the app (the set of finished reports distributed to readers), share; but not remove people or change their roles.No
ContributorCreate, edit and delete content, schedule refreshes through the gateway; update the app if an Admin allows it.No
ViewerView and interact with reports.Yes

The exact rule: read permission, with or without the permission to build your own reports on the model (Build), lets RLS apply; write permission suspends it, wherever it comes from. A reader given Build to analyze the model in Excel therefore stays filtered.

The same person, Hugo Bernard, Lyon branch manager, depending on the workspace role he is given. As Admin, Member or Contributor, in orange, write permission suspends RLS: he sees all 12 rows and €53,700. As Viewer, in green, read permission lets RLS apply: he sees only the 5 Lyon sales and €23,000, the other 7 rows are grayed out. A note specifies that with Build permission, to analyze in Excel, RLS still applies.The same person, Hugo Bernard, Lyon branch manager, depending on the workspace role he is given. As Admin, Member or Contributor, in orange, write permission suspends RLS: he sees all 12 rows and €53,700. As Viewer, in green, read permission lets RLS apply: he sees only the 5 Lyon sales and €23,000, the other 7 rows are grayed out. A note specifies that with Build permission, to analyze in Excel, RLS still applies.
Hugo sees €53,700 as a Contributor and €23,000 as a Viewer: RLS filters only the Viewer.

The highest role wins: a reader added by mistake to a group of Contributors sees everything, like a branch manager made a Contributor “so he can see it.”

The workspace is the workshop, the app the storefront: those who build have a role in the workspace, those who read go through the app or a share. “My workspace,” the personal workspace, is for drafts; a user with the paid Pro license can be a member of up to 1,000 workspaces.

Other RLS limitations

All of them appear in Microsoft’s documentation.

TopicWhat Microsoft saysWhat you do
ColumnsWhoever sees a row sees all its columns.Remove the column, protect it with object-level security (OLS, which hides entire tables or columns), or keep it in a separate model.
The detail behind a totalRLS cannot show a total while hiding the rows that make it up.A separate summary table, without the detail.
Two roles for one personRoles add up: no “deny” takes precedence.One role per person, groups included.
GroupsPeople, security groups, distribution groups or mail-enabled groups; not Microsoft 365 groups.One security group per role.
Testing“Test as role” simulates the role, but with a dynamic rule it keeps your identity: it does not faithfully show what an external guest will see.Have a real reader from each role open the report.
Source permissionsIn Import mode (the data is copied into Power BI), the source’s security roles (SQL Server, for example) are not carried over.Rewrite the permissions in the model, from a permissions table.
The report itselfRLS does not decide who can open the report.Control access through the workspace, the app or sharing.

An empty report for a reader almost always means they were left out of a role or their sign-in name was mistyped. Microsoft’s test: a card that shows a USERPRINCIPALNAME () measure, viewed by the person concerned, displays the exact value to enter in the table.

When RLS is not the right answer

For two or three audiences with fixed rules, Microsoft advises one model and one workspace per audience instead. Employee-level payroll data goes in a separate model: what is not in it cannot leak from it. And shared accounts make RLS blind.

How do you share a Power BI report?

There are five ways to share a Power BI report: an app, a link, a workspace role, an external invitation or “Publish to web.” Each one opens the whole model, not just what the report displays.

As Microsoft puts it, “a report consumer’s read access isn’t restricted to the elements and data visible in the report.” RLS must therefore be in place before sharing.

MethodWhat it is forWhat to watch
An appDistribute finished reports to a team or the whole company; up to 25 audiences per app, each with its own content.An audience organizes content but does not secure data: without RLS, the reader can access the whole model.
A sharing linkShow a report to a few people. Three scopes: “People in your organization,” “Specific people,” “People with existing access.”Resharing is allowed by default, and the “organization” link works for any colleague it is forwarded to.
A workspace roleThe people who build and maintain the reports.Admin, Member and Contributor see all the data.
An external invitation (B2B)An external accountant, a client, a sister company.Must be allowed by the administrator; the guest needs a Pro or PPU license, unless you have an F64 or larger capacity (or Premium P).
“Publish to web”Public data, on a site open to everyone.Anyone on the internet can see the report and the model’s data, detail included.

Sharing with someone outside the company

External sharing goes through Microsoft Entra B2B: the person becomes a “guest” in your Microsoft Entra ID directory and signs in with their own address. Three conditions: the administrator allows invitations, and both the host and the guest have a Pro or PPU (Premium Per User) license, unless you have an F64 or larger capacity (or Premium P). The guest’s license can come from you. A capacity is reserved computing power, paid for by the company: F64 in Fabric (Microsoft’s data platform, which now includes Power BI), P in the older Premium offering.

With dynamic RLS, add the guest to the role by their address rather than through a group, and test with their real account. Their USERPRINCIPALNAME can take the “#EXT#” format instead of their address, and the rule then finds no rows.

Which license you need to share

Without an F64 or larger capacity (or Premium P), the author and every reader need a license. Pro costs €12.10 excluding VAT per user per month, PPU €20.80 excluding VAT (Microsoft’s public prices in France, checked November 3, 2026). One author and ten readers on Pro:

11 users × €12.10 excl. VAT
  = €133.10 excl. VAT per month,
  at French list prices

On an F64 or larger capacity (or Premium P), readers need no paid license, whether they come through the Viewer role, the app or a share; smaller F capacities still require Pro. The details are in the Power BI pricing guide.

Can you export data from a Power BI report?

Yes, and two features take the data out: exporting from a visual, which respects RLS but produces an unprotected file, and “Publish to web,” which makes the report public. Both can be controlled, report by report or globally.

Exporting to Excel

From a visual, a reader exports summarized data or, if allowed, underlying data: up to 150,000 rows in .xlsx, 30,000 in .csv, 500,000 in .xlsx with a live connection (the report queries a published model or Analysis Services live, with no copy of the data). Inès would export only her three sales, but the exported workbook is no longer protected.

Three steps for the same sales rep, Inès Petit. In Power BI, her visual shows her 3 sales, BTP Morin €7,500, Serrurerie Faivre €3,200 and BTP Morin €5,300, total €16,000, filtered by RLS, in green. The exported workbook contains the same 3 rows: the export respected RLS, but the file, on her computer, outside Power BI, no longer has any protection, in orange. Forwarded by email to a third party, it stays readable without a Power BI account, in orange. The audit log records the export, not the forwarding.Three steps for the same sales rep, Inès Petit. In Power BI, her visual shows her 3 sales, BTP Morin €7,500, Serrurerie Faivre €3,200 and BTP Morin €5,300, total €16,000, filtered by RLS, in green. The exported workbook contains the same 3 rows: the export respected RLS, but the file, on her computer, outside Power BI, no longer has any protection, in orange. Forwarded by email to a third party, it stays readable without a Power BI account, in orange. The audit log records the export, not the forwarding.
The export respects RLS; the exported file no longer respects anything.

The author chooses the level for each report: no export, summarized, or summarized and underlying. The administrator can turn off export for the whole company, and that setting wins.

Every view, export or share is recorded in the audit log, which the administrator reads in the Microsoft Purview portal: it shows who exported what.

Sensitivity labels

Microsoft Purview labels (“Confidential,” “Internal”…) follow the file exported to Excel, PowerPoint or PDF, with their protection, without changing who can access the report. A .csv carries none. Applying these labels requires an Azure Information Protection Premium P1 or P2 license, on top of Pro or PPU.

“Publish to web” makes a report public

With “Publish to web (public),” Microsoft warns that anyone on the internet can see the report, with no authentication, including the detailed data it aggregates. The option is not offered for a report protected by RLS, but any report without RLS can be published.

The administrator turns it on or off, or restricts it to security groups, and sees every embed code, which should be reviewed regularly. For an intranet, the secure “Embed report” options keep permissions intact.

Where is Power BI data stored, and is it protected?

The data is stored in the Azure geography assigned to your organization when it first signed up, and encrypted at rest and in transit. Accounts and sharing are what expose it.

QuestionWhat Microsoft says
Where is it?In the Azure geography set from the country chosen when the Microsoft account was created. To find it: the service’s Help pane, the “About” link, the line “Your data is stored in.”
What is copied?In Import mode, the model’s data is kept in the service. In DirectQuery, it stays in the source, which is queried each time a report is viewed, with a possible temporary cache.
Is it encrypted?At rest, by default, with Microsoft-managed keys. In transit, TLS 1.2 at minimum; earlier versions are rejected.
Who can sign in?Microsoft Entra ID accounts, that is, the company’s Microsoft 365 accounts. Passwords and multifactor authentication are therefore managed in Microsoft 365.

A stolen account opens everything it is allowed to see: encryption does not protect against a weak password, hence the recommendation on multifactor authentication from the CNIL, France’s data protection authority (April 1, 2025).

Power BI and the GDPR

What follows reports what Microsoft and the CNIL write; for your own case, ask your data protection officer.

Microsoft presents itself as a processor (it processes data on your behalf); the customer remains the controller (Data Protection Addendum, DPA). For customers based in the EU or EFTA, it commits to processing Power Platform and Microsoft 365 data within that area, with documented exceptions (the “EU Data Boundary”).

The CNIL asks for access profiles limited to the data each person needs (in Power BI: roles and RLS), approved by a manager. They should be removed as soon as a person is no longer authorized and reviewed at least once a year, and no shared account should escape monitoring.

A personal data breach, malicious or not, must be documented internally and, when there is a risk to individuals, notified to the supervisory authority within 72 hours where feasible. In France, the CNIL counted 6,167 notifications in 2025, 9.5% more than in 2024:

Type of incident, 2025 notifications in FranceShare
Hacking (hijacked legitimate account, ransomware, phishing…)50%
Personal data sent to the wrong recipient13%
Theft or loss of equipment and data7%
Unintentional publication of information7%
Other types of incident23%

Sending to the wrong recipient and unintentional publication account for 20%: points 6 to 8 of the checklist, at the end of the page, address them. These figures cover all tools; no public source puts a number on incidents specific to Power BI.

What is the Power BI gateway for?

The on-premises data gateway is Windows software installed on your network. It lets the online Power BI service refresh data it cannot reach over the internet, without opening an inbound port.

When you need one

You need one for the database of an ERP installed on your own server or files on a network drive, not when all your sources are in the cloud. For a source behind an Azure virtual network, Microsoft manages a virtual network data gateway, with nothing to install.

What it changes for network security

The gateway only makes outbound connections to Azure: the service’s requests reach it as responses to its own calls.

Two zones separated by the firewall. On the left, your network: the ERP database (SQL Server) and a network drive of Excel files, connected to the on-premises data gateway, in standard mode, on an always-on Windows server; the source credentials are encrypted there and decrypted only there; it connects with a read-only account, limited to the tables needed. On the right, the Power BI service in Azure and its semantic model with scheduled refresh. The only two arrows, green, go from the gateway to Azure: they are outbound connections. None enters the network: 0 inbound ports.Two zones separated by the firewall. On the left, your network: the ERP database (SQL Server) and a network drive of Excel files, connected to the on-premises data gateway, in standard mode, on an always-on Windows server; the source credentials are encrypted there and decrypted only there; it connects with a read-only account, limited to the tables needed. On the right, the Power BI service in Azure and its semantic model with scheduled refresh. The only two arrows, green, go from the gateway to Azure: they are outbound connections. None enters the network: 0 inbound ports.
Every connection starts from your side: no inbound port needs to be opened.

Only the gateway decrypts the source credentials: the service never sees them in clear text, Microsoft writes. Whoever is viewing the report, the gateway connects with the stored credentials (unless single sign-on is configured, or a live connection to Analysis Services is used): give it a read-only account, limited to the tables needed.

Where to install it

  • On an always-on machine with a wired connection: never a laptop or a computer that goes to sleep.
  • On Windows 10, 11 or Server 2019 to 2025, with .NET Framework 4.8; ideally 64-bit Windows Server, 8 cores, 8 GB, SSD. Never on a domain controller.
  • In standard mode, which Microsoft recommends: it serves several users; personal mode serves only one.
  • Up to date: a new version comes out every month, and only the last six are supported.

For refreshes, a Pro license alone (on capacity shared between customers) allows 8 scheduled refreshes a day, each limited to 2 hours; Premium, PPU or Fabric allow 48, with a maximum duration of 5 hours on Premium. After two months without anyone visiting a report built on the model, scheduled refresh is paused.

What happens when someone leaves the company?

Disabling a departing employee’s Microsoft Entra ID account shuts them out of Power BI. But their permissions stay recorded until the account is permanently deleted, whatever they exported stays with them, and their reports need a new owner.

The diagram separates what disabling takes care of from what it leaves behind.

In the center, Inès Petit’s account, disabled, in green: Power BI is closed to her. Around it, in orange, what remains to be handled: her access, workspace Viewer and member of the Sales Rep role, which returns if the account is re-enabled; the exported workbook, 3 sales for €16,000, on her computer, outside Power BI; any models she published, which have only one owner: a colleague must take them over. In gray, her personal workspace, deleted with the account and kept for 30 days.In the center, Inès Petit’s account, disabled, in green: Power BI is closed to her. Around it, in orange, what remains to be handled: her access, workspace Viewer and member of the Sales Rep role, which returns if the account is re-enabled; the exported workbook, 3 sales for €16,000, on her computer, outside Power BI; any models she published, which have only one owner: a colleague must take them over. In gray, her personal workspace, deleted with the account and kept for 30 days.
Disabling the account closes the door; permissions, exports and models still have to be handled one by one.
  • Their permissions: a re-enabled account gets them back, according to Microsoft; remove them from workspaces and roles.
  • What they took out: workbooks and .pbix files (Power BI reports saved on the computer) stay on their computer.
  • Their reports: a model has only one owner; to change its credentials, a colleague must first take it over.
  • Their personal workspace: deleted with the account, it is kept for only 30 days, a fixed period during which a Fabric administrator can restore it. A deleted shared workspace is kept for 7 days by default, up to 90.

Hence three precautions: no company report in a personal workspace, two Admins per workspace (without them, it becomes “orphaned”), two for the gateway.

This applies to service providers too, us included: we work with read-only access to our clients’ data, and our access is removed at the end of the project like everyone else’s.

What should you check before sharing a report?

Check ten points before every new share and whenever the circle of readers widens: five in the model and the workspace, three at the moment of sharing, two in the organization.

PointWhat must be true
1. Each reader’s roleViewer, app or share; nobody as Contributor, Member or Admin, either directly or through a group.
2. RLS in the modelRoles, not page filters; every reader in a role, and only one.
3. A test per roleA real reader from each role confirms their total; an external guest tests with their own account.
4. Sensitive columnsSalaries, purchase prices, margins by customer: removed, protected by OLS, or in a separate model.
5. Small totalsNone identifies a person; no subtraction reveals a hidden number.
6. The link’s scope“Specific people” rather than “People in your organization”; resharing unchecked unless intended.
7. The export levelChosen for this report: none, summarized, or summarized and underlying.
8. “Publish to web”Turned off or restricted to a group; existing embed codes reviewed.
9. ContinuityA shared workspace; two Admins for the workspace and for the gateway.
10. Access reviewAt least once a year, backed by the audit log, and permissions removed at every departure.

For the last two, see the data governance for SMEs guide.

Common mistakes

  • Giving a reader the Contributor role “so they can see it”: RLS stops applying to them.
  • Entering the email address when the sign-in name is different (an alias): the rule finds nothing, the report stays empty.
  • Sharing a report without RLS through an “organization” link: any colleague who receives the link can access the whole model.
  • Going back to one file per branch “to be safe”: you get back the copies and discrepancies the report was meant to eliminate.

In our SME, the three branch managers had been made Contributors “so they could see it”: all it took was switching them back to Viewer and giving them the app. Hugo once again sees his €23,000, and only that: not one character of the rule changed.

Frequently asked questions

Where do I find the Power BI service?

The Power BI service, the online part, is at app.powerbi.com, where you sign in with your company’s Microsoft account. That is where sharing, workspaces and roles are managed; reports are built in Power BI Desktop, the free Windows application.

Can I share a Power BI report without a Pro license?

Not securely: sharing requires a Pro or PPU license for the author and the readers, unless you have an F64 or larger capacity (or Premium P). The workarounds, “Publish to web” or sending the .pbix file, leave the data with no protection at all: keep them for public data.

What is the difference between RLS and OLS?

RLS filters rows: Inès sees only her sales. OLS (object-level security) hides entire tables or columns, margins for example. It is written in Desktop’s TMDL view (the model as a script) or with Tabular Editor, and a visual that touches a hidden object shows an error.

Can I share a Power BI report in Teams or SharePoint?

Yes, through a Power BI tab in Teams or the Power BI web part in SharePoint Online. RLS applies there, but embedding grants no access: each reader must have access to the report in Power BI, and a Pro or PPU (Premium Per User) license, unless you have an F64 or larger capacity (or Premium P). SharePoint does not support B2B guests.

Does RLS work with DirectQuery?

Yes, in both Import and DirectQuery mode. With single sign-on (SSO), the source receives the user’s identity and also applies its own permissions; without SSO, it sees the stored credentials, and only the model’s RLS filters. “Test as role” does not work with SSO. With a live connection to Analysis Services (the report queries the model live, with no copy of the data), RLS is set in Analysis Services.

Let’s talk about your reporting.

A 30-minute video call with Dylan Arnaud. You come away with a clear scope and a fixed price.

Dylan Arnaud, Power BI consultant and founder of Datafuji
Dylan ArnaudFounder · your single point of contact