Hash
Also: digest, hash function
cryptography · beginner
A fixed-size fingerprint of arbitrary data. One-way: easy to compute, infeasible to reverse.
A cryptographic hash function takes input of any length and produces a fixed-length output — for Bitcoin, that output is 256 bits (32 bytes) of SHA-256. The same input always produces the same output. Change one bit of input and the output looks unrelated.
Three properties make hashes useful: one-way (you can't work backward from the output to the input), collision-resistant (you can't practically find two inputs that produce the same output), and deterministic (everyone computes the same hash for the same input).
Bitcoin uses SHA-256 hashes everywhere: identifying blocks, identifying transactions, building the merkle root, deriving addresses, and — most famously — as the puzzle miners solve. The proof-of-work target is "produce a block header whose double-SHA-256 hash, read as a number, is less than X." There's no shortcut; you just keep trying.
Hashing is not encryption. Encryption is reversible with a key; hashing isn't reversible at all. That asymmetry is what makes hashes a one-way commitment device.