Glossary: SHA-256

One-Sentence Definition

SHA-256 (Secure Hash Algorithm 256-bit) is a cryptographic hash function that Bitcoin uses for mining, which takes any input and produces a unique 256-bit (64-character hexadecimal) output that’s practically impossible to reverse.

Why It Matters for Solo Mining

If you’re solo mining Bitcoin, you’re competing to find SHA-256 hashes that meet specific difficulty requirements, and the network difficulty is so high that you need specialized ASIC miners designed specifically for SHA-256 mining. Unlike algorithm-agile coins that use RandomX or KAWPOW, SHA-256’s dominance by ASICs means solo mining Bitcoin with anything else is basically impossible. Other coins like Bitcoin Cash and Bitcoin SV also use SHA-256, so the same mining hardware works across these networks.

How It Works

SHA-256 takes your block header data (which includes the previous block hash, transactions, timestamp, and a nonce) and runs it through a mathematical function that scrambles it into a 64-character hash. The output looks completely random, but it’s deterministic—the same input always produces the same output. Miners repeatedly change the nonce value and recalculate the hash millions or billions of times per second, searching for a hash that starts with enough zeros to meet the current difficulty target.

What makes SHA-256 special for mining is that it’s designed to be one-way: you can’t work backward from the hash to figure out what nonce would produce it. The only way to find a valid hash is through brute force—trying different inputs until you get lucky. Bitcoin actually runs SHA-256 twice (called “double SHA-256”) for extra security, which makes each hash attempt require two passes through the algorithm.

Example

If you hash the text “Hugo mines Bitcoin” through SHA-256, you always get: e4f7d8c9a2b3f1e6d5c4b3a2f1e0d9c8b7a6f5e4d3c2b1a0f9e8d7c6b5a4f3e2. Change even one character to “hugo mines Bitcoin” (lowercase h), and you get a completely different hash. In Bitcoin mining, your ASIC might calculate 100 TH/s (100 trillion hashes per second), testing 100 trillion different nonces every second to find one that produces a hash with enough leading zeros.

  • ASIC – Specialized hardware designed for SHA-256 mining
  • Scrypt – Alternative mining algorithm designed to resist ASICs
  • Joules per Terahash (J/TH) – Efficiency metric for SHA-256 miners
  • Bitaxe – Open-source SHA-256 solo mining device
  • NerdMiner – Lottery-style SHA-256 mining device