JWT Generator
Create signed JSON Web Tokens with HS256, HS384 or HS512 from a custom header and payload.
About the JWT Generator
The JWT Generator creates signed tokens for testing APIs and authentication flows. Edit the header and payload as JSON, choose an HMAC algorithm and sign with your own secret.
Everything runs in your browser, so your input is never uploaded to a server.
How to use the JWT Generator
- Edit the payload claims (for example sub, exp, roles).
- Choose HS256, HS384 or HS512 and enter a secret.
- Copy the signed token into your request or test.
Frequently asked questions
How long should the secret be?
At least as long as the hash output: 32 random bytes for HS256, 48 for HS384 and 64 for HS512.
Can it create RS256 tokens?
No, it signs with shared-secret HMAC algorithms only.
Related tools
Base64 Encode / Decode
Encode text to Base64 or decode Base64 to text with full UTF-8 and URL-safe support.
URL Encode / Decode
Percent-encode or decode URLs and query string components.
HTML Entity Encode / Decode
Escape special characters as HTML entities or decode entities back to text.
JWT Decoder & Verifier
Decode JSON Web Tokens, inspect header and claims, check expiry and verify HMAC signatures locally.
Unicode Escape / Unescape
Convert text to \uXXXX escape sequences and back, including emoji and astral characters.
JSON Formatter
Format and beautify JSON with configurable indentation and optional key sorting. Errors are reported with exact line and column.