Guide
Reading the claims inside a JWT
By Logappradeep · ServiceNow developer
When an API answers 401 Unauthorized or a user is mysteriously missing a permission, the first step is to look inside the access token. A JSON Web Token (JWT, RFC 7519) carries its claims in plain JSON that has merely been Base64URL-encoded, so decoding it requires no key at all. This decoder splits the token, decodes the header and payload as you paste, and shows them as formatted JSON.
What decoding actually does
A signed JWT has three dot-separated segments. Decoding takes the first two, converts each from Base64URL back to bytes, and parses the resulting UTF-8 text as JSON. For example, the familiar prefix eyJhbGciOiJIUzI1NiJ9 decodes to {"alg":"HS256"}. The third segment, the signature, is binary data that only means something when checked with a key. If you paste the whole Authorization header value, a leading Bearer prefix is removed for you.
Claims worth checking when debugging
exp(expiration time): the most common reason for a rejected token. It is a NumericDate, the number of seconds since the Unix epoch, not milliseconds. The decoder convertsiat,nbf, andexpinto readable local dates and flags a token that has already expired.nbf(not before) andiat(issued at): a token issued by a server whose clock runs ahead may appear "not yet valid" elsewhere, so allow for a little clock skew.aud(audience): must match the API that receives the token. A token minted for one service is often rejected by another for exactly this reason.iss(issuer): shows which identity provider or tenant created the token, which helps when staging and production tokens get mixed up.sub(subject) and custom claims such asscope,roles, orgroups: confirm the user and permissions the backend will see.
Decoding is not verifying
Anyone can decode a JWT, and anyone can also edit a payload and re-encode it. A decoded token tells you what the token claims, not whether those claims are genuine. Never make authorization decisions on the client from decoded claims alone; the server must verify the signature with the proper key and then validate exp, aud, and iss. Use the JWT Verifier when you need to check a signature.
What this means for token design
Because the payload is readable by anyone who holds the token, including browser extensions and anything that logs request headers, it should never contain passwords, API secrets, or sensitive personal data. If confidentiality is required, use encrypted JWTs (JWE), which have five segments and cannot be decoded without the decryption key; the decoder recognizes them and tells you so.
Privacy
Access tokens are live credentials. This decoder runs entirely in your browser and does not send the token anywhere, but it is still good practice to decode expired or test tokens when you can, and to avoid sharing screenshots of valid ones.