Interactive blockchain demos to accompany the textbook. Explore hashing, blocks, chains, distributed consensus, tokens, and coinbase transactions hands-on.
This section has been forked and inspired from work from Professor Anders Brownworth, check his work at andersbrownworth.com
Type anything below and watch the SHA-256 hash update in real time. Notice how even a tiny change produces a completely different hash.
Watch video explainerA block bundles a block number, nonce, and data. The hash must start with "0000" to be valid. Click Mine to find a valid nonce.
Watch video explainerEach block's "Prev" field contains the previous block's hash, chaining them together. Tampering with any block invalidates all subsequent blocks.
Watch video explainerThree peers each hold an identical copy of the blockchain. Modify a block on one peer and see how it diverges from the others.
Watch video explainerInstead of free-form data, blocks now contain financial transactions (value, sender, recipient). Altering any transaction breaks the chain.
Watch video explainerMiners earn a coinbase reward for each block. This is how new currency enters the system. Observe how coinbase transactions differ from regular transfers.
Watch video explainerGenerate a private key and see the corresponding public key derived from the secp256k1 elliptic curve. The private key is a large number; the public key is a point on the curve.
Watch video explainerSign a message with your private key, then verify it with the public key. This proves authorship without revealing the private key.
Watch video explainerSign a financial transaction (amount, from, to) with your private key. The "from" field is your public key. Anyone can verify the signature without your private key.
Watch video explainerA full blockchain where every transaction is cryptographically signed. Each transaction includes a sequence number and signature that can be independently verified.
Watch video explainer