HMAC-SHA256 Generator
Generate an HMAC-SHA256 Signature
Need to use HMAC-SHA256 Generator right now?
HMAC-SHA256 is the exact algorithm behind JWT's HS256 signing — this computes it directly, verified against the official RFC 4231 reference test vectors.
Features
- Runs entirely in your browser
- Privacy-first — your data is never uploaded
- Real-time, instant results
- 100% free, no sign-up required
- Works on desktop, tablet, and mobile
- No installation needed
Who uses this tool?
About HMAC-SHA256 Generator
HMAC (Hash-based Message Authentication Code) combines a secret key with a hash function to prove both that a message hasn't been altered and that it came from someone who knows the shared secret — a plain hash alone only proves integrity, not authenticity, since anyone could recompute a plain hash without knowing any secret.
This tool computes HMAC signatures using your browser's native Web Crypto API across SHA-1, SHA-256, SHA-384, and SHA-512, verified against the standard RFC 4231 test vectors for correctness. Enter a secret key and a message, and the signature updates automatically.
HMAC is the backbone of a huge amount of real infrastructure: webhook payload verification (confirming a webhook actually came from the service that claims to have sent it), API request signing, JWT signing (the 'HS256' algorithm is literally HMAC-SHA256), and OAuth 1.0a request signing — anywhere two parties share a secret and need to verify message authenticity without exchanging the secret itself.
This is useful for testing webhook signature verification during development, debugging API signing implementations by comparing computed signatures against expected values, understanding how JWT HS256 signatures are actually computed, and learning HMAC mechanics hands-on.
How it works
- Enter a secret key. The shared secret both parties would use to sign and verify.
- Choose a hash algorithm. SHA-1, SHA-256, SHA-384, or SHA-512.
- Enter the message. The HMAC signature computes automatically as you type.
Examples
Computing HMAC-SHA256 for a test message
Input
Secret: "secret", Message: "message"
Output
8b5f48702995c1598c573db1e21866a9b825d4a794d169d7060a03605796360