Calculate a SHA or MD5, or an HMAC with SHA or MD5

HEX-encoded result:
Base64-encoded result:
  1. The hex and base64 results shown by this page are different encodings that represent the same value.
  2. If you specify a key for HMAC, the key is used only for HMAC calculation, and never leaves your browser.
  3. Here are a few test cases:
    SHA-256abc-- (hex) ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad
    (b64) ungWv48Bz+pBQUDeXa4iI7ADYaOWF3qctBD/YfIAFa0=
    HMAC-sha256 abcsecret (hex) 9946dad4e00e913fc8be8e5d3f7e110a4a9e832f83fb09c345285d78638d8a0e
    (b64) mUba1OAOkT/Ivo5dP34RCkqegy+D+wnDRShdeGONig4=
  4. Just a reminder, base64-encoded values are case sensitive. Hex-encoded results are not. This is characteristic of the encodings, not special to this page, or to hash functions or HMACs.
  5. For message content, Whitespace in the content is significant. Line-breaks will be converted to newline (\n). It's not possible to paste in a carriage-return (CR), because this page strips them. Trailing newlines will not be stripped. And remember, the sha256 for 'abc\n' is completely different from the sha256 for 'abc'.
  6. Unicode is ok. The calculator will encode the string as UTF-8 bytes before computing the checksum. UTF-8 ought to be good enough for anybody. :)