Skip to content
uencoder

Bearer Token

A Bearer token is a token type that works purely by possession: it is sent in the Authorization: Bearer <token> header, so whoever holds it can use it, with no additional credentials.

Purpose

It provides a simple token-based authentication mechanism in which the token itself is the credential.

Mechanism

The header is Authorization: Bearer <token>. The server validates the token's validity and permissions. The token can be a JWT, an opaque token, and so on. Security relies on HTTPS to prevent transit leakage and on token lifetime; once leaked, the token can be used for impersonation.

Use cases

  • API Bearer authentication
  • OAuth 2.0 access token
  • Carrying JWTs
  • Service-to-service authentication

Examples

  • Input
    Authorization: Bearer eyJ...
    Output
    The server verifies the JWT signature and expiry

    Possession grants validity

Common errors

A leaked token is immediately used for impersonation
Use short lifetimes, HTTPS, and a revocation list

Related terms

Related tools

References