What are OAuth scopes and how are they used to limit what an API client can access?

Last updated 29 June 2026

  • Scopes are named permissions (e.g. read:orders) that a client requests and a user consents to. Granted scopes are encoded into the access token.

  • The resource server checks the token's scopes per endpoint and returns 403 if one is missing. This enforces least privilege and limits damage if a token leaks.

  • Scopes are coarse-grained and don't replace resource-level checks like record ownership.

  • https://auth0.com/docs/get-started/apis/scopes
  • https://docs.github.com/en/apps/oauth-apps/building-oauth-apps/scopes-for-oauth-apps
  • https://docs.github.com/en/apps/oauth-apps/using-oauth-apps/authorizing-oauth-apps
  • https://learn.microsoft.com/en-us/entra/identity-platform/scopes-oidc
  • https://auth0.com/blog/oauth2-access-tokens-and-principle-of-least-privilege/
  • https://www.obsidiansecurity.com/blog/oauth-scopes-permissions-security-best-practices
  • https://auth0.com/blog/auth0-authorization-guide-scopes-roles-client-grants/
  • https://curity.io/resources/learn/scope-best-practices/
All REST API interview questions