JWT Decoder

Paste a JSON Web Token to read its header and claims, check whether it has expired, spot security red flags, and optionally verify its signature — all in your browser.

Tokens, secrets and keys stay in your browser — nothing is sent or stored

Processed locally. The token, secret and key you enter here never leave this page; ToolTarvern has no server code for this tool and stores nothing. Treat real tokens as passwords: use test tokens where you can.

A leading “Bearer ” is removed automatically.

How it works

A signed JWT is three Base64URL strings joined by dots: header.payload.signature. The decoder:

  1. splits the token and decodes the header and payload to JSON;
  2. lists every claim, explaining the registered ones (iss, sub, aud, exp, nbf, iat, jti) and showing times as UTC dates and relative to now;
  3. flags problems: an unsigned token (alg: none), an expired or not-yet-valid token, a missing expiry, an issue time in the future, a very long lifetime, or exp in milliseconds;
  4. optionally verifies the signature with the Web Crypto API: HMAC (HS256/384/512) with your secret, or RSA (RS*, PS*), ECDSA (ES*) and EdDSA with the public key.

Decoding shows you what a token says. Only a verified signature tells you it’s genuine, and only your server should decide whether to trust it.

Example

The sample token decodes to the header {"alg":"HS256","typ":"JWT"} and a payload for user 1234567890 (“Thandi Nkosi”, role editor), issued at 2025-10-09 08:53:20 UTC and expiring one hour later. That’s in the past, so the decoder warns that it has expired.

Open “Verify the signature” and enter the secret tooltarvern-demo-secret to see a valid signature. Change one character of the payload, or the secret, and verification fails.

Frequently asked questions

Is it safe to paste my token here?

This decoder runs entirely in your browser: the token, secret and keys are never sent to ToolTarvern or anyone else, and nothing is stored. Still, a JWT is often a live credential — anyone holding it can use it until it expires — so prefer test tokens, and never share production tokens in screenshots, tickets or chat.

Does decoding a JWT prove it’s genuine?

No. The header and payload are only Base64URL-encoded, so anyone can read — and anyone can write — them. Only verifying the signature with the right secret or public key proves the token was issued by whoever holds that key and hasn’t been altered.

Which algorithms can it verify?

HS256, HS384, HS512, RS256, RS384, RS512, PS256, PS384, PS512, ES256, ES384, ES512, EdDSA, using your browser’s Web Crypto API. HS* tokens need the shared secret; RS*, PS*, ES* and EdDSA tokens need the public key as PEM (BEGIN PUBLIC KEY) or JWK — a JWKS works too, matched by kid. EdDSA requires a recent browser.

Can it decode encrypted tokens (JWE)?

No. A JWE has five parts and its payload is encrypted, so it can only be read with the decryption key. The decoder recognises JWEs and says so.

Why are exp and iat numbers?

JWT times are NumericDates: seconds since 1 January 1970 UTC. The decoder shows each as a date in UTC and relative to now, and warns if a value looks like milliseconds by mistake.

Related tools

Decode Base64 to text, preview images, detect file types and download the original file — with precise errors.

FreeRuns in your browser

Convert Unix timestamps to dates and back, in UTC, South African time or your local time zone.

FreeRuns in your browser

Pretty-print or minify JSON with your choice of indentation and optional key sorting.

FreeRuns in your browser

Generate random v4 or time-ordered v7 UUIDs in bulk, in the format you need.

FreeRuns in your browser

Related guides