Home / JWT tools / JWT parser

JWT Parser

Break a token into its header, payload and signature. See how each part is built and copy any part on its own.

What the JWT parser does

A JWT parser breaks a token into its three parts: the header, the payload and the signature. This one shows each part with its length and decoded size, then gives you the whole token as one JSON object that you can copy.

The three parts

  • Header: a JSON object that names the algorithm and often the key ID.
  • Payload: a JSON object that holds the claims.
  • Signature: raw bytes, written in Base64URL, computed over the first two parts.

How parsing works

The parser splits the token at the dots, converts Base64URL back to bytes, reads the bytes as UTF-8 and parses the JSON. Base64URL uses - and _ instead of + and / and has no = padding, so a standard Base64 decoder can fail on it.

Copy a single part

Each part has its own copy button, so you can take only the header or only the payload segment into a script or a test. The JSON output is handy for bug reports and for comparing two tokens.

Parser or decoder?

The tools read the same tokens. The parser focuses on structure. The JWT decoder adds time claims and signature verification, and the inspector adds security checks. To build a token instead, use the JWT encoder. Background reading: what a JWT is.

Frequently asked questions

What are the parts of a JWT?

A header, a payload and a signature, separated by dots: header.payload.signature.

How do I parse a JWT by hand?

Split the token at the dots, Base64URL decode the first two parts and read them as JSON. The third part is the binary signature.

Why does a normal Base64 decoder fail on a JWT?

JWTs use the URL-safe alphabet with - and _ and no padding. A standard decoder expects + and / and = padding.

Can the parser read an encrypted token?

No. Encrypted tokens (JWE) have five parts and need a key to decrypt. The parser handles signed tokens with three parts.