Hashing
Last Updated: November 19, 2026
Hashing is the process of running data through a hash function to get a short, fixed-length result called a hash. Blockchains use hashing to link blocks, check transactions, secure mining and hide public keys, because the same input always gives the same output and any change gives a completely different one.
How Hashing Works
A hash function reads the input, whether it is a transaction, a message or a whole file, and mixes its bits through many fixed rounds. The output always has the same length. Good functions are one-way: computing a hash takes a fraction of a second, but working backward from the hash to the input is not practical.
Not every hash function is safe for security. A cryptographic hash function must also make it impractical to find two inputs with the same output. Bitcoin uses SHA-256 for most of its hashing, and Ethereum uses Keccak-256.
How Blockchains Use Hashing
- Linking blocks: each block header stores the hash of the previous block, so editing an old block breaks every later link.
- Mining: proof-of-work miners hash block headers again and again, changing a number called the nonce, until a hash falls below the network’s target.
- Addresses: many Bitcoin addresses hold a 160-bit hash of the public key, made with SHA-256 and then RIPEMD-160.
- File checks: Bitcoin Core publishes the SHA-256 hashes of its downloads, so users can confirm a file was not changed.
Hashing also builds a Merkle tree in every block. Transactions are hashed in pairs, then the results are hashed again, until one root hash remains in the header. Light wallets use that root to check that a payment is in a block without downloading the whole block.
Example: Bitcoin Hashing on November 16, 2026
Bitcoin mining is hashing at enormous scale. At 19:10 UTC on November 16, 2026, mempool.space estimated the network hashrate at about 975.5 EH/s, or roughly 975 quintillion double SHA-256 attempts per second. At the current difficulty of about 134.8 trillion, finding one block takes about 580 sextillion hashes on average.
Block 976,170, mined at 18:36 UTC, shows the result. Its winning nonce was 2,675,311,566, and its hash starts with 20 zeros. Any node can check that work with a single double hash, while producing it took the whole network about ten minutes.
Hashing vs Encryption
| Feature | Hashing | Encryption |
|---|---|---|
| Can it be reversed? | No | Yes, with the right key |
| Uses a key? | No | Yes |
| Output size | Fixed, such as 256 bits for SHA-256 | Grows with the input |
| Main job | Prove data has not changed | Keep data secret |
| Crypto examples | TXIDs, mining, addresses | Encrypted wallet backups |
Where to Check It
To see hashing for yourself, paste a transaction ID or block hash into an explorer such as mempool.space or Etherscan. To hash a file, use sha256sum on Linux, shasum -a 256 on macOS or certutil -hashfile with SHA256 on Windows, then compare the result with the hash a wallet publisher lists.
Limits and Risks
Hashing only proves that data matches. It does not hide data that is easy to guess, and it does not prove who created it, which is the job of digital signatures. Old functions such as MD5 and SHA-1 are broken for security use, and NIST plans to phase out SHA-1 completely by December 31, 2030.
Quantum computers are a smaller threat to hashing than to signatures. Grover’s algorithm would roughly halve the strength of a hash function against brute-force search, so SHA-256 would keep about 128 bits of protection. An IETF guide from June 2026 says hash functions face a lower risk than public-key cryptography.
The Avalanche Effect in Practice
A tiny change to the input changes the whole hash. This is called the avalanche effect. Here are the SHA-256 hashes of two words that differ only in their first letter.
- hello:
2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824 - Hello:
185f8db32271fe25f561a6fc938b2e264306ec304eda518007d1764826381969
The two results share no visible pattern. Compared bit by bit, 125 of the 256 bits are different, close to the half you would expect by chance. This is why a hash can flag even a one-letter change in a file or a transaction.
Hash Functions Used by Major Coins
- SHA-256: Bitcoin mining and transaction IDs. Bitcoin Cash uses it too.
- Keccak-256: Ethereum addresses, transaction hashes and smart contract storage.
- RIPEMD-160: shortens public key hashes in many Bitcoin addresses.
- Scrypt: mining on Litecoin and Dogecoin, designed to need more memory.
- BLAKE2b: the base of Equihash, Zcash’s mining puzzle, and used widely in Polkadot.
Each choice reflects a trade-off between speed, hardware and security. You can read more on SHA-256 and the nonce that miners change on every try.
Frequently Asked Questions
What is hashing used for in crypto?
Hashing links each block to the one before it, powers proof-of-work mining, builds the Merkle trees that sum up transactions and turns public keys into shorter addresses. It also gives every transaction and block its ID. Outside blockchains, it checks downloaded files and protects stored passwords, since the original data never has to be kept.
Can hashing be reversed?
No. A good hash function is one-way, so there is no method to compute the input from the output. The only option is to guess inputs and compare the results. That works for short or common inputs, such as weak passwords, but not for random data like a private key or a block of transactions.
Is hashing the same as encryption?
No. Encryption is designed to be undone by someone holding the right key, and its output grows with the input. Hashing uses no key, always gives a fixed-length result and cannot be undone. Crypto systems use hashing to prove data is unchanged and encryption to keep data, such as wallet backups, private.
Why does Bitcoin hash data twice?
Bitcoin runs SHA-256 twice for block headers and transaction IDs, a method often called double SHA-256. A common explanation is that the second round guards against a weakness called a length extension attack, which affects a single round of SHA-256. Satoshi Nakamoto never explained the choice in writing, so the exact reason is still debated.
Data sources: mempool.space (hashrate, difficulty and block 976,170, read at 19:10 UTC, November 16, 2026); NIST (SHA-1 retirement plan, December 15, 2022); IETF RFC 9958 (June 2026); Bitcoin Core download page (SHA256SUMS); SHA-256 example hashes computed with a standard SHA-256 tool (November 19, 2026).