JWT Decoder Online — Decode & Verify JSON Web Tokens
Decode and inspect JSON Web Tokens instantly — view header, payload, verify HMAC signatures, and generate JWT code in PHP, JavaScript, Python, and Java.
Updated November 2026
Reviewed by Rafael Duarte
Paste a JWT token on the left to decode it
1const jwt = require('jsonwebtoken');
2
3const secretKey = 'your-256-bit-secret';
4
5const payload = {
6 sub: '1234567890',
7 name: 'John Doe',
8 iat: Math.floor(Date.now() / 1000)
9};
10
11const token = jwt.sign(payload, secretKey, { algorithm: 'HS256' });
12console.log(token);
13
14// To verify:
15const decoded = jwt.verify(token, secretKey, { algorithms: ['HS256'] });
16console.log(decoded);How to decode a JWT token
Decode, verify, and generate code in seconds
1. Paste your token
The three parts appear color-coded instantly — header in pink, payload in purple, signature in cyan.
2. Inspect the claims
iat, exp, and nbf are converted to readable dates automatically — spot an expired token at a glance.
3. Verify the signature
For HS256/384/512, enter the secret key and get an instant green or red verification badge.
What this JWT decoder does
A complete JWT debugger, not just a viewer
Instant decoding
Header, payload, and signature highlighted in color — no key required to read them.
Readable timestamps
exp, iat, and nbf are converted to ISO dates automatically, no manual Unix math.
HMAC signature verification
HS256, HS384, and HS512 signatures verified directly in your browser with your secret key.
Code generation
Ready-to-use signing snippets in JavaScript, PHP, Python, and Java for your own project.
JWT decoding examples
What to expect for a few real-world cases
alg: HS256, sub, name, iat — no exp setexp in the past)alg: noneWhen you'll reach for this tool
The most common scenarios among developers who use it
Debugging a 401 Unauthorized
Check exp, aud, and the algorithm before writing a single line of code.
Security audits
Confirm no sensitive data is leaking through the payload claims.
Integration testing
Verify the right claims, TTL (exp minus iat), and algorithm before writing tests.
Signature verification
Confirm a token was signed with the expected secret between services.
Learning the JWT structure
A color-split view of the three parts, no need to read the RFC first.
Generating signing code
Ready-made snippets save you from hunting down the right method in each library.
Common JWT mistakes
Confusing decoding with verifying
Decoding just reads the payload without checking the signature. A token can decode fine and still be forged.
Storing JWTs in localStorage
Accessible to any JavaScript running on the page — one XSS vulnerability steals every active token.
Skipping the exp claim check
A stolen token stays valid indefinitely. 15 minutes is the 2026 best practice, paired with a refresh token.
Sensitive data in the payload
It's Base64URL, not encryption. Never put a password, card number, or SSN in a JWT payload.
Why use this JWT decoder
Beyond basic decoding, it verifies HMAC signatures directly in your browser and generates ready-to-use code in four languages — a full debugger, not just a payload viewer.
Everything runs locally through the Web Crypto API. Your token and your secret never leave your device, even when you verify a signature.
Frequently asked questions
The payload is only Base64URL-encoded, not encrypted. Anyone holding the token string can decode and read it without a key. The signature only proves who issued the token — it doesn't hide the content.
Yes — decoding and verifying are separate operations. Decoding is just a Base64URL-decode, no key needed at all. Verifying checks the signature with the shared secret (HMAC) or the issuer's public key (RSA/ECDSA). This tool verifies HS256, HS384 and HS512 with a secret you enter; RS and ES tokens are decoded but not verified.
The tool decodes it completely and shows the full payload regardless of expiration. The exp claim appears next to its readable date, making it obvious the token has already expired.
HS256 is symmetric — the same secret key both signs and verifies the token. RS256 is asymmetric — a private key signs it, and a different public key verifies it. RS256 is preferred in distributed systems where you don't want every service holding the signing secret.
Usually a mismatched secret, the wrong algorithm selected, or the token payload being altered after signing. Double-check you're using the exact secret and algorithm the token was originally signed with — even a trailing space or wrong encoding breaks the match.
No. All decoding and verification happens in your browser via the Web Crypto API. Nothing leaves your device, and the tool keeps working offline once it has loaded.
Resources
The canonical JWT reference and interactive debugger, maintained by Auth0.
The official specification defining the JWT format, claims, and processing rules.
A practical guide to JWT structure, signing, and common usage patterns.
Related Tools
- Bcrypt Generator & Checker: Hash and Verify Passwords Developer Generate a bcrypt hash with cost 4 to 18 or check whether a password matches a $2a$, $2b$ or $2y$ hash. Runs in your browser; nothing is uploaded.
- Chmod Calculator: Linux Permissions 755, 644 & 777 Developer Tick read, write and execute or type 755 to get rwxr-xr-x, a ready chmod command and a warning for 777. Includes umask, SUID, SGID and sticky bit.
- Enigma Machine Simulator: M3 & M4 Emulator Online Developer Encrypt and decrypt like a WWII operator: Enigma M3 and M4, rotors I–VIII, ring settings, a 10-cable plugboard and a step-by-step signal animation.
- ASCII Table Generator: Plain-Text & Markdown Tables Developer Turn CSV or typed data into a plain-text table: MySQL, Unicode box, rounded, double-line, Markdown, RST or minimal style. Copy it or download as .txt.
- Base64 Decode Online — Free Base64 to Text Decoder Developer Free online Base64 decoder — decode Base64 strings back to plain text instantly in your browser. Validates input and shows decoded payload size.