Crypto & Web3 · Explainer
How Bitcoin mining works
Mining Bitcoin means competing to produce the next block in the chain. Here is what miners compute, how the network keeps the pace of one block every ten minutes and why its energy use divides opinion.
- Author:
- Redação Token & Tech
- Responsible editor:
- Daniel Ferreira
- Translation:
- Redação Token & Tech
Published · 9 min read
Originally published in Brazilian Portuguese.
Translated from the Portuguese original with AI assistance.
Also available in: Português
Key points
- Miners test billions of variations of the block header until they find a hash below a target; whoever finds it first earns the subsidy and the fees.
- Every 2,016 blocks the network recalculates the difficulty to keep the average at one block every 10 minutes, with a limit of four times per adjustment.
- Mining today uses dedicated chips and is concentrated in a few pools; energy use is estimated at hundreds of TWh per year, with opposing assessments of its impact.
When someone says they are “mining bitcoin”, they are not extracting anything. They are putting computers to compete for the right to record the next block of transactions. The winner receives new bitcoins and the fees paid by users.
This article explains what miners compute, how the network adjusts difficulty, the role of pools and hardware and what the sources say about energy. For general context, see what Bitcoin is and how the Bitcoin blockchain works.
What mining is for
Satoshi Nakamoto’s whitepaper starts from a problem: without an intermediary, how do you ensure no one spends the same coin twice? The answer is a public ledger in which everyone agrees on the order of transactions (Bitcoin whitepaper).
Mining does three things at once:
- It orders transactions. Each accepted block fixes a batch of transactions at a position in the chain.
- It makes history expensive to alter. Changing an old block would require redoing its work and that of all subsequent blocks.
- It distributes new coins. Without an issuing authority, bitcoins enter circulation as a reward to miners. The issuance rule is covered in why Bitcoin has a fixed supply.
Proof of work, step by step
The mechanism is called proof of work. The whitepaper describes it as scanning for a value that, when hashed with a function such as SHA-256, produces a result beginning with a certain number of zero bits. A hash is a fixed-size “fingerprint” of any data: changing a single character of the input changes the result unpredictably.
In practice, the process is this:
- The miner assembles a candidate block with pending transactions.
- It builds the block header, an 80-byte summary that includes the hash of the previous block, a summary of the transactions and a numeric field called the nonce.
- It computes the hash of the header. If the result is less than or equal to a target value set by the network, the block is valid (Bitcoin Developer Guide, “Blockchain”).
- If not, it changes the nonce and tries again. And again, billions of times per second.
There is no shortcut: the only way to find a valid hash is to try. But checking is instantaneous. According to the whitepaper, the work required grows exponentially with the number of zeros, and verification takes a single hash. This asymmetry is the heart of the system.
When a miner finds a valid block, it broadcasts it to the network. Nodes check that all transactions are valid and start building the next block on top of it.
Voting with processing power
The whitepaper sums up proof of work as “one CPU, one vote”. The chain considered valid is the one that has accumulated the most work. As long as most of the processing power is held by honest participants, that chain grows faster than any attempt to rewrite it.
The flip side is the risk known as a 51% attack: whoever controlled the majority of processing power could, for example, reverse their own recent transactions. The whitepaper argues that, in that case, it would be more profitable for the attacker to follow the rules than to undermine the system and the value of their own wealth. It is an argument about economic incentives, not a technical impossibility.
Difficulty adjustment
If more machines join the network, blocks would be found faster. To keep the pace, the network periodically adjusts the target. The whitepaper already anticipated this: difficulty follows a moving average to maintain an average number of blocks per hour.
In Bitcoin Core, the mainnet parameters are a target interval of 10 minutes per block and a two-week window (Bitcoin Core, chainparams.cpp). Two weeks divided by 10 minutes gives 2,016 blocks. Every 2,016 blocks, each node measures how long the last period took (Bitcoin Core, pow.cpp):
- if it took less than two weeks, difficulty goes up;
- if it took longer, difficulty goes down;
- in a single adjustment, the change is limited to four times harder or four times easier.
The Developer Guide notes a curiosity: because of an old bug, the calculation uses the timestamps of 2,015 blocks rather than 2,016, which creates a small distortion kept for compatibility.
To give an idea, on October 8, 2026, the mempool.space explorer showed the current period averaging about 9.5 minutes per block and estimated an increase of about 5.7% in difficulty at the next adjustment, at block 971,712 (mempool.space, difficulty adjustment). It is an estimate that changes with every block.
The effect of the adjustment is important: the number of machines does not change the speed of issuance. More miners mean more competition for the same number of blocks.
The reward: subsidy and fees
The first transaction in each block, the coinbase, pays the miner. It adds up two parts:
- the subsidy, the new bitcoins in that block, currently 3.125 BTC, which is halved every 210,000 blocks (see Bitcoin halving);
- the fees from the included transactions: when a transaction spends more than it sends, the difference can be collected by the miner (Bitcoin Developer Guide, “Blockchain”).
Nodes check this amount. If the coinbase pays more than subsidy plus fees, the block is rejected (Bitcoin Core, validation.cpp). In addition, the amount received can only be spent after 100 blocks, in case the block ends up being discarded.
Today, the reward comes almost entirely from the subsidy. In the 1,008 blocks up to block 970,487 (about one week, through October 8, 2026), fees totaled about 19.3 BTC, close to 0.6% of the total reward (mempool.space, reward statistics). This percentage varies with demand for block space. Because the subsidy falls with each halving, the weight of fees tends to grow proportionally, but how much they will be worth in the future is uncertain.
The hardware
The whitepaper talks about CPUs, a computer’s ordinary processor. Today, mining uses ASICs, chips designed for a single function: computing SHA-256 hashes as fast as possible. The Developer Guide describes the flow: the mining software sends the 80-byte header to the ASIC, which tests nonce values until it finds a hash below the target (Bitcoin Developer Guide, “Mining”).
The guide also points out a detail: the nonce is 4 bytes, which allows about 4 billion attempts. Modern machines exhaust that in a fraction of a second, so the miner also changes an extra field in the coinbase transaction to generate new headers.
The scale is hard to imagine. On October 8, 2026, mempool.space estimated the network’s total processing power at about 989 EH/s, or nearly 10²¹ hashes per second (mempool.space, mining pools). It is an estimate derived from block frequency, not a direct measurement.
Mining pools
With this much competition, a solo miner may go a long time without finding any block. The answer is pools: groups that combine processing power and share the reward.
According to the Developer Guide, the pool sets a much easier target for its members than the network’s. Each result that hits this target counts as a share, proof that the miner did their part of the work. When a share also hits the network target, it becomes an actual block. The reward is split roughly in proportion to shares. The result is smaller, more frequent payments, with less variance than solo mining.
The guide describes two common protocols:
- getblocktemplate: the miner receives the suggested transactions and can choose which to include;
- Stratum: the miner receives only the minimum needed to build headers and does not choose the transactions. The pool operator decides.
This difference has consequences. In the year up to October 8, 2026, the three largest pools produced about 59% of blocks: Foundry USA (28.3%), AntPool (18.1%) and F2Pool (12.5%). The top five together accounted for about 77% (mempool.space, mining pools). A pool does not own its members’ machines, and miners can switch pools. Even so, the concentration of block assembly in a few operators is a frequent point of concern in discussions about the network.
The energy debate
Computing nearly 10²¹ hashes per second consumes a lot of electricity. How much, where it comes from and whether it is justified are questions with divergent answers.
Cambridge’s most recent figures. The Cambridge Centre for Alternative Finance (CCAF) at the University of Cambridge published a report on the mining industry in April 2025. The estimate is 138 TWh per year, about 0.5% of global electricity consumption, and 39.8 million tonnes of CO2 equivalent (Cambridge Judge Business School, April 2025). According to the survey, 52.4% of the energy came from sustainable sources (42.6% renewables and 9.8% nuclear), 38.2% from natural gas and 8.9% from coal, compared with 36.6% from coal in 2022.
There are important caveats. The network-wide figures are extrapolated from data from 49 companies covering 48% of global activity, and the answers come from the miners themselves. The companies surveyed are concentrated in the United States, with 75.4% of the reported activity.
A critical assessment. A study published in the journal Earth’s Future in October 2023, by Sanaz Chamanara, Arman Ghaffarizadeh and Kaveh Madani, looked at 2020–2021 and arrived at a different picture (AGU, October 2023). The estimate was 173 TWh, 86 million tonnes of carbon and 1,870 km² of affected land, with 67% of the energy coming from fossil fuels and 45% from coal. The press release from AGU, the journal’s publisher, describes the impacts on land and water as “very worrying”, and the study’s title calls for “urgent action”.
The two studies cover different periods and methods, and should not be compared as if they measured the same thing. The difference may reflect real changes in the geography and energy mix of mining as well as methodological choices; the sources consulted do not allow the two to be separated.
The proponents’ argument. The FAQ page on bitcoin.org states that spending energy to secure and operate a payment system is “hardly a waste”, and that miners have an incentive to become more efficient (Bitcoin.org, FAQ). In the logic of proof of work, energy expenditure is precisely what makes rewriting history expensive.
In the newsroom’s assessment, both sides agree on the technical essentials: consumption is high and proportional to the competition among miners. The disagreement lies in the value assigned to what that consumption protects and in the weight given to the source of the energy.
Risks for those thinking of mining
This article does not assess whether mining is worthwhile, and no generic answer would do. But the risks are well known and apply to any person or company:
- Difficulty is only predictable for two weeks. If more machines join the network, your share of the reward shrinks, even if nothing changes on your side.
- The subsidy halves every 210,000 blocks. The next cut is at block 1,050,000; by the newsroom’s estimate, with blocks every 10 minutes, this would happen around 2028.
- The price of bitcoin is highly volatile. The reward is paid in bitcoin, but energy, equipment and rent are paid in local currency (in Brazil, reais). Sharp drops can make the operation loss-making, and the asset’s value can fall for a prolonged period.
- Equipment ages quickly. ASICs are only good for mining, and more efficient models reduce the competitiveness of older ones.
- There is counterparty risk. Pools, hosting services and “cloud mining” platforms hold or pass on rewards. If they fail or are fraudulent, you can lose everything you invested. Offers with guaranteed returns should be treated with suspicion.
- Local rules change. Energy tariffs, taxation and regulation vary by country and can change.
Key takeaways
- Mining is testing billions of variations of a block header until finding a hash below a target. Finding it is hard; checking it is instantaneous.
- Every 2,016 blocks, the network recalculates the difficulty to keep the average at 10 minutes per block. More machines do not speed up issuance.
- The reward combines subsidy and fees. In October 2026, fees were about 0.6% of the total, and the subsidy halves every 210,000 blocks.
- Mining uses dedicated chips and is concentrated in a few pools: three of them produced about 59% of blocks in the past year.
- Energy use is estimated at hundreds of TWh per year. Cambridge points to an increasingly sustainable mix; other studies highlight the weight of fossil fuels. The figures are estimates and depend on period and method.
Sources
- Bitcoin: A Peer-to-Peer Electronic Cash System, Satoshi Nakamoto (bitcoin.org). Accessed October 8, 2026
- Bitcoin Core: src/pow.cpp (ajuste de dificuldade), Bitcoin Core. Accessed October 8, 2026
- Bitcoin Core: src/kernel/chainparams.cpp (parâmetros da rede principal), Bitcoin Core. Accessed October 8, 2026
- Bitcoin Core: src/validation.cpp (GetBlockSubsidy e checagem bad-cb-amount), Bitcoin Core. Accessed October 8, 2026
- Blockchain: Bitcoin Developer Guide, Bitcoin Project (developer.bitcoin.org). Accessed October 8, 2026
- Mining: Bitcoin Developer Guide, Bitcoin Project (developer.bitcoin.org). Accessed October 8, 2026
- Mempool.space API: participação dos pools de mineração no último ano, mempool.space. Accessed October 8, 2026
- Mempool.space API: estatísticas de recompensa dos últimos 1.008 blocos (blocos 969.480 a 970.487), mempool.space. Accessed October 8, 2026
- Mempool.space API: ajuste de dificuldade, mempool.space. Accessed October 8, 2026
- Cambridge study: sustainable energy rising in bitcoin mining, Cambridge Judge Business School / Cambridge Centre for Alternative Finance. Published April 28, 2025 · Accessed October 8, 2026
- Bitcoin mining has "very worrying" impacts on land and water, not only carbon, American Geophysical Union (AGU). Published October 24, 2023 · Accessed October 8, 2026
- Frequently Asked Questions, Bitcoin.org. Accessed October 8, 2026
Educational content. Not investment advice. This article is educational and informative. It is not a personalized recommendation to buy, sell or hold any asset. Crypto-assets and tokenized assets carry risks, including total loss; rules vary by jurisdiction.