JWT Generator
Build and sign a JSON Web Token with HS256, HS384 or HS512 from an editable header and claims, with an exp shortcut and an expiry readout.
JWT Generator
Signing happens entirely in your browser via the Web Crypto API. Your secret and claims never leave this page.
Updated . Provided as is. Check the output before you rely on it in production.
How to use JWT Generator
- 1
Edit the header
Keep the default header with alg and typ, or adjust it. The alg field stays in sync with the algorithm selector.
- 2
Write your claims
Enter the payload as JSON, or use the quick-add buttons for iat, exp, sub, iss, and aud.
- 3
Choose algorithm and secret
Pick HS256, HS384, or HS512 and enter the shared secret used to sign and later verify the token.
- 4
Read the preview
Check the decoded claims and expiry status to confirm the token contains what you expect.
- 5
Copy the token
Copy the signed header.payload.signature string into your app, tests, or API client.
Questions and answers
What does this JWT generator do?
Which signing algorithms are supported?
Is the token signed in my browser?
How do I set an expiry time?
Can I edit the header and claims freely?
For AI agents: how to call this tool
Machine-readable contract, endpoints and examples. Humans can ignore this section.
Best Path For Builders
Browser workflow
Runs instantly in the browser with private local processing and copy/export-ready output.
Browser Workflow
This tool is optimized for instant in-browser execution with local data handling. Run it here and copy/export the output directly.
/jwt-generator/
For automation planning, fetch the canonical contract at /api/tool/jwt-generator.json.