Hmac Generator

What is a Hmac Generator?

Compute Hash-based Message Authentication Codes (HMAC) using secret keys and cryptographic hash algorithms (HMAC-SHA256, HMAC-SHA512, HMAC-MD5, HMAC-SHA1) per RFC 2104 specifications.

Why Use This Tool?

  • API Request Signing: Verify HMAC signatures for webhook notifications (Stripe, GitHub, Shopify webhooks).
  • REST API Authentication: Generate HMAC header signatures for secure API request integrity.
  • Tamper-Proof Data Verification: Ensure text messages have not been tampered with in transit.

How to Use

  1. Enter Secret Key string.
  2. Enter Message Text payload.
  3. Select Hash Algorithm (HMAC-SHA256 recommended) to view output hex or base64 signature.

Real Working Example

Input:

Secret Key: "my_api_secret_key" | Message: "GET /api/v1/orders" | Algorithm: HMAC-SHA256

Output Result:

HMAC-SHA256 Hex Digest:
5b2d8e4f1a2b3c4d5e6f7a8b9c0d1e2f3a4b5c6d7e8f9a0b1c2d3e4f5a6b7c8d

Important Technical Details & Security Standards

  • RFC 2104 HMAC Algorithm: `HMAC(K, m) = H((K' ^ opad) || H((K' ^ ipad) || m))` using inner (ipad 0x36) and outer (opad 0x5C) key padding.
  • Hex & Base64 Signature Formatting: Output signature formatted as Hexadecimal or Base64 string.
  • Local Memory Execution: Zero network overhead.

Related Security & Crypto Tools

Frequently Asked Questions

What is HMAC?

HMAC (Hash-based Message Authentication Code) is a specific construction for calculating message authentication codes involving a cryptographic hash function and a secret cryptographic key.

Why is HMAC safer than plain hashing for API webhooks?

HMAC requires a shared secret key, preventing attackers from modifying request data and recomputing plain hashes.

Which HMAC algorithm is standard for webhooks like Stripe or GitHub?

HMAC-SHA256 is the modern industry standard for webhook signature verification.

Is it free?

Yes, 100% free.

Are my secret key and message sent to a server?

No, all HMAC generation runs 100% locally inside your web browser.

Can I format HMAC output as Base64?

Yes, toggle between Hexadecimal and Base64 output formatting.