# Hash text with SHA-1 / 256 / 384 / 512

> Compute a SHA-family hash of any text, with the algorithm of your choice, live as you type.

Open the tool: https://yourbrowsercandoit.com/hash-text

SHA-1, SHA-256, SHA-384, SHA-512 of any text. Free, no signup. Runs entirely in your browser; files are never uploaded.

## How it works

Type or paste the text and pick an algorithm: SHA-1 (20-byte digest, deprecated for security but still common), SHA-256 (32-byte, modern standard), SHA-384, or SHA-512. The result is a hex string, computed via the Web Crypto API. Live update with a small debounce so fast typing doesn't thrash the hasher. SHA-1 is included for legacy use cases (file checksums in older systems, git's internal hash) but should not be used for new security applications because collisions are known. SHA-256 is the modern default. SHA-512 produces a longer digest but isn't more secure than SHA-256 for most purposes, just slower. For hashing files, use the Hash file tool, which streams over the file's bytes.

## How to use it

1. **Type or paste your text.** The hex digest updates live with a small debounce.
2. **Pick an algorithm.** SHA-256 is the modern default; SHA-1 only for legacy compatibility.
3. **Copy the digest.** The output matches shasum and openssl dgst on the same input — computed entirely in your browser.

## Frequently asked questions

### Should I use SHA-1?

Only for legacy compatibility. For security (anything someone might try to forge), SHA-256 or above. SHA-1 has known collision attacks.

### What's the difference between SHA-256 and SHA-512?

SHA-512 produces a longer digest (128 hex chars vs 64). It's not more secure for typical use; it's just bigger. On 64-bit CPUs, SHA-512 can be slightly faster than SHA-256.

### Is the text uploaded?

No. Hashing runs in your browser via Web Crypto. Text and digest stay local.

### Are these the same hashes I'd get from shasum?

Yes. The output matches shasum -a 256 (or 1, 384, 512) and openssl dgst on the same input.

## Related tools

- [JSON to CSV](https://yourbrowsercandoit.com/json-to-csv): Turn JSON into a CSV table, nested fields and all.
- [CSV to JSON](https://yourbrowsercandoit.com/csv-to-json): Convert CSV to a JSON array, with live preview.
- [Password generator](https://yourbrowsercandoit.com/password-generator): Generate strong random passwords with crypto entropy.
- [Password strength](https://yourbrowsercandoit.com/password-checker): Check password strength with zxcvbn-style heuristics.
- [JSON formatter](https://yourbrowsercandoit.com/json-formatter): Format, validate and fix JSON, with a tree view.
- [Regex tester](https://yourbrowsercandoit.com/regex-tester): Test regular expressions with live highlighting.
