Cryptographic Foundations

Bitcoin's Algorithmic
Building Blocks

Theory, mathematics, and working code — everything you need to understand the cryptographic primitives that make Bitcoin trustless, secure, and verifiable.

4
Complete
3
Coming Soon
Cryptographic Algorithms
✓ Complete

SHA-256

Bitcoin's primary hash function. Every block header, every transaction ID, every Merkle tree leaf passes through SHA-256. Understand how 512-bit message blocks are compressed into a 256-bit digest through 64 rounds of bitwise operations.

256-bit output 64 rounds SHA-2 family Merkle–Damgård
Block hashing Transaction IDs Merkle trees Mining PoW
✓ Complete

RIPEMD-160

Applied after SHA-256 to produce shorter, more compact Bitcoin addresses (the HASH160 operation). Its 160-bit output strikes a balance between security and address brevity, using parallel processing of 80 rounds across two independent pipelines.

160-bit output 80 rounds HASH160 P2PKH
Address generation P2PKH scripts HASH160
✓ Complete

ECDSA secp256k1

The digital signature algorithm that proves you own bitcoins without revealing your private key. Built on elliptic curve cryptography over the secp256k1 curve — the same curve chosen by Satoshi for its efficient computation and well-understood security.

256-bit keys 64-byte sigs secp256k1 ECC
Transaction signing Ownership proof Public keys
✓ Complete

HMAC-SHA512

The keyed hash function at the core of HD wallet derivation (BIP32) and seed generation (BIP39). By combining a secret key with the SHA-512 hash function, HMAC produces authentication codes that are computationally infeasible to forge without the key.

512-bit output BIP32 BIP39 HMAC-RFC2104
HD wallets Seed derivation Key stretching
Coming Soon
Base58Check
Human-readable address encoding with built-in checksum
Soon
Bech32 / Bech32m
SegWit & Taproot native address format (BIP173 / BIP350)
Soon
Schnorr / Taproot
Linear signatures enabling key aggregation and script privacy
Soon
Thank you for your feedback! 🙏