Comment utiliser : JWT Encoder
- Choose the signing algorithm — HS256 for a shared secret, RS256 or ES256 for a private key.
- Edit the payload JSON and add claims such as
iatandexpwith the buttons. - Enter the secret, or paste a PKCS#8 private key for RS/PS/ES algorithms.
- Copy the encoded token, or open it in the decoder to inspect it.
How a JWT is built
A JSON Web Token (RFC 7519) has three Base64url parts separated by dots: header.payload.signature. The signature is computed over the first two parts, so any change to the header or claims invalidates it. The payload is only encoded, not encrypted — anyone can read it, so never put secrets in a JWT.
Choosing an algorithm
| Algorithm | Key | When to use |
|---|---|---|
| HS256 / HS384 / HS512 | Shared secret (HMAC) | One service both issues and verifies tokens |
| RS256 / RS384 / RS512 | RSA private key, public key to verify | Many services verify; widest library support (OAuth, OpenID Connect) |
| PS256 | RSA with PSS padding | Like RS256 with a more modern padding scheme |
| ES256 / ES384 | EC private key (P-256 / P-384) | Short signatures and keys; Apple and many modern APIs |
Registered claims
ississuer,subsubject (user ID),audaudienceiatissued at,nbfnot before,expexpiry — all in seconds since 1970 (Unix time; see the timestamp converter)jtiunique token ID, useful for revocation lists
Secrets and keys
RFC 7518 requires HMAC keys at least as long as the hash: 32 random bytes for HS256. Short human-readable secrets can be cracked offline from a single token. Private keys must be in PKCS#8 PEM (BEGIN PRIVATE KEY); convert older formats with openssl pkcs8 -topk8 -nocrypt. Inspect existing tokens with the JWT decoder.
Aussi recherché comme : jwt generator, create jwt, jwt encode, sign jwt online, jwt builder, generate jwt token, rs256 jwt.
Outils complémentaires : JWT Encoder
- RSA Key Generator — Create a public/private key pair for JWT signing, TLS testing, encryption experiments or SSH — generated by your browser’s Web Crypto API and never sent anywhere.
- HMAC Generator — Compute keyed HMAC signatures for API requests and webhooks, and check whether a received signature is valid — using your browser’s Web Crypto API.
- Encodage / Décodage Base64 — Convertissez du texte au format Base64 et inversement, avec une prise en charge complète de l'UTF-8 (accents, emojis) ; passez au format Base64 compatible URL, ou glissez-déposez un fichier pour obtenir sa chaîne Base64 ou son URI de données.
- Hash Generator — Compute MD5 and SHA hashes of any text or file instantly, create HMAC signatures, and paste an expected checksum to verify a download.
Questions fréquentes
Is it safe to create JWTs here?
Why does RS256 reject my private key?
openssl pkcs8 -topk8 -nocrypt -in key.pem.