Skip to developer tool
DEVELOPER TOOLKIT SECURITY & ENCODING

SHA Hash Generator

Generate a digest in the representation an API or workflow expects. Hash exact file bytes or UTF-8 text, choose an output encoding and explicitly choose the newline bytes for text.

Browser-based · No account required · Copy and export

BUILT FOR THE DETAILS
  1. 01Add your input
  2. 02Inspect & adjust
  3. 03Use your result
Browse developer tools
PIXELOKAY · LOCAL CRYPTOGRAPHIC WORKSPACE

Digest & integrity studio

Know the exact bytes. Create SHA digests and reusable integrity reports without uploading your data.

Local processing · Web Crypto

01 · Source

Text source · UTF-8
UTF-8 · no trimming · selected newline settings apply
Text byte settings & algorithm options

Textareas do not preserve original file line endings. Use File mode when byte-exact file hashing is required.

02 · Digest result

Copy · verify · export

No current digest

An unkeyed hash match is not proof of publisher identity.

Input byte preview (up to 48 bytes)
SHA digests are not encryption, authentication signatures or password-storage hashes. SHA-1 is legacy and not collision-resistant for modern security-sensitive uses. Native Web Crypto hashing buffers up to 50 MiB per file, not unlimited streaming.

How to use SHA Hash Generator

  1. Choose an algorithm and explicitly select Text, One file, or Batch. Selecting a file automatically activates File mode; switch to Text or clear the file to use typed text.
  2. Choose hex, Base64 or Base64URL output. For text only, choose LF or CRLF newline bytes.
  3. Generate and inspect the digest and source-byte information. Clear a file selection to return to text input, then copy or download.

When to use this tool

Generate a digest for a text fixture or local file in the representation a system expects. This tool offers multiple digest representations and a trusted-reference comparison field; use File Checksum Calculator for a dedicated verification workflow.

The algorithm and representation are independent

A SHA digest is a sequence of bytes. Hex, Base64 and Base64URL display those same bytes differently; they are not different hash algorithms. Text is first encoded as UTF-8. The textarea normalizes entered line breaks; the explicit LF/CRLF setting determines the bytes used for hashing and can change the digest. File mode always hashes the selected file's exact bytes without that text transformation.

Worked example

Text: abc
SHA-256 hexadecimal:
ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad
The same digest can be represented as Base64 or Base64URL.

Match digest representation as well as the input bytes

  1. For an authored fixture workflow, choose SHA-256 and enter a short nonsecret text passage. Select LF or CRLF according to the receiving system.
  2. Generate and inspect hexadecimal, Base64 or Base64URL as required. These are representations of digest bytes, not separate hash algorithms.
  3. File mode hashes the selected file; Text mode hashes the text field instead. Use Clear file selection before returning to the text exercise; the newline option does not rewrite file bytes.
  4. Copy/download the representation the recipient expects. Base64URL uses its URL-safe alphabet and omits trailing padding.

When comparing against a published hexadecimal checksum, changing the display to Base64 does not produce a different underlying digest. Compare matching algorithms and representations instead of treating differently written digests as a file-content change.

Authored procedure, no newly calculated hash. This is digest generation with encoding choices; Checksum Calculator supplies the separate expected-hash comparison workflow. Neither proves origin without a trusted reference.

Limits and output checks

Web Crypto requires a secure or suitable local context. Files are limited to 50 MiB each. Native Web Crypto digest is non-streaming; the browser holds each file in memory for hashing. SHA-1 is a legacy option. These fast unkeyed hashes are not password-storage functions, HMAC signatures or proof of file authenticity without a trusted comparison.

Reference: Web Crypto digest API.

Frequently asked questions

Why are text and file hashes different?

A file can contain a byte-order mark, another encoding or extra newlines. Text mode hashes the browser text encoded as UTF-8.

What does Base64URL change?

It uses URL-safe characters and removes trailing padding for display. The underlying digest bytes are unchanged.

Is the newline setting applied to files?

No. It only affects text mode. File hashing uses the original bytes.

Text bytes and original file bytes differ

Choose text or file mode and the intended digest representation. Compare the same encoding and newline convention when matching a known value.

Scope of this workflow

A file may contain a byte-order mark or different line endings. An unkeyed digest alone is not a signature or proof of origin.

File Checksum Calculator — SHA-256 & SHA-512 · All developer tools · Privacy policy · Contact PixelOkay