Crypto Hub

composed-banner-left

How Bitcoin Mining Works

Crypto_Monitor_Website_Composed_Banner_Right_aa37163571.png

Mining is one of the most complex components of bitcoin, but it is arguably the most important. There are three main functions that bitcoin mining serves:

  1. Adding new blocks to the blockchain

  2. Creating new bitcoins

  3. Securing the network

We review each aspect in turn below.

Who are the bitcoin miners?

Before reviewing what bitcoin miners do, it can help to know who they are.

Bitcoin miners are usually companies. Many of them public, with their shares trading on exchanges such as the Toronto Stock Exchange and the Nasdaq. Famous miners include HIVE Blockchain, Riot Blockchain, Hut 8 and Marathon Digital Holdings.

Successful mining requires thousands of high-performance computers. Meaning that bitcoin miners run server farms, quite like data or tech companies. Once these computers are connected to the internet and to the bitcoin network, miners can collect and confirm transactions.

Picture3_189be19fc1.jpg

A mining farm of Genesis Mining, located in Iceland. Source: Wikipedia

Miners are based all over the world. But they prefer to be in whichever country provides the cheapest electricity, as running server farms uses a lot of it. Since China banned bitcoin mining in 2021, the US and Kazakhstan have become the biggest bitcoin mining centres.

So, what do bitcoin miners do?

Function 1: Adding new blocks

The main activity of bitcoin miners is adding new chunks of transactions – called “blocks” – to the blockchain. Under the rules of bitcoin, a new block can only be added to the blockchain every 10 minutes (other cryptos are faster, with blocks being added more often). The way new blocks get added is through a lottery. The winning miner gets the right to add a new block.

The slot machine in this lottery is a famous little programme called SHA-256, which was developed by the National Security Agency (NSA) in 2001. In the lottery, miners punch letters and numbers into SHA-256 until they get an output – called a hash – that begins with 30-odd zeroes. Below is a screenshot of SHA-256.

SHA256

SHA_256_b69a6c9864.png

The NSA did everything they could to ensure SHA-256 generates highly unpredictable outputs (but not random). Statistically, miners have a one in a billion chance of finding a winning number with every guess.

As with any lottery, maximising your chances of winning requires buying as many tickets as possible. For this reason, the most successful miners tend to have the most computers. As with any lottery, it costs money to play. Running these computers incurs high electricity bills.

Function 2: Creating new bitcoins

Whichever miner finds a lottery number first wins and can add a new block to the blockchain.

The prize for winning is newly created bitcoins. The current prize money as of December 2021 is six bitcoins. However, the prize slowly declines over time (halving every four years) until roughly 2140, at which point it hits zero. This is because bitcoin will hit its supply limit of 21 million bitcoins.

Other (competitor) miners will check that the number found by the lottery winner is correct. If most miners confirm it, the lottery starts afresh with the next block. However, if most other miners reject the new block, the block will not be added.

Future Bitcoin Supply