The Problem: Who Keeps the Record?
Imagine your class runs a snack stand. Somebody has to write down every sale and every payout in a notebook. That notebook is a ledger, which is just a running list of records kept in order.
Now here is the awkward question. Who holds the notebook?
If one person holds it, everyone else has to trust that person completely. They could erase a line. They could add a line that never happened. They could lose the whole thing. Even if they are perfectly honest, you have no way to prove it, and that is the real problem. Trust that cannot be checked is not much better than a guess.
The usual fix is to pick an authority everybody agrees to trust: a bank, a school office, a company's servers. That works fine most of the time, and it is why banks exist. But it means the authority gets to decide what the record says.
Blockchain asks a different question: could we build a shared record that nobody controls, but where everyone can still tell if it has been changed?
The answer turns out to be yes, and it does not require trusting anyone. It requires two ideas working together: a math tool called a hash, and a clever way of stringing records together so that editing the past leaves obvious fingerprints. The rest of this page builds those two ideas from scratch.
Hashing: A Fingerprint for Data
A hash function is a program that takes in any amount of data (a word, a paragraph, an entire movie file) and spits out a short scrambled code of a fixed length. That output is called a hash, and you can think of it as a fingerprint for the data.
The one used almost everywhere is called SHA-256. It always returns 64 characters, no matter what you put in. Here is what makes it useful:
- It is consistent. The same input always produces the exact same hash, on any computer, forever.
- It looks random. The output tells you nothing about the input just by looking at it.
- It is a one-way trip. Given a hash, there is no practical way to work backwards and recover the original data.
- Tiny changes explode. Change one letter of the input and the entire output changes. This is the important one.
That last property has a name: the avalanche effect. You would expect a small change to make a small difference. It does not. Look at these two sentences, which differ by a single character, and their real SHA-256 hashes:
Not one character in common. That is the whole trick. If you save a hash of something today, you can check tomorrow whether the something has been touched: run the hash again, and if you get a different fingerprint, the data changed.
This is not a simulation. Your browser has SHA-256 built in, and the code on this page calls it directly. Type below and watch the fingerprint change.
SHA-256 hash
Change one letter. Add a space. Delete the period. The 64 characters above scramble completely every time.
Your browser did not make its built-in cryptography tools available here, so this demo cannot run. It normally works in any current browser on a secure connection.
People mix these up constantly. Encryption scrambles data so that someone with the right key can unscramble it later. Hashing has no key and no way back: it turns data into a fingerprint and that is it. You use encryption to hide things. You use hashing to check whether things changed.
What Is Actually Inside a Block
A block is one page of the ledger. It is not mysterious. It is a small bundle holding four things:
- The data. Whatever the ledger is tracking. On a cryptocurrency it is a batch of transactions. On a shipping ledger it might be "Pallet 44 arrived in Denver."
- A timestamp. When the block was created.
- The previous block's hash. A copy of the fingerprint of the block that came right before this one. This is the link in the chain.
- Its own hash. The fingerprint you get by hashing all three items above together.
Read item 4 again, because it is the part that does the work. A block's own hash is not computed from its data alone. It is computed from its data plus its timestamp plus the previous block's hash, all mashed together and run through SHA-256.
So a block's fingerprint depends on the block before it. And that block's fingerprint depended on the block before it. Every block quietly carries a summary of the entire history behind it.
The very first block has no block before it, so its "previous hash" is just a placeholder, usually a string of zeros. That first block has a name: the genesis block.
Chaining Blocks Makes Tampering Obvious
Now put the blocks in a row, each one storing the hash of the block before it. That row is the blockchain. The name is literal: it is a chain of blocks, held together by hashes.
Checking whether the chain is honest is easy. Walk down the list. For each block, ask one question: does the previous hash I have stored actually match the hash of the block before me? If every answer is yes, the chain is intact. One no, and something was tampered with.
Here is why that is so hard to cheat. Suppose block 2 says "Ana pays Ben 5 credits," and somebody wants it to say 500 instead. They edit the text. Watch what falls over:
- Block 2's data changed, so block 2's own hash changes completely (avalanche effect).
- Block 3 stored the old hash of block 2. That stored value no longer matches. Block 3's link is broken.
- Anyone checking the chain sees the mismatch instantly.
The cheater's next move is obvious: fix block 3 by storing the new hash. But block 3's own hash is computed from its previous-hash field, so block 3's hash changes too. Now block 4 is broken. Fix block 4 and you break block 5. The damage rolls forward all the way to the end of the chain.
Changing one old record means redoing every single record that came after it. That property has a name: the chain is tamper-evident.
Be precise with the words. Nothing stops you from editing your own copy of a blockchain. What the design guarantees is that the edit cannot be hidden. A blockchain does not prevent tampering, it makes tampering impossible to disguise, the way a broken seal on a package does not stop someone from opening it but does tell you they did.
Break a Chain Yourself
Reading about it only gets you so far. Below is a real four-block chain running in your browser. Every hash you see is a genuine SHA-256 hash, computed live from that block's data, timestamp, and stored previous hash. Nothing is faked and nothing leaves your computer.
Start by editing the data in Block 1 or Block 2. Then watch what happens below it.
- Timestamp
- 2026-03-02 09:14
- Previous hash
- 0000000000000000...
- This block's hash
- computing...
- Timestamp
- 2026-03-02 09:31
- Previous hash
- computing...
- This block's hash
- computing...
- Timestamp
- 2026-03-02 10:02
- Previous hash
- computing...
- This block's hash
- computing...
- Timestamp
- 2026-03-02 10:47
- Previous hash
- computing...
- This block's hash
- computing...
Chain intact. Every block's stored previous hash matches the block above it.
Hashes are shortened to their first 16 characters so they fit on screen. The real ones are 64 characters long.
Your browser did not make its built-in cryptography tools available here, so this demo cannot run. It normally works in any current browser on a secure connection.
What You Just Saw
Editing Block 2 changed Block 2's hash. Block 3 was still storing the old value, so its link snapped, and Block 4 sits behind a broken link, so it cannot be trusted either. One tiny edit invalidated the rest of the chain.
Then "Fix the chain" relinked them one at a time. Notice it had to work through every block after the edit, not just the next one, because repairing a block changes that block's own hash and breaks the next link in turn. In this toy version that took a fraction of a second. Read on for why it is not that easy in the real world.
You edit the data in Block 2. Why does that break Block 3 and Block 4, instead of only Block 3?
Right. A block's hash is calculated from its data, its timestamp, and its stored previous hash. Touch any of those three and the block's fingerprint changes, which breaks the next block's link. That is why the damage rolls forward instead of stopping at one block.
Not quite. Blocks do not store each other's data, and the timestamps are untouched. The real reason is the cascade: a block's hash is computed partly from its stored previous hash, so repairing Block 3's link changes Block 3's own fingerprint, which breaks Block 4, which would break Block 5, all the way to the end.
Distributed Ledgers: Thousands of Copies
The chain by itself is only half the design. If a blockchain lived on one computer, an attacker with access to that computer could rewrite every block and hand you a chain that checks out perfectly. Tamper-evidence is useless when the tamperer controls the only copy.
So blockchains are usually distributed. Distributed means the whole ledger is copied onto many independent computers, often thousands of them, spread across the world. Each computer is called a node, and each node keeps its own full copy. There is no head office holding the real one. They are all the real one.
When someone wants to add a block, they broadcast it to the network. Every node checks it against the rules and against its own copy of the chain. If the block checks out, nodes add it. If it does not, they throw it away. That agreement process is called consensus, which is just a formal word for the network deciding together which version of history is correct.
Why That Makes Cheating So Much Harder
Now redo the attack. To rewrite an old block and get away with it, you would have to:
- Recompute that block's hash, plus every block after it, all the way to the present.
- Do it faster than the honest network is adding new blocks, because the chain keeps growing while you work.
- Convince a majority of thousands of independent nodes to throw out their copy and accept yours instead.
Any one node that still has the honest chain can point at your version and say the hashes do not line up. On a large public network, that combination is expensive enough that nobody bothers.
Some blockchains make step two deliberately slow. In systems that use proof of work, adding a block requires solving a hard math puzzle by guessing over and over until you find an answer that produces a hash starting with a required number of zeros. Finding that answer takes an enormous amount of computing. Checking it takes a fraction of a second. That asymmetry, hard to do and easy to verify, is what makes rewriting old blocks financially pointless.
Anyone can download a copy of a public blockchain like Bitcoin's and check it themselves. Companies also build private blockchains, where only invited organizations run nodes. Private chains are faster and cheaper, but they trade away some of the point: if one company controls most of the nodes, you are back to trusting that company.
A blockchain is copied across 5,000 computers. You change one block on your own copy and carefully redo every hash after it so your chain passes its own check. What happens?
Exactly. An internally consistent chain is not enough. Your rewritten chain has to match what everyone else already has, and it does not. The network compares copies and keeps the one the majority agrees on, so your edit gets ignored.
Not quite. You genuinely can edit your own copy, and you can make the hashes line up again if you redo all of them. What stops you is everyone else: 4,999 other nodes still hold the original, they compare notes, and the odd copy out gets rejected.
Where Blockchain Is Actually Used
Blockchain gets talked about a lot, and much of that talk is exaggerated. Here is a plain summary of where the technology genuinely shows up today.
Cryptocurrency
This is the original use and still by far the biggest. A cryptocurrency such as Bitcoin is a system where the blockchain records who transferred what to whom. The ledger replaces the bank: instead of a bank confirming your balance, the shared chain does.
The reason it needed blockchain is a problem called double spending. Digital files copy perfectly, so what stops someone from sending the same digital coin to two people at once? A shared, tamper-evident, ordered ledger does, because the network sees the first transfer and rejects the second.
Cryptocurrency prices swing wildly, plenty of people have lost money in them, and the space attracts a lot of scams. Understanding how the technology works is genuinely worth your time. Deciding whether to buy anything is a separate question, one this page is not answering, and one you should not take from social media either.
Supply Chain Tracking
Some food and shipping companies log the journey of goods on a shared ledger, so a grocery store, a farm, and a shipper are all reading the same record instead of emailing spreadsheets around. When a food safety recall happens, tracing a contaminated batch back to its source can go from days to seconds. The wins here are real but narrower than early marketing promised.
Records and Certificates
Some governments and universities publish a hash of official documents (land deeds, diplomas, transcripts) onto a blockchain. Nobody puts the actual document on the chain. They post its fingerprint, so anyone holding a copy can hash it and confirm it matches the version that was published on that date. That is a small, sensible use of exactly what hashing is good at.
Smart Contracts
Some blockchains can store small programs, called smart contracts, that run automatically when conditions are met. They are not legal contracts and they are not smart. They are code that executes on the network without anyone able to quietly change it afterwards.
What Blockchain Cannot Do
Understanding a technology means knowing its limits, and blockchain has several serious ones. Anyone who describes it as a fix for everything has not thought carefully about it.
It Cannot Tell If Something Is True
This is the big one. A blockchain guarantees that a record has not been altered since it was written. It says nothing at all about whether the record was accurate when it went in.
If a worker scans a crate of ordinary coffee and labels it "organic, fair trade," the blockchain will faithfully preserve that lie forever, and preserve it with impressive mathematical certainty. Garbage in, permanent garbage. The gap between the physical world and the digital record is where most real-world blockchain projects run into trouble.
Some Systems Use Enormous Amounts of Energy
Proof of work is secure precisely because it wastes effort, and at global scale that adds up. Bitcoin's network has at times consumed about as much electricity per year as a mid-sized country. Newer designs such as proof of stake reach agreement a different way and use a tiny fraction of the energy, so this is not true of every blockchain, but it is a genuine cost of the most famous one.
It Is Slow and Expensive Compared to a Database
Making thousands of computers agree on every entry is much slower than writing to one ordinary database. A regular payment network handles tens of thousands of transactions per second. Bitcoin handles single digits.
Most Problems Do Not Need It
Blockchain is worth its costs only when you have all three of these at once: several parties who need to share a record, no authority they all trust, and a real need to prove nothing was altered. Miss any one of those and a normal database is faster, cheaper, simpler, and easier to fix when someone makes a mistake.
That is the honest summary. Blockchain is a clever, specific tool built from two ideas you now understand: hashes as fingerprints, and chains that make edits impossible to hide. Knowing what it does well, and what it does not do at all, is what separates understanding it from repeating what you heard about it.