Developer Tools
HMAC Generator
Create HMAC signatures with SHA-256, SHA-512, SHA-1 or MD5 from a message and secret key, as hex or Base64 — for webhooks and API signing.
How to use
- 1Enter the secret key and choose the algorithm.
- 2Paste the message (e.g. the raw webhook body) and compare the signature.
How it's calculated
HMAC(K, m) = H((K ⊕ opad) ‖ H((K ⊕ ipad) ‖ m)) as defined in RFC 2104.
Frequently asked questions
What is HMAC used for?
Proving a message came from someone with the shared secret and wasn't changed — e.g. Stripe, GitHub and Shopify webhook signatures.
Why doesn't my webhook signature match?
Sign the exact raw request body, byte for byte. Re-serialized JSON, changed whitespace or a different encoding breaks the match.
Is my secret key sent anywhere?
No. The HMAC is computed in your browser; neither the key nor the message leaves your device.
Worked example: HMAC Generator
With the message "The quick brown fox jumps over the lazy dog" and the secret key "key", HMAC-SHA256 produces f7bc83f430538424b13298e6aa6fb143ef4d59a14946175997479dbc2d1a3cd8 — a published RFC test vector, so you can verify this tool's output with `openssl dgst -sha256 -hmac key` on the same message and get an identical hex string. Switch to HMAC-MD5 with the same inputs and you get an entirely different, shorter signature (80070713463e7749b90c2dc24911e275): the algorithm, not just the key, fundamentally changes the output, which is why an API's webhook documentation always specifies exactly which hash algorithm its signatures use.
Why HMAC needs a key and a plain hash doesn't
A plain hash (MD5, SHA-256) is a public, keyless function — anyone can compute the hash of a message, which makes it useless for proving who sent something. HMAC mixes a secret key into the computation (RFC 2104's construction nests the key with the message through the hash function twice), so only someone who knows the shared secret can produce a signature that matches. This is exactly how Stripe, GitHub and Shopify authenticate webhook deliveries: they sign the request body with a secret only you and they know, and you recompute the same HMAC on your end to confirm the request genuinely came from them and wasn't tampered with in transit.
The one mistake that breaks almost every webhook signature check
A signature verification failure is almost never a bug in the HMAC math — it's almost always that the bytes being signed don't exactly match the bytes the sender actually signed. If a webhook handler parses the incoming JSON and then re-serializes it before computing the HMAC, even identical-looking JSON can produce different bytes (key order, whitespace, number formatting can all differ), and the signature will never match. The fix is always the same: sign and compare against the exact raw request body, byte for byte, before any parsing touches it — which is also why this tool treats its input as raw text rather than trying to parse or reformat it.
The secret opens empty, and both encodings are always shown
Secret key opens blank, so the first signature I see is for an empty secret until I type one. Algorithm opens on SHA-256. Hex is the headline and Base64 is always shown under it. There is no uppercase switch on this tool, so the hex stays lowercase. Changing the algorithm replaces both lines at once. The message is whatever is in the main box, taken as raw text, including spaces. I do not get a choice to hash without a key. Even a blank key is still a key, and it produces a different signature from a key of a single character.
Related tools
- Hash Generator (MD5, SHA-1, SHA-256, SHA-512)
Generate MD5, SHA-1, SHA-224, SHA-256, SHA-384, SHA-512 and CRC32 checksums of any text, instantly and privately in your browser.
- CSV to SQL INSERT Generator
Generate SQL CREATE TABLE and INSERT statements from CSV data for MySQL, PostgreSQL, SQLite or SQL Server.
- JSON to TypeScript / Go Types
Generate TypeScript interfaces or Go structs from sample JSON — nested objects, arrays and optional fields inferred automatically.
- JSON Schema Generator
Generate a JSON Schema (draft 2020-12) from sample JSON — types, nested objects, arrays, required fields and formats like email, date-time and URI.
- Dockerfile & docker-compose Generator
Generate a production-ready Dockerfile and docker-compose.yml for Node.js, Python or static sites — with PostgreSQL, MySQL, Redis or MongoDB services.
- Nginx Config Generator
Generate an nginx server block for a static site, SPA or reverse proxy — with HTTPS (Let's Encrypt paths), HTTP→HTTPS and www redirects, gzip and caching.