How to Mine Bitcoin: The Ultimate Guide to Start Mining Bitcoins

What is Bitcoin mining?  Mining is the process by which new bitcoins are created and simultaneously, the way the bitcoin system is secured. Through mining, bitcoin transactions are validated and cleared. Mining is a sort of decentralized clearinghouse because it secures the bitcoin system and enables a network-wide consensus to be achieved without a central authority or a trusted third party. It is the invention that makes cryptocurrencies revolutionary. Well, technically, Bitcoin is an emanation of an ingenious solution to the double-spending problem and the Byzantine Generals’ Problem. And here you will find out how to mine Bitcoin.

So, who do you think created this cryptocurrency?

In the words of Andreas M. Antonopoulos: “Satoshi Nakamoto’s main invention is the decentralized mechanism for emergent consensus. Emergent, because consensus is not achieved explicitly—there is no election or the fixed moment when consensus occurs.

Instead, the consensus is an emergent artifact of the asynchronous interaction of thousands of independent nodes, all following simple rules. All the properties of bitcoin, including currency, transactions, payments, and the security model that does not depend on central authority or trust, derive from this invention.”

Ever wondered how mining works? There is no physical activity involved.

Trust me on this one.

Miners provide processing power to the bitcoin network to validate new transactions and record them on the global ledger called the Blockchain. A new block is mined roughly every 10 minutes and it contains all the transactions that occurred since the last block.

When the transactions are aggregated into a block and the block is “added” into the blockchain, those transactions are considered to be “confirmed” which in turn allows for the owners of the funds to spend the bitcoin they received in those transactions. Why would anyone disburse computing power and therefore electricity to do this? It’s certainly not for altruistic reasons.

Mining is incentivized by the opportunity to be rewarded with bitcoins. It is the way new currency is added to the money supply. It’s called “mining” because it’s designed to simulate diminishing returns, just like mining for precious metals.

It started with 50 bitcoin per block in January of 2009 and halved to 25 bitcoin per block in November 2012, then it halved to 12.5 in 2016 and it will halve again in 2020 repeating this process until the last bitcoin is mined in the year 2140. Exactly 20,99999998 bitcoins will be issued in total.

Bitcoin mechanics and Bitcoin economics

Mining is basically a competition to solve the proof-of-work algorithm.

What miners do is use specialized hardware that is designed to solve the proof-of-work algorithm in the fastest and the most power efficient way in the hopes of being the first one to do it. The winning miner will receive the block reward in what is known as the coinbase transaction.

Mining nodes, as do all nodes, are “listening” for new blocks all the time. However, the arrival of a new block, for a miner node, acts as an announcement for a winner, and both as the end of the competition and as the starting pistol for the beginning of a new race.

At that exact moment, the mining node ends the process of validation of the previous block, it accepts the winning block as valid and incorporates it into its own copy of the ledger. In the time following, the mining node aggregates the transactions from the transaction pool into a candidate block and starts solving the puzzle for the proof-of-work consensus algorithm.

In the simplest terms, mining, in the case of Bitcoin is the process of hashing the block header repeatedly, changing one parameter called a nonce, until the resulting hash matches a specific target. The only way to produce a hash that matches the specific target is by randomly modifying the input until the desired hash appears by chance.

For any specific input, the resulting hash will always be the same, but no one can reverse engineer that particular input to get the desired hash result. It can only be done by trying random inputs, and therefore, only by chance.


Bitcoin mining uses the SHA256 algorithm. The SHA (Secure Hash Algorithm) is one of a number of cryptographic hash functions. A cryptographic hash is like a signature for a text or a data file. The SHA-256 algorithm generates an almost-unique, fixed size 256-bit (32-byte) hash. Hash is a one-way function – it cannot be decrypted back.

The Target

The proof-of-work consensus algorithm uses a “target” or a “goal” to make solving the hashpuzzle intentionally difficult. To make it a challenge the Bitcoin system automatically adjusts the difficulty of the puzzle in such a way that it takes the whole network of miners (all that computing power put together) roughly ten minutes to solve the puzzle.

It practically states that for a block to be considered valid the miner has to find a hexadecimal hash that starts with 10 zeros per se. The more zeros at the beginning, the harder the miner has to work to find the phrase. The number used as a variable in such a scenario is called a nonce, and it’s used to vary the output of the cryptographic function until it hits the target set by the system.

The first miner in the race to find the solution to the puzzle that meets the target criteria is said to have “proof of work” because the miner had no other way of finding the solution other than trying different nonces one after the other and thus spending an enormous amount of electricity in the process.

Why is the difficulty adjustable?

Bitcoin’s blocks are generated every 10 minutes on average. This means that all the transactions are settled every 10 minutes and new bitcoins are issued every 10 minutes. The mining difficulty is a dynamic parameter that has to be adjusted to meet the 10-minute block target.

If the whole network is finding blocks faster than 10 minutes, the difficulty will increase, and if it’s slower than 10 minutes, the difficulty will decrease. It is entirely dependent on the combined computing power of the network. As more miners and incentivized to join in the race, the difficulty has to increase to meet the 10-minute criteria and vice versa.

Can miners cheat the system?

The short answer is, no. As the mining node transmits the newly mined block to its peers in the p2p network, every node independently cross-checks the block it received to a long list of criteria to validate it. As the newly minted block ripples across the network, each node performs an independent evaluation to validate it before transmitting it to its peers.

This ensures that only valid blocks are propagated on the network. This ensures that miners who act honestly get their blocks incorporated into the global ledger and thus earn the reward from the coinbase transaction they created.

How to start mining Bitcoin?

As with any other investment the first thing you want to do is to think about all the factors that interact with your profits, and as mentioned before, several factors determine the profitability of mining:

a) Initial investment

The most obvious expense in Bitcoin mining is the mining hardware that includes the actual Bitcoin miner, power supplies, cables, software, cooling, rent (if you go big), etc.

b) Mining difficulty

Assuming every other factor stays the same, you can expect your earnings to decrease as difficulty increases and vice versa. When taking this into account, you should keep in mind that the mining difficulty is on a steady uptrend as more and more miners are joining the race. The rate at which this happens is indeterministic, but you can certainly expect it to go up.

c) The price of Bitcoin on the free market

This is one of the biggest profitability factors in the mining game. A sudden drop in the price of bitcoin can turn a profitable miner into an unprofitable one. Any investment in Bitcoin is a high-risk high-reward one. The Bitcoin market is a very volatile and stochastic market, and you should always take this into consideration.

d) Cost of electricity

The cost of electricity is one of the biggest expenses miners face after the initial investment in mining hardware. Miners that achieve high efficiency with their mining rigs and cooling methods and mine in countries with the lowest electricity costs will naturally have an advantage over other miners in the game.

e) Block and fee rewards

Bitcoin’s block reward halves every 210,000 blocks or approximately every four years. Because of deep technical reasons, bitcoin block space is a scarce commodity, getting a transaction mined can be seen as purchasing a portion of it.

Users with high time requirements may pay a higher than average miner fee to be confirmed quickly, while more users under less time pressure can save money by being prepared to wait longer. This means that the rewards from fees are determined by the free market and are therefore unpredictable.

f) Downtime

Downtime is your enemy. Every second your mining operation is not running it’s losing you money. Making sure your rig doesn’t get overheated, your software doesn’t get buggy, steady supply of electricity, maintenance of hardware and so on is a must for any professional miner in the game.

Mining calculator

Before you consider getting into the Bitcoin mining game, you should roughly calculate your expected ROI using a Bitcoin mining calculator. Cryptocompare provides a page where you can compare cryptocurrency mining equipment and a calculator with inputs of the key factors.

Here’s a short how-to tutorial you should follow when calculating your ROI time.

1. Click here and chose a mining rig within your price range. Let’s assume for simplicity’s sake that you want to compare the DragonMint 16T and the S9 Antminer.

2. When you click on the two mining rigs you will see their specs:

DragonMint 16T – price $1,595; power 1432W, Hash rate 16,000.0 GH/s

S9 Antminer – price $1.415; power 1375W; Hash rate 14,000.0 GH/s

3. Use the cryptocompare mining calculator to calculate your potential profits;

For DragonMint 16T the calculation looks like this:


For S9 Antminer it looks like this:


As you can see the Dragon miner has more than 100% profitability advantage over the S9 Antminer and costs you only $180 more.

Note: Please consider that the calculations are made with the current difficulty rate and price of bitcoin (both factors have high volatility) and with the assumption of zero downtime and $0.10 kW/h electricity cost.

Choose your way forward

There are two ways you can get into the mining game,  you can set up a mining rig (or build a mining farm if you want to go large-scale) or you can buy a cloud mining contract. Let’s consider the pros and cons of both.

How do cloud bitcoin mining contracts work?

Bitcoin cloud mining or also known as cloud hashing means that a company owns a warehouse (a.k.a mining farm) full of mining hardware and it enables clients to purchase mining capacity or a certain amount of hashrate. Based on the amount of hashing power you are buying you will earn a share of payments from the cloud mining company for any revenue generated by the hashing power you got.


1. Simple to use. Zero hassle, you just set up a wallet and buy a contract and you’re set.

2. No noise, no heat and ventilation problems, no electricity bills

3. No equipment to take space in your home, no hassle to sell it when you decide to get out of the market

4. No downtime, risk of fires, maintenance fees etc.


1. SCAMS. 99% of the cloud mining businesses are SCAMS. This may be the most important factor when considering cloud mining contracts. Buy them ONLY from reputable companies such as Genesis mining and Hashflare. Both of them are offering contracts for several years on the market and are considered to be the most credible cloud mining companies out there.

2. Lower profits. This is a no-brainer. Every time you delegate your work and your risk you can expect lower profits.

3. Bitcoin mining contracts may have the ability to cease operations or payouts in the contracts if the Bitcoin price is too low

How to set up your own mining operation

Selecting a Scrypt ASIC Miner

Setting up a mining operation is a serious undertaking and should be taken as such. The first sensible step is to purchase the hardware. Before you do this, you should consider using the mining calculator and the equipment comparing tool as mentioned above.

In the process of selecting an ASIC miner, there are 4 key aspects to it that determine profitability:

1. Hash rate (usually expressed in hashes per second – H/s; proportional to the number of solutions that the unit generates for the cryptographic problem that all miners compete to solve in a given time; therefore, the higher the hash rate – the more likely it is that the miner will find the solution);

2. Power consumption (usually expressed in Watts – W; indicates how much electricity is used while mining);

3. Cost (important for determining the return of investment, or ROI, of the miner);

4. Delivery date (the function difficulty and overall hash rate of the network tend to increase over time, which can jeopardize the profitability of the ASIC miner before it’s even delivered);

Selecting a Power Supply Unit:

Most ASIC miners require the purchase of a separate, external Power Supply Unit (PSU). Keep in mind that the PSU wattage should be rated to exceed the power consumption requirements of the miner, with an additional margin for safety (usually +/- 10% 0f the wattage).

The PSU wattage should exceed the one of the miner because at peak power draw, a 500 W miner unit, for example, will demand 500 W + (10% of 500 W), or 550 W.

As the miner’s power consumption increases, so should the margin between it and the peak output rating of the PSU (e.g. for a miner that draws 500W +/- 10%, a PSU rated for 600 W or higher should be considered; for a miner that is reported to consume 800 W +/- 10%, a PSU rated for 1000 W would be advisable, etc.).

In addition to the wattage, PSUs are characterized by an “80 PLUS” designation, usually followed by a Bronze, Silver, Gold, or Platinum rating. This rating applies to the overall efficiency of the PSU. The higher the rating – the less electricity the miner wastes, which means less electricity is needed to deliver the same power to a miner.

Basic ASIC Miner Setup

While some ASIC miners vary significantly in terms of their specifications, there are some basic instructions that should be followed when setting up an ASIC miner.

Preparations to be made before setting up the miner itself:

Larger mining operations produce considerable heat and noise, so if that’s the setup you’re going for, you should find a well-ventilated location (to prevent heat from building up) that’s still isolated from potential contaminants (moisture, dust, pet hair etc.) as not to damage the miner, but one that still has access to a power outlet and to an ethernet cable connected to the Internet.

Another thing to consider when undertaking a larger mining operation is the number of miners on a given circuit as well as optional auxiliary cooling/heat management devices since they both can draw significant power.

Now to set up the miner:

1. Inspect the delivered ASIC mining unit for any damage, and compare it to pictures on the manufacturer’s website. If you find defects, contact the manufacturer or look for solutions to repair the unit yourself.

2. Connect the PSU to the miner, but not to the wall socket yet. Ensure that all required connections are powered correctly first. If the PSU is designated as an ATX PSU (very common), a more detailed sequence of action is necessary to insert the PSU in the mining ensemble correctly.

3. Connect the ethernet cable to the miner. If you’re unable to find the ethernet port, take a look at the manual.

4. Check the miner’s PSU again, and verify that it’s switched OFF. Check the manufacturer’s instructions for additional steps prior to powering up the ASIC miner. Upon completion of said steps, connect the PSU to the wall socket and switch it ON.

5. Ensure that the miner has entered in the expected startup. If the setup was done successfully, the startup process should be indicated by certain lights and/or sounds, as explained in the manual.

6. Log into the router connected to your miner, find the miner in the router interface and note the IP address.

7. Sign up for a mining pool. The benefits of pooled mining are many, and have been explained extensively online, so find a pool that is closest to you geographically and join it using the provided instructions for creating a profile.

You might be asked to provide a wallet address for payouts, name your “worker” unit, and enter a password for it. Lastly, don’t forget to save the pool’s URL.

8. Log into the miner by entering its IP address (that you wrote down in step 6) into a web browser. Now you want to find the miner configuration settings, where you can input URLs, names of separate “worker” units, and passwords.

In the URL field paste the pool’s URL (the one you saved in step 7), name your “worker” (the current mining unit itself) with the same name you used for it in the mining pool profile, and enter the same password in the miner configuration settings as the one you used on the mining pool profile.

If you followed these steps correctly, your miner should be up-and-running on your designated mining pool. You can check the status of your miner (or “worker” unit) by accessing your mining pool profile created on the pool website.

Maintenance of your mining rig

After the initial setup, there is little active maintenance required to keep the miner running. Here are some necessary requirements and some additional tips to keep the miner running at optimal efficiency.


1. Keep contaminants and other objects away from the miner ventilation system. Dust, dirt, hair or other contaminants can accumulate in the miner and cause all sorts of trouble. Keeping your mining environment clean is essential for the longevity of your miner rigs.

2. Keep the miner as cool as possible. This is a must. Try to maximize the air available to the inlet of the miners while moving the hotter exhaust air away from the mining area.

3. Keep the miner as dry as possible. Moisture can cause shorts in the circuity of the miner and cause irreversible damage to it, and may even render it useless.

4. Distribute the power draw. Use as many unique circuits as possible.

Additional tips for efficient mining:

1. Log into your mining pool from time to time to check the performance history. There may be problems you need to address and improve your mining efficiency.

2. Add auxiliary mining pools to your rig as a back-up in case the first pool goes offline.

Two ways you can mine with your mining rig

1. Solo mining, as the term suggests, means that you’re on your own. You use the hashing power of your mining rig to compete with the hashing power of the whole network with the hopes of beating it and retaining the reward in its entirety for yourself. Solo mining is usually not recommended because the payouts are significantly less consistent due to the smaller chance of finding the solution to the puzzle all by yourself.

2. Pool mining represents a conglomerate of many individual miners joined together with the same goal in mind: Solve the puzzle and share the profits. With more miners in the pool, the combined hashing-rate grows which in turn gives the pool more significant chance of mining a block and receiving the reward. Joining a mining pool is usually preferred over solo mining because of the consistency of the returns as everyone in the pool shares the remuneration proportional to the contributed hash-rate.

There are many mining pools to choose from, and all of them have different nuances, before joining one make sure you do your homework and research them. Here are just a few most popular ones: p2pool, bitminter, kanopool, and slushpool.

Final notes

You have reached the end of our Ultimate Bitcoin mining guide, and hopefully, you learned everything you need to know to get into the mining game.

Before you take a deep dive into your Bitcoin mining journey, take a look at our step-by-step wallet setup in our Guide to Investing in Bitcoin, and you are all set and done!

Make sure you always keep within the legal boundaries of your country and research the Tax Regulations in the place of your residence.

Good luck and happy mining and if you’re just getting started with Bitcoin read this first!