The basic idea
Mining secures and updates Bitcoin's transaction history
Bitcoin needs a way to decide which valid transactions should be added to the blockchain and in what order.
Miners compete to produce the next block by performing proof-of-work.
The successful miner broadcasts a proposed block, but the block is not automatically trusted.
Bitcoin nodes independently verify the block and reject it if it breaks any of the network's consensus rules.
Simple definition
Bitcoin mining is the process of using computing power to compete for the right to propose the next valid block.
Miner responsibilities
What do Bitcoin miners do?
Mining involves more than creating new bitcoin.
Build candidate blocks
Miners select valid transactions from their mempools and arrange them into candidate blocks.
Perform proof-of-work
Mining machines repeatedly hash block data while searching for a result below the network target.
Broadcast blocks
A miner that finds a valid result broadcasts the proposed block to the Bitcoin network.
Receive rewards
A successful miner may receive newly issued bitcoin and the transaction fees included in the block.
Mining process
How a Bitcoin block is mined
A block moves through several stages before nodes accept it.
Transactions enter the mempool
Bitcoin nodes receive, verify and store valid unconfirmed transactions.
The miner selects transactions
The miner usually prioritises transactions offering competitive fee rates.
A candidate block is assembled
The miner creates a proposed block containing selected transactions and a special reward transaction.
Mining hardware begins hashing
Machines repeatedly change block data and calculate new hashes.
A valid hash is found
The miner succeeds when the resulting hash is below the target set by the network.
The block is broadcast
The successful miner sends the block to nodes across the network.
Nodes independently verify it
Nodes check the transactions, proof-of-work, block reward and every other relevant consensus rule.
The block joins the chain
Valid nodes accept the block and begin building or following work on top of it.
Cryptographic hashing
What is a hash?
A hash function takes input data and produces a fixed-size output.
Even a very small change to the input normally produces a completely different hash.
Bitcoin miners repeatedly modify parts of the block data and calculate new hashes.
They are searching for a hash that falls below the target set by the network.
Proof-of-work
Why is mining called proof-of-work?
Producing a valid block requires miners to perform large numbers of hash calculations.
Finding a valid result is difficult and costly, but checking the result is fast and easy for nodes.
The valid hash demonstrates that the miner spent computing resources and electricity.
This cost makes producing dishonest competing histories more difficult and expensive.
Mining difficulty
Why does mining become harder or easier?
Bitcoin aims to produce one block approximately every ten minutes on average.
When more mining power joins the network, blocks would be found more quickly if the difficulty remained unchanged.
Bitcoin therefore adjusts the mining target every 2,016 blocks—about two weeks at the intended block rate. The new difficulty is based on how long the previous 2,016 blocks actually took to mine.
If those blocks were found too quickly, mining becomes more difficult. If they were found too slowly, it becomes easier. This keeps block production near ten minutes on average; it does not guarantee that every block takes ten minutes.
Probability
Mining is a competition of chance and computing power
Every hash attempt is another chance to produce a valid result.
A miner with more hashrate can make more attempts per second, increasing the probability of finding a block.
However, no miner can know in advance which attempt will succeed.
A small miner could theoretically find the next block, but a larger miner has a higher probability over time.
Specialised equipment
What is an ASIC miner?
ASIC stands for application-specific integrated circuit.
A Bitcoin mining ASIC is designed specifically to perform Bitcoin's hashing calculations efficiently.
General-purpose computers and graphics cards are no longer competitive for modern Bitcoin mining.
ASIC machines can produce substantial heat and noise and usually require reliable electricity and ventilation.
Mining economics
Mining has significant operating costs
Mining profitability depends on several changing factors.
Electricity
Mining equipment consumes substantial electricity while continuously performing hashes.
Hardware
Competitive mining generally uses specialised machines called ASICs.
Cooling
Mining equipment produces significant heat that must be managed.
Maintenance
Machines can fail, become inefficient or require replacement as technology improves.
Miner incentives
How are miners rewarded?
A miner that produces a valid block can include a special transaction known as the coinbase transaction.
This transaction allows the miner to claim the permitted block subsidy and transaction fees.
Nodes verify that the miner has not claimed more than the rules allow.
A block attempting to create an excessive reward is rejected.
Block subsidy
New bitcoin issued according to Bitcoin's predetermined monetary schedule.
Transaction fees
Fees from the transactions included in the successfully mined block.
Monetary issuance
What is the Bitcoin halving?
The block subsidy is reduced by half every 210,000 blocks, which is approximately every four years.
This event is commonly called the halving.
The declining subsidy gradually reduces the rate at which new bitcoin enters circulation.
Over time, transaction fees are expected to become a larger part of miner revenue as the subsidy continues to decline.
Under Bitcoin's current rules, the subsidy is expected to reach zero at about the year 2140. This is often described as the point when the last bitcoin will be mined.
The precise calendar date cannot be guaranteed because the schedule is based on block height, while the time between blocks varies. Bitcoin already in circulation will continue to exist, and miners can still earn transaction fees after new issuance ends.
Shared mining
Why do miners join mining pools?
Finding a Bitcoin block is unpredictable.
A small miner operating alone might wait a very long time before finding one.
Mining pools combine the hashrate of many miners and distribute rewards according to the work each participant contributes.
This provides more regular payouts, although pool operators may charge fees and influence transaction selection.
Important distinction
Miners propose blocks, but nodes enforce the rules
Mining power does not give a miner unlimited authority over Bitcoin.
A miner may propose a block, but every node independently checks whether it follows the consensus rules.
A block that creates too much bitcoin, spends invalid outputs or lacks sufficient proof-of-work is rejected.
This separation between mining and verification is a central part of Bitcoin's design.
Network security
How mining helps secure Bitcoin
Proof-of-work makes rewriting confirmed transaction history expensive.
Miners compete independently to extend the valid blockchain.
The network can compare competing chains by the amount of accumulated work.
Attackers would need significant computing power and energy to attempt large-scale chain reorganisations.
Nodes still determine whether mined blocks follow Bitcoin's rules.
Energy use
Why does Bitcoin mining use electricity?
Proof-of-work requires miners to perform real computational work.
Electricity is a major cost of that work and makes block production difficult to fake.
Proof-of-work consumes substantial electrical energy. That energy cost is part of what makes competing transaction histories expensive to produce, but it also creates a real environmental and infrastructure trade-off.
The environmental impact depends on the scale, location, energy source, emissions and operating practices of mining activity. Energy use and carbon emissions are related, but they are not the same measurement.
Common misunderstandings
Mining concepts to remember
Miners do not create Bitcoin's rules
Miners propose blocks, but nodes reject blocks that violate the consensus rules they enforce.
Mining is not solving useful equations
Miners repeatedly perform hashing work to prove that computational resources were spent.
Finding a block is probabilistic
Greater hashrate improves the chance of finding a block, but no individual attempt guarantees success.
Bitcoin is not mined from the blockchain
New bitcoin is issued through a valid block's reward transaction according to the protocol rules.
More machines do not create faster blocks permanently
Bitcoin adjusts mining difficulty to keep the average block interval near ten minutes.
Miners cannot spend arbitrary bitcoin
Nodes verify ownership rules and reject unauthorised or invalid transactions.
Key terminology
Mining terms to understand
Hash
A fixed-size output created by running data through a cryptographic hash function.
Hashrate
The number of hashes mining equipment can attempt over a period of time.
Difficulty
A measurement describing how difficult it is to find a valid block.
Target
The numerical threshold that a valid block hash must fall below.
Nonce
A value miners change while attempting to produce a different block hash.
Block subsidy
Newly issued bitcoin that may be claimed by the miner of a valid block.
Transaction fees
Fees paid by users whose transactions are included in the block.
Mining pool
A group of miners who combine computing power and share rewards according to contributed work.
Knowledge check
Before continuing
What role do miners play in the Bitcoin network?
What is a cryptographic hash?
Why is Bitcoin mining called proof-of-work?
What is the mining target?
Why does Bitcoin adjust mining difficulty?
What is the difference between hashrate and difficulty?
How does a miner earn transaction fees?
What happens to the block subsidy during a halving?
Why do smaller miners often join mining pools?
Why can nodes reject a block produced by a miner?
Mining and difficulty adjustment
Proof of work targets a stable issuance rhythm
Connect candidate-block construction, nonce search, valid proof of work and the 2,016-block retarget.
Assemble
A miner builds a candidate block that must satisfy every consensus rule before proof of work matters.
Visual recap
How a block reaches the chain
Miners propose blocks using proof-of-work, but nodes decide whether those blocks satisfy Bitcoin's rules.
Valid transactions
Candidate block
Proof-of-work
Node validation
Chain extends
References
Further reading
From the 21Relay Library
Recommended reading for this lesson
Optional books selected to reinforce this topic or provide a useful second perspective.
Recommended nextInventing BitcoinYan PritzkerBeginner · Short · EssentialA first technical book about Bitcoin
Another perspectiveBitcoin: A Peer-to-Peer Electronic Cash SystemSatoshi NakamotoIntermediate · Short · EssentialReading Bitcoin's original proposal in its own wordsLesson summary
Key takeaways
Miners assemble valid transactions into candidate blocks.
Mining uses proof-of-work to compete for the right to propose the next block.
Miners repeatedly calculate hashes while searching for a result below the target.
Bitcoin adjusts difficulty to maintain an average block interval near ten minutes.
Modern Bitcoin mining generally uses specialised ASIC hardware.
Mining rewards consist of the block subsidy and transaction fees.
The block subsidy is reduced approximately every four years during the halving.
Mining pools combine hashrate and distribute rewards among participants.
Miners propose blocks, while nodes independently enforce Bitcoin's rules.
Proof-of-work makes altering confirmed transaction history expensive.