RBAC vs ABAC vs ReBAC: Which Access Control Model Fits?
RBAC grants access by role, ABAC by attributes, ReBAC by relationships. How each works in a SaaS app, how they combine, and which providers support them.
Leonard Hußke••12 min read

On this page
- One question, three answers
- Role-based access control gives permissions through roles
- Attribute-based access control checks attributes at request time
- Relationship-based access control follows relationships, like Google Zanzibar
- RBAC vs ABAC vs ReBAC compared
- Most apps combine the models
- Fine-grained authorization runs in OpenFGA, Cedar, OPA, or Ory Keto
- Which auth providers support roles and fine-grained authorization
- Pick the model by what your app shares
- FAQ
RBAC vs ABAC comes down to what the access check looks at. Role-based access control (RBAC) looks at the user's role. Attribute-based access control (ABAC) looks at attributes of the user, the resource, and the request. Relationship-based access control (ReBAC) looks at how the user is connected to the resource, through teams, folders, and sharing. Start with RBAC. Add ReBAC once users share individual documents or projects with each other. Add ABAC conditions when the answer depends on context, such as the user's department, the document's status, or whether the user signed in with MFA.
- RBAC gives each user one or more roles, and each role carries a set of permissions. NIST formalized it in 1992, and it became an American National Standard in 2004.
- ABAC evaluates policies against attributes at request time. NIST described it in SP 800-162 in 2014. XACML and Cedar are policy languages for it.
- ReBAC stores relationships such as "Maria is a member of Marketing" and "Marketing can edit this folder", then follows them. Google's Zanzibar paper from 2019 made it popular, and OpenFGA is an open-source system built on it.
- 31 of the 37 auth providers in our directory support role management. Fine-grained authorization is rarer. We found it in eight providers' docs, often as a separate service.
One question, three answers
All three models answer the same question: may this user perform this action on this resource? They differ in the data they use to answer it.
Take a SaaS app for documents. Each customer has a workspace. A workspace has teams, teams own folders, and folders hold documents. Maria works in marketing and wants to edit the document "Q3 roadmap" in the folder "Campaigns".
- RBAC checks that Maria has the Editor role in the workspace, and that Editors may edit documents.
- ABAC checks a policy against attributes. Maria's department is Marketing, the document belongs to Marketing, the document is not archived, and Maria signed in with MFA.
- ReBAC follows a path. Maria is a member of the Marketing team, the team can edit the Campaigns folder, and the folder contains the Q3 roadmap.

All three say yes, but they mean different things. The RBAC answer lets Maria edit every document in the workspace. The ABAC and ReBAC answers apply to this one document.
Role-based access control gives permissions through roles
In RBAC, you never give permissions to users directly. You define roles, give each role a set of permissions, and assign roles to users. Auth0's docs describe a role as "a collection of permissions that you can apply to users".
RBAC is the oldest of the three models in its current form. NIST says that RBAC was "formalized in 1992 by David Ferraiolo and Rick Kuhn". The NIST model became American National Standard 359-2004, and INCITS revised it in 2012. A 2010 economic study for NIST found that most users in enterprises with 500 or more employees were already using RBAC. The study estimated that NIST's RBAC research had saved industry $1.1 billion.
The standard has four components. NIST's FAQ says that "Core RBAC is required in any RBAC system". The other three are optional.
- Core RBAC. Users get roles, and roles get permissions. A user can hold several roles.
- Hierarchical RBAC. Roles inherit from other roles. An Admin has every permission of an Editor, plus more.
- Static separation of duty. Some roles exclude each other at assignment. The same person can't hold both "submit expense" and "approve expense".
- Dynamic separation of duty. Some roles exclude each other within one session. A user may hold both roles but can't activate both at once.
For the document app, the roles might look like this:
| Permission | Owner | Admin | Editor | Viewer |
|---|---|---|---|---|
| View documents | Yes | Yes | Yes | Yes |
| Create and edit documents | Yes | Yes | Yes | No |
| Invite members | Yes | Yes | No | No |
| Manage billing | Yes | No | No | No |
| Delete the workspace | Yes | No | No | No |
RBAC is easy to explain to customers, and auth providers can carry it in the token. Auth0, for example, has a setting that adds all of the user's permissions to the access token. Your API then checks a permission such as edit:documents without a database call.
RBAC fails when access depends on the resource. "Maria can edit the Q3 roadmap but not the budget" is not a role. Teams then create roles such as "Editor of Campaigns folder" for each case, and the number of roles grows with the number of resources. This problem is called role explosion. It is a common reason to add ReBAC or ABAC.
Attribute-based access control checks attributes at request time
NIST's ABAC guide, SP 800-162, defines ABAC as a method where the system evaluates "attributes associated with the subject, object, requested operations, and, in some cases, environment conditions" against policy. NIST published the guide in January 2014.
An ABAC policy for the document app could say that users may edit documents of their own department, only after MFA, and never once a document is archived. Here is that policy in Cedar, the policy language that AWS released as open source in 2023:
permit (
principal,
action == Action::"edit",
resource
)
when {
principal.department == resource.department &&
context.authentication.usedMFA
}
unless {
resource.archived
};
Cedar denies everything by default. Its docs say that an explicit deny "always overrides any Allow from other policies". A forbid policy, for example for documents under legal hold, wins over any permit.
ABAC has an older standard too. OASIS approved XACML 3.0, an XML policy language, on 22 January 2013. XACML named the parts that most authorization systems still use:
- The policy decision point (PDP) evaluates policy and returns a decision.
- The policy enforcement point (PEP) is your API or app. It asks the PDP and enforces the answer.
- The policy information point (PIP) supplies attribute values, such as the user's department.
- The policy administration point (PAP) is where people write and manage policies.
ABAC handles context that the other models can't: time of day, IP range, device posture, the customer's plan, or a risk score from your auth provider. The cost is visibility. A policy decides at request time, so "who can open this document?" has no stored answer. You find out by evaluating the policy for each user. ABAC also depends on clean attribute data. A wrong department field grants the wrong access.
Relationship-based access control follows relationships, like Google Zanzibar
ReBAC stores facts of the form "user, relation, object" and derives permissions from them. Google described its system in the paper Zanzibar: Google's Consistent, Global Authorization System at USENIX ATC 2019. Zanzibar stores "trillions of access control lists" and handles "millions of authorization requests per second" for services including Calendar, Cloud, Drive, Maps, Photos, and YouTube. Over three years in production, it kept 95th-percentile latency under 10 milliseconds and availability above 99.999%.
OpenFGA is an open-source authorization system for this model. It describes itself as "Inspired by Google's Zanzibar". A group of Okta employees built it, and it is the base of Auth0's commercial Auth0 FGA. The CNCF accepted OpenFGA in September 2022 and moved it to the Incubating level in October 2025.
The document app's model in OpenFGA's modeling language looks like this:
model
schema 1.1
type user
type team
relations
define member: [user]
type folder
relations
define editor: [user, team#member]
define viewer: [user, team#member] or editor
type document
relations
define parent: [folder]
define owner: [user]
define editor: [user, team#member] or owner or editor from parent
define viewer: [user, team#member] or editor or viewer from parent
Your app writes a relationship tuple whenever something changes in the app. Three tuples describe Maria's case:
| User | Relation | Object |
|---|---|---|
user:maria | member | team:marketing |
team:marketing#member | editor | folder:campaigns |
folder:campaigns | parent | document:q3-roadmap |
A check for user:maria, editor, document:q3-roadmap returns { "allowed": true }. Nobody wrote a rule for Maria and the roadmap. The model derives it from team membership and the folder.
ReBAC fits apps where users share things: documents, projects, repositories, or customer accounts with nested teams. Stored tuples also answer the audit question that ABAC can't. OpenFGA's ListUsers endpoint lists the users with a relation to an object, and ListObjects lists the objects a user can reach.
The cost is synchronization. Every time your app creates a folder, moves a document, or changes a team, it must write the matching tuple. A tuple that is missing or out of date denies access that should exist, or keeps access that should be gone.
RBAC vs ABAC vs ReBAC compared
| RBAC | ABAC | ReBAC | |
|---|---|---|---|
| Decides by | The user's roles | Attributes of the user, the resource, the action, and the context | Relationships between users and objects |
| Example rule | Editors can edit documents | Users can edit documents of their own department after MFA | Members of a team that edits a folder can edit its documents |
| Reference | NIST RBAC model, INCITS 359 | NIST SP 800-162, XACML 3.0 | Google Zanzibar paper, 2019 |
| Open-source engines | Built into most auth providers | Cedar, OPA, Keycloak | OpenFGA, Ory Keto |
| Access to a single document | No | Yes | Yes |
| Inherited access through folders and teams | No | No | Yes |
| Uses request context such as time, IP, or MFA | No | Yes | With conditions in OpenFGA |
| Stored answer to "who can see this?" | Yes | No | Yes |
| Typical problem | Role explosion | Policies that are hard to audit | Keeping tuples in sync with the app |
| Fits | Admin areas, internal tools, B2B apps with a few fixed roles | Regulated data, rules that depend on context | Collaboration and sharing, nested resources |
Most apps combine the models
The three models are not alternatives in practice. OpenFGA, Cedar, and Keycloak each support more than one of them.
- ReBAC can express RBAC. A role is a relation between a user and an organization. OpenFGA's docs say that ReBAC "allows developers to easily implement Role-Based Access Control".
- ReBAC can add attributes. OpenFGA has conditional relationship tuples. A condition is an expression in Google's Common Expression Language (CEL), and the tuple counts only when the condition is true. You can use one to grant access only before an expiry date, for example.
- ABAC engines handle roles. Cedar's docs name RBAC and ABAC as the models it supports. A Cedar policy can check
principal in Group::"editors"and an attribute in the same rule.
A common setup for a B2B SaaS app has three layers.
- Roles from your auth provider. Each organization gets roles such as Admin and Member. The provider puts them into the access token, and your API rejects requests that lack the basic permission.
- Relationships in an FGA service. Sharing, team folders, and per-document access live in OpenFGA or a hosted version of it.
- Conditions where context matters. Rules such as "only from the customer's IP range" or "not after the contract ends" go into conditions or Cedar policies.
The OpenID Foundation approved the AuthZEN Authorization API 1.0 as a final specification in January 2026. The API defines how a policy enforcement point asks a policy decision point for a decision. A request has a subject, an action, a resource, and an optional context. If your engine supports AuthZEN, you can replace it later without rewriting the checks in your app.
Fine-grained authorization runs in OpenFGA, Cedar, OPA, or Ory Keto
Fine-grained authorization (FGA) means access decisions per resource instead of per role. Engines for it run next to your auth provider, not inside it. They take the user's identity from the token your provider issues, so any of them works with any provider.
| Engine | Model | Policy format | Origin | License | Status |
|---|---|---|---|---|---|
| OpenFGA | ReBAC, with conditions | Modeling language and relationship tuples | Okta, based on Zanzibar | Apache 2.0 | CNCF Incubating since 2025 |
| Ory Keto | ReBAC | Ory Permission Language, a subset of TypeScript | Ory, based on Zanzibar | Apache 2.0 | Part of Ory's open-source stack |
| Cedar | RBAC and ABAC | Cedar policies | AWS, open source since 2023 | Apache 2.0 | CNCF Sandbox since 2025 |
| Open Policy Agent (OPA) | ABAC and general policy | Rego | CNCF project since 2018 | Apache 2.0 | CNCF Graduated in 2021 |
Pick by the question your app asks most often.
- If the question is "who shares what with whom", pick OpenFGA or Ory Keto. Auth0 FGA is OpenFGA as a hosted service.
- If the question is "is this request allowed under these conditions", pick Cedar. Amazon Verified Permissions runs Cedar as a managed AWS service.
- If you also want one policy engine for Kubernetes, infrastructure, and APIs, pick OPA. OPA describes itself as "a general-purpose policy engine that unifies policy enforcement across the stack".
Which auth providers support roles and fine-grained authorization
Most auth providers manage roles. Our directory tracks 55 features across 37 providers, and the chart shows the ones that feed authorization.
31 providers support role management. 28 of them also support organizations, which B2B apps need for roles per customer. 34 store custom attributes on users, the raw data for ABAC rules. Of the 15 open-source providers, 11 manage roles. Of the 22 closed-source providers, 20 do. The six without role management are Auth.js, Authelia, Authsignal, Hanko, Magic, and Sooauth. Hanko lists it on its roadmap.
Fine-grained authorization is less common. We found it in the docs of these eight providers:
| Provider | Role management | Fine-grained authorization | Open source | Self-hosted |
|---|---|---|---|---|
| Auth0 | Yes | Auth0 FGA, a hosted ReBAC service built on OpenFGA | No | No |
| WorkOS | Yes | WorkOS FGA, a resource hierarchy on top of its RBAC | No | No |
| Descope | Yes | ReBAC and ABAC in its FGA service | No | No |
| Ory | Yes | Ory Permissions, built on Ory Keto | Yes | Yes |
| Frontegg | Yes | ReBAC in its Entitlements engine | No | No |
| Authress | Yes | Role- and resource-based permissions with nested resources | No | No |
| Keycloak | Yes | Authorization Services with ABAC, RBAC, time-based, and JavaScript policies | Yes | Yes |
| Amazon Cognito | Yes | Through Amazon Verified Permissions, a separate AWS service that uses Cedar | No | No |
Two details matter when you compare them.
- WorkOS FGA extends roles, it doesn't replace them. WorkOS says that FGA "keeps the mental model of RBAC" and adds "hierarchical, resource-scoped access control". Existing roles keep working.
- Ory and Keycloak are the self-hosted options. Ory Keto calls itself "the first open-source implementation" of the Zanzibar design. Keycloak's Authorization Services run inside the Keycloak server. To compare the two, see Ory vs Keycloak.
If roles are enough for now, most providers in the directory handle them. Examples are Clerk, Zitadel, Logto, Kinde, PropelAuth, Stytch, and Better Auth. Supabase Auth takes a different route. You define roles in your own table and enforce them with Postgres row level security. When you outgrow roles, you can add OpenFGA or Cedar next to any of them.
Pick the model by what your app shares
| Your app | Model | Where to run it |
|---|---|---|
| A few fixed roles per customer, such as Admin, Member, and Billing | RBAC | Your auth provider's roles and organizations |
| Users share documents, projects, or folders with each other | ReBAC, with roles as relations | OpenFGA, Auth0 FGA, WorkOS FGA, or Ory Keto |
| Rules depend on context: region, plan, MFA, time, or record status | ABAC | Cedar, Amazon Verified Permissions, or OPA |
| Regulated data with sharing and context rules | ReBAC plus ABAC conditions | OpenFGA with conditions, or Cedar with groups and attributes |
| An internal admin tool | RBAC | Your auth provider's roles |
Authorization starts after authentication. The user must sign in before any of these checks run. For the difference between the two, read authentication vs authorization. For the protocols that carry roles and identity to your API, read SAML vs OIDC vs OAuth. If you build for business customers, the B2B providers in the directory cover roles per organization, SSO, and SCIM.
FAQ
RBAC grants access based on the roles a user holds. ABAC grants access by evaluating a policy against attributes of the user, the resource, the action, and the environment. RBAC answers "is this user an Editor?". ABAC answers "is this user in the document's department, signed in with MFA, and working on a document that isn't archived?".
Core RBAC, hierarchical RBAC, static separation of duty, and dynamic separation of duty. Core RBAC is required, and the other three are optional. The standard was adopted as ANSI INCITS 359-2004 and revised in 2012. The 2000 paper that led to it described four levels instead: flat, hierarchical, constrained, and symmetric RBAC.
ReBAC handles more cases, but it costs more to run. You need an authorization service and you must keep its relationship tuples in sync with your app. If your users never share individual resources, RBAC is enough. ReBAC can express roles as relations, so you can move from RBAC to ReBAC later without changing what users see.
Fine-grained authorization means deciding access per resource, for example per document, instead of per role. ReBAC and ABAC are the two common ways to do it. OpenFGA, Ory Keto, Cedar, and OPA are open-source engines for it, and Auth0, WorkOS, and Descope sell hosted versions.
OpenFGA is an open-source authorization system based on Google's Zanzibar. You describe types and relations in a modeling language, write relationship tuples from your app, and call its Check endpoint. Okta employees built it, it is licensed under Apache 2.0, and it has been a CNCF Incubating project since October 2025. Auth0 FGA is the hosted version.
Use OpenFGA when access depends on relationships, such as sharing, teams, and folders. Use OPA when you need general policy rules over request data, or one policy engine for APIs and infrastructure. OPA policies are written in Rego and OpenFGA models are relationship graphs. Some teams run both.
Yes, and most systems do. Roles handle the coarse checks, and attribute conditions narrow them. Cedar policies can check group membership and attributes in one rule, and Keycloak's Authorization Services combine role-based, time-based, and custom policies.
On this page
- One question, three answers
- Role-based access control gives permissions through roles
- Attribute-based access control checks attributes at request time
- Relationship-based access control follows relationships, like Google Zanzibar
- RBAC vs ABAC vs ReBAC compared
- Most apps combine the models
- Fine-grained authorization runs in OpenFGA, Cedar, OPA, or Ory Keto
- Which auth providers support roles and fine-grained authorization
- Pick the model by what your app shares
- FAQ