Bitcoin Mining

Updated: September 27, 2025

What is Bitcoin mining (brief)
– Bitcoin mining is the collective process that secures the Bitcoin network and records transactions by having devices compete to find a cryptographic solution that meets a difficulty target. The first device to find a valid solution adds a new block to the blockchain and receives newly issued bitcoin plus transaction fees.

Key definitions (first-use jargon explained)
– Hash: the fixed-size output (a 64‑digit hexadecimal string for Bitcoin) produced by applying the SHA‑256 hashing algorithm to block header data. Small input changes produce completely different hashes.
– SHA‑256: the hashing algorithm Bitcoin uses to convert block data into a hash.
– Nonce: a counter (“number used once”) that miners change on each attempt to produce a different hash.
– Target hash / difficulty target: the threshold a block hash must be equal to or lower than for the block to be accepted. Difficulty is the compact measure that controls how hard it is to find such a hash.
– Proof‑of‑Work (PoW): a consensus method where miners demonstrate they expended computational work by producing a hash under the target.
– Block reward: newly created bitcoin given to the miner who finds the valid block (plus transaction fees). The subsidy halves periodically (“halving”) until the supply limit is reached.
– Mining pool: a group of miners that combine computational power and share rewards proportionally to increase steady earnings.

How mining works — step by step
1. Construct a candidate block: collect pending transactions, the previous block’s hash, a timestamp, and other header fields.
2. Compute a hash: run the block header

…through the SHA‑256 algorithm twice to produce a 256‑bit hash. Compare that hash to the current network target (a numeric threshold set by the difficulty). If the hash is lower than the target, the candidate block is valid and can be broadcast to the network. If not, change a field in the header (usually the nonce; if the nonce space is exhausted, change the coinbase or timestamp) and repeat the hashing loop until a valid hash is found.

3. Broadcast and verification: when a miner finds a valid block, they broadcast it. Other nodes verify the block’s header, transactions, and proof‑of‑work. If valid, nodes add the block to their local copy of the blockchain.

4. Reward and propagation: the winning miner includes a coinbase transaction that awards the block reward (newly minted bitcoin) plus collected transaction fees to themselves (or to the pool’s payout address). The network then continues mining the next block on top of the new tip.

Difficulty adjustment (retarget)
– Retarget rule: Bitcoin adjusts mining difficulty every 2,016 blocks (~14 days) so that the average time between blocks stays near 10 minutes. New difficulty = old difficulty × (actual_time_for_2016_blocks / 20160 minutes). The protocol limits abrupt changes, so extreme swings are smoothed.
– Practical meaning: higher difficulty => lower chance for any fixed miner to find a block; difficulty scales proportionally to the total network hashing power.

Hardware and efficiency
– Evolution: CPUs → GPUs → FPGAs → ASICs. ASICs (application‑specific integrated circuits) are now dominant because they deliver dramatically higher hashes per second (H/s) per watt.
– Metrics: hash rate (H/s, TH/s for terahashes, EH/s for exahashes) and energy efficiency (jou

les per terahash (J/TH). Lower J/TH means better energy efficiency and lower electricity use for a given hash rate. Power (in watts) = hash rate (TH/s) × efficiency (J/TH). Example: a 100 TH/s machine at 30 J/TH consumes 100 × 30 = 3,000 W (3.0 kW).

Mining pools and payout methods
– Why pools exist: Solo mining has high variance — an individual miner with a tiny share of network hash power may wait years for a single block. Pools aggregate miners so participants receive steadier, proportional payouts.
– Common payout schemes:
– PPS (Pay‑Per‑Share): fixed payment per submitted share; lowest variance for miners but higher risk/cost for pool operator.
– PPLNS (Pay‑Per‑Last‑N‑Shares): pays based on recent shares; aligns payouts with pool luck and generally lowers operator risk.
– Proportional: shares counted per round; payout proportional to shares in that round.
– Practical step: compare pool fees (typical 0.5–2%), payout threshold, reputation, and payment method before joining.

Rewards, fees, and the halving schedule
– Block reward components: (1) block subsidy (new BTC created) and (2) transaction fees paid by users. Total reward per block = subsidy + fees.
– Halving: block subsidy halves every 210,000 blocks (≈ every 4 years). This reduces newly minted BTC over time and is predictable by protocol rules.
– Mining revenue per day (BTC) can be estimated:
Expected BTC/day = (your_hash / network_hash) × blocks_per_day × reward_per_block
where blocks_per_day ≈ 144.
– Then convert to fiat: revenue_usd/day = expected_BTC/day × BTC_price_usd.

Worked numeric example (illustrative)
Assumptions:
– Your miner: 100 TH/s.
– Efficiency: 30 J/TH → power = 100 × 30 = 3,000 W = 3.0 kW.
– Electricity price = $0.10 per kWh.
– Network hash rate = 200 EH/s = 200,000,000 TH/s.
– Block reward = 3.125 BTC (example).
– BTC price = $30,000.
Calculations:
1) Your share of network = 100 / 200,000,000 = 5.0e‑7.
2) Expected BTC/day = 5.0e‑7 × 144 × 3.125 = 0.000225 BTC/day.
3) Revenue/day (USD) = 0.000225 × $30,000 = $6.75.
4) Energy use/day = 3.0 kW × 24 h = 72 kWh → electricity cost/day = 72 × $0.10 = $7.20.
5) Net result = $6.75 − $7.20 = −$0.45 per day (a loss in this scenario).
Notes: small changes in BTC price, network hash rate, efficiency

—a small change in any of these can flip profitability quickly. Using the example above, here are a few immediate, practical calculations and checks you can run yourself.

Breakeven BTC price (same hardware and network)
– Formula: BTC_price_break_even = electricity_cost_per_day / BTC_mined_per_day.
– Using BTC_mined_per_day = 0.000225 BTC and electricity_cost_per_day = $7.20:
– BTC_price_break_even = 7.20 / 0.000225 = $32,000.
– Interpretation: with the given hash share and power use, BTC must reach about $32,000 for daily revenue to equal electricity cost (ignoring fees and other expenses).

Required miner efficiency to break even at current BTC price
– Goal: find the power (kW) that makes electricity cost = current revenue ($6.75/day at $30,000/BTC).
– Formula: power_kW = revenue_per_day / (24 h × electricity_price_per_kWh).
– Using revenue_per_day = $6.75 and electricity_price_per_kWh = $0.10:
– power_kW = 6.75 / (24 × 0.10) = 6.75 / 2.4 = 2.8125 kW (2,812.5 W).
– Convert to W per TH (for 100 TH): W_per_TH = 2812.5 W / 100 TH = 28.125 W/TH.
– Interpretation: to break even at BTC = $30,000 you’d need ~28.1 W/TH instead of 30 W/TH.

Payback example (capital cost)
– If a miner costs $6,000, and daily net result = −$0.45 (loss), payback is not achievable unless conditions change.
– If BTC rises to $35,000: revenue/day = 0.000225 × 35,000 = $7.875 → net/day = 7.875 − 7.20 = $0.675 profit/day.
– Payback period = 6,000 / 0.675 ≈ 8,889 days ≈ 24.4 years (ignores difficulty increases, maintenance, taxes).
– Interpretation: even modest profits per day can imply very long payback times.

Sensitivity checks (quick mental math)
– If network hash rate doubles, your share halves → BTC/day halves → revenue halves.
– If pool fees of 1% apply, subtract 1% from BTC_mined_per_day before converting to USD.
– If electricity rises to $0.15/kWh, electricity_cost/day = 72 kWh × $0.15 = $10.80 → larger daily loss.

Checklist: steps to evaluate a mining setup
1. Gather inputs:
– Your hash rate (TH/s), network hash rate (TH/s), block reward (BTC), blocks/day (usually 144), electricity price ($/kWh), miner power draw (W), BTC price ($), pool fee %.
2. Compute network share = your_hash / network_hash.
3. BTC/day = network_share × blocks_per_day × block_reward.
4. Revenue/day (USD) = BTC/day × BTC_price.
5

5. Adjust for pool fees and luck:
– BTC/day_after_fees = BTC/day × (1 – pool_fee%).
– Note: solo mining replaces pool_fee% with much higher variance (long periods of zero rewards then occasional full-block reward).

6. Convert to USD and subtract running costs:
– revenue_day_usd = BTC/day_after_fees × BTC_price.
– electricity_cost_day = (miner_power_W / 1000) × 24 × electricity_price_per_kWh.
– other_operating_costs_day = cooling + bandwidth + site_rent/hosting + maintenance (estimate).
– profit_day = revenue_day_usd – electricity_cost_day – other_operating_costs_day.

7. Include depreciation / capital recovery:
– daily_capex_charge = hardware_cost / expected_life_days.
– cashflow_day_after_capex = profit_day – daily_capex_charge.
– If cashflow_day_after_capex ≤ 0, payback is not achieved under current assumptions.

8. Compute payback and ROI metrics:
– payback_days = hardware_cost / profit_day (only if profit_day > 0; this ignores financing costs and taxes).
– annualized_ROI ≈ (profit_day × 365) / hardware_cost.
– Note these are simple metrics; use discounted cash flow for more precision.

Worked numeric example (step-by-step)
Assumptions:
– Your miner: 110 TH/s, power = 3,250 W, hardware_cost = $8,000.
– Network hash rate = 350 EH/s = 350,000,000 TH/s.
– Block reward = 6.25 BTC, blocks/day = 144 → BTC/day_total = 144 × 6.25 = 900 BTC/day.
– BTC price = $40,000, pool fee = 1%, electricity = $0.10/kWh, other operating costs = $0.00/day (for simplicity).

1) network_share = 110 / 350,000,000 = 3.1428571e-7.
2) BTC/day = network_share × 900 = 0.00028285714 BTC/day.
3) BTC/day_after_fees = 0.00028285714 × 0.99 = 0.0002790286 BTC/day.
4) revenue_day_usd = 0.0002790286 × $40,000 = $11.16 (rounded).
5) electricity_cost_day = (3,250 / 1000) × 24 × $0.10 = 3.25 × 24 × 0.10 = $7.80.
6) profit_day = $11.16 – $7.80 = $3.36.
7) payback_days = $8,000 / $3.36 ≈ 2,381 days ≈ 6.5 years.

Sensitivity checks (quick mental math):
– If BTC price falls 50% → revenue_day_usd halves → pay

back becomes impossible: revenue_day_usd halves to $5.58, which is less than the $7.80/day electricity bill, so profit_day = $5.58 − $7.80 = −$2.22/day. That means under those assumptions you would be losing $2.22 every day and would not recover the $8,000 capital outlay.

Quick sensitivity recalculations (same assumptions as before unless noted)
– Baseline (from prior steps): revenue_day_usd = $11.16, electricity_cost_day = $7.80 → profit_day = $3.36 → annual_profit ≈ $3.36 × 365 = $1,226.40 → simple payback = $8,000 / $3.36 ≈ 2,381 days ≈ 6.5 years → simple annual ROI ≈ 15.3%.
– BTC price −50%: revenue_day_usd = $11.16 / 2 = $5.58 → profit_day = $5.58 − $7.80 = −$2.22 → no payback (loss).
– BTC price +100% (price doubles to $80,000): revenue_day_usd = $11.16 × 2 = $22.32 → profit_day = $22.32 − $7.80 = $14.52 → payback_days = $8,000 / $14.52 ≈ 551 days ≈ 1.5 years.
– Electricity cost +100% ($0.20/kWh): electricity_cost_day = $7.80 × 2 = $15.60 → profit_day = $11.16 − $15.60 = −$4.44 → no payback (loss).
– Network hash rate +100% (difficulty doubles; your network_share halves): revenue_day_usd = $11.16 / 2 = $5.58 → profit_day = −$2.22 → no payback.

Key formulas (use consistent units)
1. network_share = miner_hashrate / network_hashrate
2. BTC_per_day = network_share × BTC_per_day_total (BTC_per_day_total ≈ blocks_per_day × block_reward; ignore transaction fees for simplicity)
3. BTC_after_pool_fees = BTC_per_day × (1 − pool_fee)
4. revenue_day_usd = BTC_after_pool_fees × BTC_price_usd
5. electricity_cost_day = (power_W / 1000) × 24 × electricity_cost_per_kWh
6. profit_day = revenue_day_usd − electricity_cost_day − other_operating_costs
7. payback_days