RBAC Scope
In Azure role-based access control, scope is the boundary where a role assignment applies: management group, subscription, resource group, or single resource. Permissions are inherited downward, so assign at the narrowest scope that works.
RBAC Scope
A role assignment ties together who (a user, group, or identity), what (a role definition), and where (the scope). Assigning Contributor on a subscription grants it for everything beneath, while assigning it on one resource group limits the reach. Permissions are additive, so a user's effective access is the union of all assignments that apply to them.
How Does Scope Inheritance Work?
How Do You Assign a Role at a Narrow Scope?
az role assignment create --assignee <service-principal-id> \ --role Contributor \ --scope /subscriptions/<sub-id>/resourceGroups/mumbai-staging-rg # See every assignment that affects a scopeaz role assignment list --all --scope /subscriptions/<sub-id> --output tableWhy It Matters in Production
A payments team like PhonePe can scope its CI/CD identity to the staging resource group only, so a leaked pipeline credential cannot touch production.
SecuritySubscription-level Contributor or Owner is one of the most common over-privileged setups. Scope down and use Privileged Identity Management for elevated access.
Common MistakeFixing "access denied" by granting a broader scope. Check effective access with Check access first, because the real fix is often a more specific role at the right scope.
Frequently Asked Questions
Why assign a role at a management group instead of a subscription?
It gives one assignment that inherits across many subscriptions, useful for central teams such as security readers. The trade-off is a larger blast radius if that identity is compromised.
Can a lower scope remove access granted above?
Not with a normal role assignment, because permissions are additive. Only deny assignments, which are mostly system-managed, can block inherited access.
How do I see who has access to a resource?
Open Access control (IAM) on the resource and use Check access or Role assignments, which include inherited assignments from parent scopes.