Join our Newsletter — 33% off our NHI Course
Authentication, Authorisation & Trust

JWT Expiry

← Back to Glossary
By NHI Mgmt Group Updated October 23, 2026 Domain: Authentication, Authorisation & Trust

JWT expiry is the time limit after which a JSON Web Token is no longer accepted for authentication or authorization. In identity systems, the exp claim sets this deadline so compromised tokens have a short useful life and services can reject stale credentials, reducing replay risk and limiting exposure from leaked secrets.

What JWT expiry means in practice

JWT expiry is not just a time stamp, it is the control that limits how long a bearer token remains useful if it is copied, logged, forwarded, or stolen. In practice, expiry turns a JSON Web Token from a standing credential into a short-lived assertion.

That matters because JWTs are commonly used as portable proof of authentication or authorisation. Once the expiry time passes, relying parties should reject the token and force the client to obtain a fresh one, which narrows the replay window and reduces the value of leaked tokens.

How expiry changes token trust

Expiry is part of the token’s trust model, not an afterthought. A token with a longer lifetime increases convenience, but it also increases the time an attacker can reuse it if they capture it through browser storage, proxy logs, client-side compromise, or intercepted traffic.

Because JWTs are often self-contained, services may validate them without contacting the issuer on every request. That makes the expiry claim especially important: it is one of the main ways a relying service can bound trust in a token that may otherwise remain structurally valid until it expires.

Expiry also shapes how surrounding controls behave. A short-lived access token can be paired with separate refresh or reauthentication steps, while a long-lived token raises the importance of revocation design, session monitoring, and key rollover discipline.

Common implementation mistakes

JWT expiry only works when every component enforces it consistently. A token that is issued with a deadline but accepted by one service after expiry creates a broken trust boundary, especially in distributed systems where different gateways, APIs, and libraries may parse time claims differently.

Time handling is a frequent source of error. Clock skew, missing leeway rules, and inconsistent validation of exp can produce false accepts or false rejects. Another common mistake is treating expiry as sufficient protection while leaving token storage, signature validation, audience checks, and issuer checks weak.

Expiry is also often confused with revocation. A token can be expired and still be used as evidence of prior compromise, while a token can be unexpired but already unsafe if the signing key, session context, or upstream account has been compromised.

Why JWT expiry matters for identity systems

In identity systems, expiry is a basic containment control for stolen credentials. It limits how long a bearer token can impersonate a user, service, or workload, and it reduces the blast radius when a token is exposed in a log, browser artifact, CI/CD trace, or application error.

For a broader view of token handling, Token and Session Security Guide explains how token lifetime, validation, revocation, and replay resistance fit together. Where organisations need to think beyond a single token and into lifecycle discipline, Guide to NHI Rotation Challenges is useful for understanding why short-lived credentials are easier to control than long-lived ones.

Risk and Threat Considerations

JWT expiry matters because a bearer token is usable by whoever holds it, so a longer lifetime directly increases exposure if the token is stolen, replayed, or copied into an unintended system. The risk is especially visible in distributed services where the token may be accepted by multiple APIs before anyone notices misuse.

Failure mechanism: Attackers reuse a captured token before expiry, or a service accepts an expired token because validation is inconsistent, clocks are skewed, or the implementation trusts the token without enforcing the deadline.

Impact: The attacker can impersonate the original subject, access protected resources, and extend the compromise window until the token expires or the surrounding session and key material are invalidated.

Standards & Framework Alignment

This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.

OWASP Non-Human Identity Top 10 addresses the attack and risk surface, while NIST SP 800-53 Rev 5, NIST SP 800-57 and OWASP ASVS set the governance and control requirements practitioners need to meet.

FrameworkControl / ReferenceRelevance
NIST SP 800-53 Rev 5IA-5 — Authenticator ManagementJWT expiry governs token lifetime and reuse risk in authentication flows.
IA-9 — Service Identification and AuthenticationJWTs are often used by services and workloads as bearer authenticators.
Recommendation — Set and enforce short token lifetimes, and require reauthentication or token renewal before continued use. Validate service tokens strictly and reject expired assertions before granting service-to-service access.
NIST SP 800-57Key ManagementJWT expiry is part of the broader lifecycle discipline that limits the usable life of cryptographic trust material.
Recommendation — Align token lifetime with key and session lifecycle decisions so stolen material loses value quickly.
OWASP ASVSV9 — Self-contained TokensJWTs are self-contained tokens whose acceptance depends on correct lifetime and claim validation.
Recommendation — Require expiry enforcement and robust claim validation for all self-contained tokens.
OWASP Non-Human Identity Top 10NHI-07 — Long-Lived SecretsShort token expiry directly reduces the exposure caused by long-lived bearer material.
Recommendation — Minimise bearer token lifetime to reduce replay value if the token is exposed.

Practitioner Guidance

Why practitioners should care: Treat expiry as one layer in token security, not the whole control. A good expiry policy only helps when the token is also validated for signature, issuer, audience, and intended use.

Common misunderstanding: Many teams assume a short expiry eliminates replay risk. It reduces risk, but it does not remove it, especially when refresh flows, caching, or downstream services extend the effective lifetime of a compromised session.

Practitioner note: For short-lived token design and rotation discipline, compare the token model with OWASP Non-Human Identity Top 10 and NIST SP 800-57 Key Management, which reinforce the value of limiting the useful life of identity material.

Free weekly newsletter

Subscribe to the NHI & AI Identity Journal

The latest on NHI and Agentic AI security – articles, research, breaches, news and events every week.

Bonus 33% off our NHI Course when you subscribe.

NHIMG Editorial Note
Reviewed and updated by the NHIMG editorial team on October 23, 2026.
NHI Mgmt Group — the #1 independent authority on Non-Human Identity, IAM, and Agentic AI security. nhimg.org