PRACTICAL GUIDE
Is It Safe to Decode a JWT Online?
A JWT is readable by anyone who holds it, and pasting a live one into a website hands over a working credential. What that means in practice.
Last updated
What a JWT actually is
A JSON Web Token is three chunks separated by dots: a header, a payload and a signature. The first two are ordinary JSON, encoded with base64url. That encoding is not encryption — it exists so the data survives being put in a URL or an HTTP header, and reversing it requires no key and no secret.
Anyone holding the token can read the payload. The signature does not hide the contents; it only lets the server detect that they have been altered.
So why does pasting one into a website matter
Because the risk is not that the site can read the claims — you could read them yourself. The risk is that a JWT is usually a bearer token, meaning whoever presents it is treated as the user it describes. Sending a live, unexpired access token to a third-party server is handing over a working key to your account or your customer's account, for as long as it remains valid.
A decoder that runs on a server receives that token. Whether it logs it, retains it or transmits it onward is entirely outside your view, and the token stays useful until it expires.
The safe ways to inspect a token
Use a decoder that runs in your browser and never transmits the value. Our JWT decoder splits the string and decodes the two segments locally; nothing is sent anywhere, which you can confirm in the Network tab of your developer tools.
Alternatively, decode it yourself. The payload is just base64url, so a one-line command in a terminal or a browser console does the job without involving anyone.
Best of all, use a token you do not care about — one issued in a development environment against test data.
Check the claims that matter
Once decoded, the useful fields are usually exp, the expiry as a Unix timestamp; iat, when it was issued; iss and aud, who issued it and who it is intended for; and sub, the subject it identifies. A surprising share of 'my authentication is broken' incidents turn out to be a token that expired, or one issued for a different audience than the service checking it.
Decoding is not verifying
Reading a payload tells you what the token claims. It tells you nothing about whether those claims are true. Verification means checking the signature against the issuer's key, along with the expiry and the audience, and it is something your backend must do on every request. No decoder — ours included — can do this for you, because it does not have the key, and any tool that offers to verify a signature is asking you for your secret.
Treat leaked tokens like leaked passwords
Tokens end up pasted into chat threads, issue trackers and screenshots more often than anyone would like. If a live token has been exposed, the response is the same as for a password: revoke or rotate the session rather than waiting for the expiry. And keep access-token lifetimes short, so an accidental exposure has a small window.
Frequently asked questions
Is a JWT encrypted?
A standard signed JWT is not. The header and payload are base64url-encoded, which is a reversible transformation with no key involved. There is a separate encrypted form, JWE, but it is far less commonly used and looks different — it has five segments rather than three.
Can someone modify a JWT they have?
They can change the payload, but the signature will no longer match and a correctly implemented server will reject it. The historical exception is a server that accepts the alg field of 'none', or that fails to check the algorithm at all, which is why libraries now require you to state the expected algorithm explicitly.
Should I put personal data in a JWT payload?
Only what you are comfortable being read by anyone who obtains the token, including the user themselves and any system it passes through. Identifiers and role claims are normal; email addresses, names and anything regulated are better fetched from an API against the token than embedded in it.
Does your decoder check the signature?
No, and it cannot. Verifying a signature requires the issuer's secret or public key. Asking you to paste a signing secret into a web page would be considerably worse advice than asking you to paste the token.