🛠️DevTools

Basic JWT Token Example

Try:
155 characters
characters
Header
{
  "alg": "HS256",
  "typ": "JWT"
}
Payload
subSubject - Who the token is about1234567890
nameUser's full nameJohn Doe
iatIssued At - When the token was created1516239022 (1/18/2018, 1:30:22 AM (EXPIRED))
Signature
SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c
⚠️ Signature verification requires the secret key. This tool only decodes the token.

💡 Tip: JWT tokens consist of three parts: Header (algorithm info), Payload (claims/data), and Signature (verification). This tool decodes the header and payload but cannot verify signatures without the secret key.

Code Examples

Here's how to achieve this in different programming languages:

1// Decode JWT (without verification)
2const token = "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxM...";
3const [header, payload, signature] = token.split('.');
4const decoded = {
5 header: JSON.parse(atob(header)),
6 payload: JSON.parse(atob(payload)),
7 signature
8};
9console.log(decoded);
10
11// Using jwt-decode library
12import jwt_decode from 'jwt-decode';
13const decoded = jwt_decode(token);

More JWT Examples

Related JWT Tools

📚 Learn More