Decoding a JWT does not verify it

CodeMoment · Updated 2026-10-31

Decoding a JSON Web Token shows the header and the payload. It does not prove that anyone you trust signed that payload.

A JWT is three pieces of text separated by dots. The first is the header, the second is the payload, and the third is the signature. The first two are Base64url: the URL-safe Base64 alphabet, often without = padding. A decoder turns those two pieces back into JSON and prints them. Anyone who can see the token can do that. No secret is required.

Change one claim and leave the signature where it is. Suppose the payload says the role is admin. Replace that word with guest and keep the third segment. A decoder still prints the new payload. The signature no longer matches the bytes that were signed, but a decoder never computes that check, so the screen looks like the same kind of success. Only the issuer, holding the signing key or a public key you have chosen to trust, can tell the two tokens apart.

A header that sets alg to none is not a signed token. There is no signature to check. Printing the payload does not make the token acceptable. Do not treat none as a harmless default.

exp is a Unix timestamp in seconds, not milliseconds. The number 1600000000 is 2020-09-13 12:26:40 UTC. Read those ten digits as milliseconds and the instant falls in January 1970, about eighteen days after the epoch. Thirteen digits are the millisecond form. Mixing the units moves the date by decades, not by a rounding error. The Timestamp Converter on this site treats ten digits as seconds and thirteen digits as milliseconds. The clock it uses is the clock of the device you are using. An expiry in the future does not mean the signature is valid. An expiry in the past does not mean the payload was honest when it was signed.

The JWT Decoder ignores a leading Bearer prefix, shows the header, payload, and signature, and compares exp with this device. It does not call the issuer, does not fetch a JWKS document, and does not store the token. Analytics on this site do not record what you paste.

Use the decoder to read what a token claims. Verify the signature in a place that holds the key before you trust those claims.