So how do you decide who gets to write to the ledger? The answer is: competitive Proof of Work, where you waste computing power to demonstrate your commitment.4
A new block of transactions is created every ten minutes or so, with 12.5 bitcoins (BTC5) reward attached as incentive, plus any fees on the transactions. Bitcoin miners (analogous to gold miners) apply as much brute-force computing power as they can to take the prize in this block’s cryptographic lottery.
(The mining reward halves every four years – it started at 50 BTC, went to 25 BTC in 2012 and 12.5 BTC in 2016 – and will stop entirely in 2140. There will only ever be 21 million bitcoins.)
Satoshi Nakamoto, Bitcoin’s creator, needed a task that people could compete to waste computing power on, that would give one winner every ten minutes.
The difficulty would need to automatically adjust, as computing power joined and left, to keep block creation steady at about one every ten minutes.
What he came up with was: Unprocessed transactions are broadcast across the Bitcoin network. A miner collects together a block of transactions and the hash of the last known block. They add an arbitrary “nonce” value, then calculate the hash of the resulting block. If that hash satisfies the current difficulty criterion, they have mined a block! This successful block is then broadcast to the network, who can quickly verify the block is valid. The miner gets 12.5 BTC plus the transaction fees. If they failed, they pick another nonce value and try again.6
Since it’s all but impossible to pick what data will have a particular hash, guessing what value will give a valid block takes many calculations – as of June 2017 the Bitcoin network was running 5,500,000,000,000,000,000 (5.5×1018, or
5.5 quintillion) hashes per second, or 3.3×1021 (3.3 sextillion) per ten minutes.
The 3.3 sextillion calculations are thrown away, because the only point of all this technical rigmarole is to show that you can waste electricity faster than everyone else.
Obviously, the competition gets viciously Darwinian very quickly. Mining rapidly converges on 1 BTC costing 1 BTC to generate. The ensuing evolutionary arms race, as miners desperately try for enough of an edge to turn a profit, is such that Bitcoin’s power usage is on the order of the entire power consumption of Ireland.7
This electricity is literally wasted for the sake of decentralisation; the power cost to confirm the transactions and add them to the blockchain is around $10-20 per transaction. That’s not imaginary money – those are actual dollars, or these days mostly Chinese yuan, coming from people buying the new coins and going to pay for the electricity. An ordinary centralised database could calculate an equally tamper-evident block of transactions on a 2007 smartphone running off USB power. Even if Bitcoin could replace conventional currencies, it would be an ecological disaster.
So why bother with all of this? Ideology. From day one, Bitcoin was about pushing politics.