HMAC Generator
Generate HMAC-SHA1, HMAC-SHA256, HMAC-SHA384, and HMAC-SHA512 message authentication codes using the Web Crypto API.
Selected digest (HMAC-SHA256)
All algorithms
About This Tool
Computes Hash-based Message Authentication Codes (HMAC) using the browser native Web Crypto API (crypto.subtle.sign). Generates the selected primary digest and displays all four SHA variants (SHA-1, SHA-256, SHA-384, SHA-512) side by side.
Accepts secret keys as UTF-8 text, hexadecimal bytes, or Base64 strings, and formats the resulting MAC as lowercase hex, uppercase hex, Base64, or URL-safe Base64.
Key Features
- Native Web Crypto: Uses crypto.subtle.importKey and crypto.subtle.sign directly in your browser with zero external libraries.
- Four HMAC algorithms: Computes HMAC-SHA256, HMAC-SHA384, HMAC-SHA512, and HMAC-SHA1 simultaneously.
- Flexible key encodings: Provide your secret key as plain UTF-8 text, raw hex bytes, or Base64-encoded binary.
- Multiple output formats: Export digests as lowercase hex, uppercase hex, standard Base64, or URL-safe Base64.