DevKits
7 registered claims

JWT Claims Reference

Every standard JWT claim from RFC 7519 — what it means, its type, an example value, and the gotcha that bites people. Decoding never needs a key; only signature verification does.

A JWT's payload is a JSON object of claims — statements about the token and its subject. RFC 7519 defines a set of registered claims with reserved three-letter names (shown below); everything else is a public or private claim you define yourself. The payload is only Base64URL-encoded, not encrypted, so never store secrets in a claim.

issIssuerStringOrURIRFC 7519

Identifies who issued the token — usually your auth server's identifier or URL. Verifiers check it to make sure the token came from a trusted issuer.

"iss": "https://auth.example.com"

Gotcha: Always validate iss on the verifier side against an expected value. Accepting tokens from any issuer is a common auth bug.

subSubjectStringOrURIRFC 7519

The principal the token is about — typically the user ID. It should be unique within the issuer and stable for that user.

"sub": "user_1234567890"

Gotcha: Don't put personally identifying info (email, name) in sub if the token is readable by clients — the payload is only Base64URL-encoded, not encrypted.

audAudienceStringOrURI | string[]RFC 7519

Identifies the recipient(s) the token is intended for — e.g. your API's identifier. A verifier must reject a token whose aud doesn't include itself.

"aud": "https://api.example.com"

Gotcha: aud can be a single string or an array. Validate that your service's identifier is present; skipping aud validation lets a token minted for one API be replayed against another.

expExpiration TimeNumericDateRFC 7519

The Unix timestamp (seconds since epoch) after which the token must be rejected. This is how JWTs expire.

"exp": 1735689600

Gotcha: exp is in SECONDS, not milliseconds — a classic bug is passing Date.now() (ms). Keep access-token exp short (minutes) and use refresh tokens, since a JWT can't be revoked before it expires.

nbfNot BeforeNumericDateRFC 7519

The Unix timestamp before which the token must not be accepted. Lets you issue a token that only becomes valid later.

"nbf": 1735603200

Gotcha: Clock skew between servers can make a just-issued token fail nbf. Allow a small leeway (e.g. 30–60s) when validating exp/nbf.

iatIssued AtNumericDateRFC 7519

The Unix timestamp when the token was issued. Useful for computing token age and for revocation-by-issue-time schemes.

"iat": 1735603200

Gotcha: iat alone doesn't expire a token — you still need exp. Some systems reject tokens issued before a 'password changed' timestamp as a lightweight revocation mechanism.

jtiJWT IDstringRFC 7519

A unique identifier for the token. Primarily used to prevent replay — a verifier can track used jti values and reject duplicates, or build a revocation denylist keyed by jti.

"jti": "a1b2c3d4-e5f6-7890-abcd-ef1234567890"

Gotcha: jti only helps if you actually store and check it. On its own in the payload it does nothing — you need server-side state (a seen-list or denylist) to get replay/revocation protection.

Common custom claims

Beyond the registered claims, these non-standard claims appear constantly in real tokens (especially OAuth access tokens and OpenID Connect id_tokens). Exact key names vary by identity provider.

scope / scp
OAuth scopes granted to the token, space- or array-delimited (e.g. 'read:users write:users'). Used for authorization decisions.
roles / role
The user's roles for role-based access control. Non-standard — the exact key depends on your issuer (Auth0, Keycloak, Cognito all differ).
email / email_verified
OpenID Connect identity claims carried in the id_token. email_verified is a boolean the IdP sets.
name / preferred_username / picture
OpenID Connect profile claims for display. Present in id_tokens, not usually in access tokens.
azp
Authorized party — the client ID the token was issued to (OpenID Connect).