Skip to content
ENCODING & DECODING

JWT Decoder – Decode JSON Web Tokens Online

Decode a JWT header and payload without verifying it.

  • Free
  • No signup
  • Runs in your browser

This tool runs in your browser. The text you enter is processed on your device and is not sent to NHP Learning.

JWT Decoder

About JWT Decoder

A JSON Web Token (JWT) is a compact string with three parts separated by dots: a header, a payload and a signature. The header and payload are JSON objects encoded with URL-safe Base64, so anyone holding the token can read them. The signature lets a server check that the token was not modified.

This decoder splits the token, decodes the header and payload locally and shows them as formatted JSON, so you can inspect claims such as sub, iss, aud, iat and exp while debugging login flows. It does not verify the signature, because verification needs the secret or public key.

How to use JWT Decoder

  1. Paste the full JWT, including both dots, into the input box.
  2. Click Run Tool to decode it.
  3. Read the header and payload. Convert iat and exp values with the Timestamp Converter if you need dates.

Example

Input

eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c

Output

{
  "header": {
    "alg": "HS256",
    "typ": "JWT"
  },
  "payload": {
    "sub": "1234567890",
    "name": "John Doe",
    "iat": 1516239022
  },
  "warning": "Signature not verified"
}

This is the public sample token used in the JWT documentation, so it contains no real account data.

Common uses

  • Checking why an API rejects a token: wrong audience, missing scope or expired exp claim.
  • Inspecting the claims returned by an identity provider during development.
  • Learning how JWT-based authentication is structured.

Privacy and safety

This tool runs in your browser. The text you enter is processed on your device and is not sent to NHP Learning.

Frequently asked questions

Does decoding prove a token is valid?

No. Anyone can create a token with any payload. A token is only trustworthy after the server verifies its signature with the correct key.

Is it safe to paste a real token?

Decoding happens in your browser and the token is not sent to NHP Learning. Even so, treat live tokens like passwords and prefer expired or test tokens when using any online tool.

What do iat, nbf and exp mean?

They are Unix timestamps in seconds: issued at, not valid before and expires at. Paste them into the Timestamp Converter to see the date and time.

Learn to build this yourself

Free tutorials and courses on NHP Learning cover PHP, JavaScript, SQL and WordPress, from the basics to real projects.