JWT Decoder
decode JWT tokens and inspect header, payload, and claims
Try it now — free, instant, no signup
Paste a JWT and it splits the token at the two dots, base64url-decodes each segment, and renders the header, payload, and signature as formatted JSON. Useful when you have a token like eyJhbGciOiJSUzI1NiJ9... from an Authorization header and need to confirm the exp claim without spinning up a debugger or curl. Unlike jwt.io, nothing leaves your browser tab.
What is JWT Decoder?
A JWT is three base64url-encoded segments joined by dots. This tool splits on those dots, runs each segment through a base64url decoder (padding-aware, replacing - with + and _ with /), then JSON-parses the result and pretty-prints it so you can read fields like iss, sub, aud, and exp at a glance. Example: drop in a token and immediately see that exp is 1716076800, which you can mentally compare to a Unix timestamp or read as the rendered UTC date the tool shows.
When you already have Postman open, its built-in JWT decoder under the Authorization tab is faster for tokens attached to a request. If you only need to inspect the payload and you have Node.js available, JSON.parse(Buffer.from(token.split('.')[1], 'base64').toString()) in a REPL takes three seconds. This tool earns its place when you are on a machine without Node, inside a browser-only environment, or when you want a clean visual split of header versus payload without writing a one-liner.
One gotcha that catches developers regularly: the exp and iat claims are Unix timestamps in seconds, not milliseconds. JavaScript's Date constructor expects milliseconds, so if you copy the raw exp value and pass it to new Date(exp) you will get a date in 1970. Multiply by 1000 first. Also, decoding a JWT here tells you what the token claims, not whether the signature is valid — verifying the HMAC or RSA signature requires the secret or public key, which this client-side tool intentionally does not handle.
When to use JWT Decoder
- Confirm an `exp` timestamp is in the future before blaming an upstream service for a 401 during local integration testing.
- Identify which `alg` value a third-party identity provider is sending when your library throws an unsupported algorithm error.
- Extract the `sub` or custom claim from a token copied out of browser DevTools without setting up a local script.
Expert Notes
A JWT has three parts: header, payload, and signature — the decoder shows you the first two, but verification of the signature requires the secret or public key, which you should never paste into a third-party tool. The `alg: none` attack is real: some older libraries accept unsigned tokens if the algorithm is set to `none`; always validate `alg` server-side before trusting a JWT. The `exp` claim is Unix epoch seconds, not milliseconds — a common off-by-1000 bug appears when developers compare it against `Date.now()` directly.
DevLab's Take
Essential for debugging auth issues in development — paste the token, read the claims, check the expiry. Never decode a production JWT containing sensitive claims in a public browser tab.
Frequently Asked Questions
Why does the decoded payload show correct JSON but the signature segment looks like random bytes?
My token has a period inside the payload after decoding. Did it get corrupted?
What is the difference between base64 and base64url, and does it matter here?
Can this tool decode a JWT signed with RS256 or ES256, or only HS256?
The `exp` claim decoded fine but the date shown looks wrong by several hours. Why?
Related Tools
- Base64 Encoder / Decoderencode and decode Base64 strings and files in your browser · Encoding
- Hash Generatorgenerate MD5, SHA-1, SHA-256, and SHA-512 hashes from text · Encoding
- URL Encoder / Decoderencode and decode URL percent-encoding for query strings and paths · Encoding
- JSON Formatterformat and prettify JSON with syntax highlighting · JSON
Learn more
- JWT Structure and How It WorksUnderstand JSON Web Tokens: their structure, how to decode them, and when to use (and not use) them.
- JWT vs Session Tokens: Which Should You Use?Understand the fundamental differences between stateless JWT authentication and stateful session tokens, with concrete guidance on which fits your use case.
- JWT Refresh Tokens ExplainedLearn how refresh tokens extend JWT authentication sessions securely, without requiring users to log in again every 15 minutes.
- How JWT Works: Header, Payload, Signature DecodedUnderstand JWT structure, how HS256 and RS256 signing work, when to use JWT over sessions, and the security mistakes that get apps breached.