What are consensus mechanisms?

Consensus mechanisms are the method blockchain networks use to agree which transactions and other data are valid.

One of the challenges of creating digital money is to maintain an accurate record of transactions without a central authority. Maintaining an accurate record is important to prevent double-spending and other invalid transactions. 

Every node in a network needs to agree on one version of reality. A consensus mechanism is a set of rules that determines how nodes do this. 

Blockchains are ledgers of transactions that are distributed and decentralized. So different nodes need to agree on identical copies of this ledger.  

But what if one node says something different happened? That a transaction was 10 BTC instead of 1 BTC? How do all the nodes agree which version of history is correct? 

The answer to this question depends on the consensus mechanism the blockchain uses to decide what information is valid.


What’s proof-of-work (PoW)?

Proof-of-work (PoW) was the first consensus mechanism as explained in the Bitcoin white paper.

Miners (computers) spend energy to solve complex mathematical problems. The miner to solve the puzzle the fastest gets to validate the block. For validating the block, the miner earns the block reward. 

This incentivizes solving the problem, which is the “work” in proof-of-work. 

It also disincentivizes making up alternative versions of reality because (if the network is decentralized enough) it’s too expensive. You would have to own 51% of the network to validate a double-spend transaction. 

Because it’s so expensive to verify transactions, it’s also too expensive to manipulate the blockchain for gain.

Bitcoin uses the proof-of-work consensus mechanism.


What’s proof-of-stake (PoS)?

Proof-of-stake (PoS) uses validators rather than miners to validate blocks. A validator checks the accuracy of transactions, verifies on-chain activity, votes on blocks, and maintains records.

The more blocks a validator validates, the more rewards the validator earns.

A validator owns and stakes the primary token of the network (i.e. ATOM in the Cosmos network, ADA in the Cardano network) in order to participate.

Different protocols have different rules for staking, but generally staking means locking up a minimum amount of crypto for a certain amount of time.

There can also be a waiting period before your coins start earning rewards. Depending on the coin, there might also be a waiting period before you can unstake your crypto and transact with it again.  

The next validator is chosen at random. Usually, the more crypto a validator has staked, the greater the chance of being chosen to validate the next block.

Blocks are generally validated by more than one validator. When a specific number (set by the protocol) of validators agree on the data included in the block, the block is finalized.


What are other consensus mechanisms?

Delegated proof-of-stake

  • Like proof-of stake, the network is secured by validators
  • Stakeholders vote for delegates, also known as witnesses. Voting power is proportional to the amount of coins held by a stakeholder.
  • Delegates generate and validate new blocks 
  • You can read more about DPoS in Binance Academy’s article: Delegated Proof of Stake Explained

Directed acyclic graph (DAG)

  • Instead of blocks, DAGs have vertices and edges. In a DAG, each vertex represents a transaction. Transactions are built on top of one another. In order to send a transaction, you need to validate two previous transactions you’ve received.
  • You can read more about DAGs in Cointelegraph’s article: What is a directed acyclic graph in cryptocurrency? How does DAG work?

Proof-of-authority (PoA)

  • Rather than staking crypto, proof-of-authority relies on participants staking their real identity. Staking your identity means disclosing who you are in exchange for the right to validate blocks. This means that any actions you perform are public, and tied to who you are and your reputation. This disincentivizes bad behaviour. 
  • You can read more about PoA in CoinDesk’s article: What Is Proof-of-Authority?

Proof-of-burn (PoB)

  • Allows virtual miners to “burn” tokens by sending them to a burn address (i.e. an address that no one has access to via private keys).
  • Miners are granted the right to create blocks relative to the coins they burn. The more coins they burn, the more power they have, and the more blocks they can create. The more blocks they create, the more rewards they earn. 
  • You can read more about proof-of-burn in CoinMarketCap’s article: Proof-of-Burn (PoB)

Proof-of-capacity (PoC)

  • Allows computers to use available space on their hard drives to validate transactions. Thinking back to PoW’s complex problem, PoC works by storing a list of possible solutions on the mining device’s hard drive. The greater the space, the longer the list it can store, and the greater possibility of a match. 
  • You can read more about PoC in Investopedia’s article: Proof of Capacity (Cryptocurrency) Overview

Proof-of-elapsed-time (PoET)

  • Follows a lottery system that gives each participating node a chance to validate the next block
  • Each node has a set wait time in which it’s inactive, or goes to sleep. The node with the shortest sleep time gets to wake up and create the next block. 
  • Similar to proof-of-work but uses much less energy because it allows the node to sleep or switch to other tasks for the duration of the wait time
  • You can read more about PoET in Investopedia’s article: Proof of Elapsed Time (PoET)

Proof-of-staked-authority (PoSA)

  • A combination of delegated proof-of-stake and proof-of-authority used by BNB Smart Chain (BSC)
  • Validators are elected, and take turns in confirming transactions on the network
  • Validators produce blocks in a PoA manner, which considers the amount of their stake and their reputation in the community
  • You can read more about PoSA on CoinMarketCap: Proof of Stake Authority (PoSA)