A blockchain is a shared record of transactions that is stored on many computers at once. New entries are grouped into blocks, and each block is cryptographically linked to the one before it. Because of that link, changing an old record means redoing everything that came after it, which the rest of the network would reject. Blockchains are the technology behind Bitcoin, Ethereum and nearly every other cryptocurrency.
A Short History
The idea of chaining timestamped records together with cryptography dates to work by Stuart Haber and Scott Stornetta in 1991. The first working blockchain came with Bitcoin. On October 31, 2008, the pseudonymous Satoshi Nakamoto published the Bitcoin whitepaper, which described a peer-to-peer electronic cash system that needed no bank. The Bitcoin network started running in January 2009.
Ethereum launched in July 2015 and extended the idea. Its blockchain stores and runs programs called smart contracts in addition to recording payments.
How a Blockchain Works
A transaction goes through these steps:
- A user creates a transaction and signs it with a private key. The signature proves the user controls the funds.
- The transaction is broadcast to the network, where computers called nodes check it against the rules.
- Valid transactions are collected into a block by a miner or validator.
- The block includes a hash of the previous block. A hash is a short fingerprint of data: change the data even slightly and the fingerprint changes completely.
- Other nodes verify the new block and add it to their copy of the chain.
The hash link is what forms the chain. If someone altered a transaction in an old block, that block's hash would change. It would no longer match the reference stored in the next block, and every later block would be invalid. Bitcoin's developer documentation on the block chain describes this structure in detail.
Thousands of nodes hold a full copy of the ledger. No single one is the master copy. A node that receives a block breaking the rules simply rejects it.
Consensus Mechanisms
All nodes must agree on which block comes next. The method they use is called a consensus mechanism. The ethereum.org page on consensus mechanisms covers the main types.
- Proof of Work: miners compete to solve a computational puzzle. The winner adds the next block and earns a reward. Rewriting history would require more computing power than the rest of the network combined. Bitcoin uses it. It is secure but uses a lot of energy.
- Proof of Stake: validators lock up coins as collateral and are chosen to propose and confirm blocks. Dishonest validators can lose part of their stake. Ethereum has used it since September 2022. It needs far less energy than Proof of Work.
Solana combines Proof of Stake with Proof of History, a cryptographic clock that helps order transactions quickly. Proof of History is a timing tool. It is not a consensus mechanism by itself.
Key Properties
- Decentralized: many independent parties run the network, so no single one controls it.
- Tamper-resistant: changing confirmed history is extremely expensive on large networks. It is not strictly impossible, and small chains are easier to attack.
- Transparent: on public blockchains, anyone can inspect every transaction.
- Pseudonymous: addresses are strings of characters, not names. They are not anonymous, since activity can often be traced to a person.
- Permissionless: on public chains, anyone can send transactions or run a node without approval.
The Blockchain Trilemma
Designers face a tradeoff among security, decentralization and scalability. Improving one tends to cost another. Bitcoin favors security and decentralization, and processes only a few transactions per second. Solana favors speed and low fees, and requires more powerful hardware to run a validator. Ethereum keeps its base layer conservative and moves much of its activity to Layer 2 networks such as Arbitrum and Base.
Types of Blockchains
- Public: open to anyone. Bitcoin and Ethereum are examples.
- Private: run by one organization, which controls who can read and write. Frameworks such as Hyperledger Fabric are used for this.
- Consortium: shared among a group of selected organizations.
Blockchain vs a Traditional Database
A traditional database is run by one organization, which can edit, delete or restrict records. It is fast and efficient, but users have to trust the operator.
A blockchain spreads control across many participants. It is slower and more expensive per transaction, because every node repeats the work. It suits cases where parties that do not trust each other need a shared record, such as digital money and asset ownership. Where a trusted central party already exists, a normal database is usually the better tool.
Limits and Risks
- Transactions are irreversible. Funds sent to the wrong address or to a scammer cannot be recalled.
- Security depends on keys. Whoever holds the private key controls the funds, and a lost key cannot be reset.
- A secure chain does not make every application on it safe. Smart contract bugs and bridge hacks have caused large losses.
- A blockchain cannot verify that data entered from the outside world is true.
- Small networks can be attacked by anyone who gains a majority of the mining power or stake.
Common Misconceptions
- Blockchain and Bitcoin are not the same thing. Bitcoin is one application of the technology.
- Records are not encrypted or hidden by default. On most public chains, everything is visible.
- Putting data on a blockchain does not make it accurate. It only makes it hard to change.
Nothing in this article is financial advice.
Track on CoinMarketGuy
The Bitcoin price page and the Ethereum price page show live prices, market caps, supply and charts for the two largest blockchains. The homepage shows total market cap, volume and the Fear and Greed reading.