HMAC Generator
Generate secure HMAC codes using SHA-256, SHA-512, BLAKE3, and more. 100% private, client-side generation with support for Hex and Base64 inputs.
How to Use
The HMAC Generator allows you to create secure Message Authentication Codes using a secret key and a cryptographic hash function.
How to use this tool
- Select Algorithm: Choose a hash function from the dropdown (e.g., SHA-256 for standard security or BLAKE3 for high performance).
- Enter Secret Key: Provide your private authentication key. You can also click "Generate" to create a cryptographically strong random key.
- Enter Message: Paste the text or data you wish to sign.
- Verify Output: The HMAC will be calculated instantly in your browser. You can view the result in hex format.
- Integration Snippets: Look at the bottom of the page for ready-to-use implementation code for Node.js and Python.
About This Tool
What is an HMAC?
HMAC (Hash-based Message Authentication Code) is a specific type of message authentication code involving a cryptographic hash function and a secret cryptographic key. It is used to simultaneously verify both the **data integrity** and the **authenticity** of a message.
Any change to the message or the secret key will result in a completely different HMAC, making it an essential component of secure API authentication, webhooks, and session management (like JWTs).
Why Use This Tool
Safe & Secure by Design
Handling authentication keys requires extreme care. Most online tools send your secret keys to their servers for processing, which is a major security risk. Our generator runs **100% client-side**. Your keys and messages never leave your machine, ensuring that your secrets remain truly secret.