Decode JWT claims, see expiry, verify HMAC and public key signatures
JWT Generator
Make a test token for an API or a local app in seconds, signed with your secret and checked before you copy it.
Loading tool…
How to use jwt generator
Pick HS256, HS384 or HS512 and add a key ID if your server uses one.
Edit the payload JSON; use iat = now and Set exp for times.
Enter the secret, or press Random secret for a strong one.
Copy the signed token, which updates as you type.
What this tool does
- Signs with HMAC through the browser's Web Crypto.
- Accepts the secret as text, Base64 or hex, matching how your server stores it.
- Warns when the secret is shorter than the algorithm needs (32, 48 or 64 bytes).
- Colours the header, payload and signature so you can see the three parts.
How the result is verified
Each new token is decoded again, its header and payload compared with what you entered, and its signature verified with the same secret before the green check appears.
Frequently asked questions
How long should an HS256 secret be?
At least 32 random bytes, the size of the SHA-256 output (RFC 7518). Random secret makes one of the right length for the chosen algorithm and sets the format to Base64.
Is the payload of a JWT secret?
No. It is only Base64url encoded, so anyone with the token can read it. Never put passwords or personal data in it that the holder should not see.
Is my data uploaded to a server?
No. Everything you drop, paste or type is processed by code running in this browser tab. You can check it yourself: open your browser's developer tools, watch the Network panel, and use the tool. No request carries your data.
Related tools
MD5, SHA-1, SHA-256, SHA-384, SHA-512 and HMAC for text or files
Text or files to Base64, Base64url or a data URL, with UTF-8 support
Bulk UUID v4 and v7 with formats, plus a UUID inspector