Row-Level Security
Row-Level Security (RLS) is a database access control that limits which rows within a table a given user can see or modify, based on their identity, role, or session context. Rather than granting or denying access to an entire table, it filters the data so users only see the specific rows they are permitted to access. It is implemented within database platforms and analytics tools such as PostgreSQL, Power BI, Databricks, and CockroachDB.
Row-Level Security is an access control mechanism, typically enforced at the database or semantic-model layer, that restricts read and/or write operations to a subset of rows in a table according to policies evaluated against a user's identity, role, or session attributes. In implementations such as PostgreSQL, row security policies are applied per-table and, by default, tables have no policies so table-level access privileges otherwise govern access; in tools like Power BI, filters restrict data at the row level within a semantic model. RLS is a security control (part of confidentiality enforcement) rather than a data governance construct, and this definition does not address whether the data being restricted is personal data, nor does it cover pseudonymization, anonymization, retention, cross-border transfer, or any specific regulatory obligation. Applying RLS does not by itself render restricted data non-personal or satisfy any particular legal requirement; compliance depends on broader context and implementation.
Why it matters
Row-Level Security addresses a common gap in data access control: coarse, table-level permissions frequently grant users far more visibility than they need. Where a single table holds records belonging to many customers, business units, or tenants, granting access to the table as a whole can expose rows that a given user has no legitimate reason to see. RLS narrows access to the specific rows a user is permitted to view or modify, supporting the principle of least privilege at a finer granularity than table-level grants alone.
For organizations enforcing confidentiality, RLS is a practical control for multi-tenant systems and shared analytics environments, where the same table or semantic model serves users with different entitlements. It can help reduce the risk of inadvertent over-exposure of data within a shared store. However, RLS is a security control focused on confidentiality enforcement; it is not a data governance construct and does not, on its own, establish ownership, stewardship, data quality, or lineage.
It is important not to overstate what RLS achieves. Restricting which rows a user can access does not change the nature of the underlying data: applying RLS to personal data does not render that data non-personal, and it does not by itself satisfy any particular legal or regulatory obligation. Whether RLS is sufficient in any given deployment depends on broader context, the correctness of the policies configured, and the surrounding controls; this definition does not address retention, cross-border transfer, pseudonymization, anonymization, or specific compliance requirements.
Who it's relevant to
Inside RLS
Common questions
Answers to the questions practitioners most commonly ask about RLS.