# SHA-256

From Trezor Wiki

**SHA-256** (Secure Hash Algorithm) is a cryptographic hash (sometimes called ‘digest’). SHA-256 is a member of the SHA-2 cryptographic hash functions designed by the NSA. Cryptographic hash functions are mathematical operations run on digital data, SHA-256 generates an almost-unique 256-bit (32-byte) signature for a text. By comparing the computed "hash" (the output from execution of the algorithm) to a known and expected hash value, a person can determine the data's integrity. A one-way hash can be generated from any piece of data, but the data cannot be generated from the hash.

eg. 'ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad' is a SHA-256 hash for text 'abc'

## SHA-256 in Bitcoin

SHA-256 is used in several different parts of the Bitcoin network:

- Mining uses SHA-256 as the Proof of work algorithm.
- SHA-256 is used in the creation of bitcoin addresses to improve security and privacy.