The Tangle: no blocks, no chain

The IOTA Tangle is a stream of interlinked and individual transactions. These transactions are distributed and stored across a decentralised network of participants.

A pile of braided rope representing the nature of Tangle

The Tangle is the data structure at the heart of IOTA, first introduced in the Tangle whitepaper. IOTA uses a DAG instead of a blockchain to store its ledger, with the main motivation being scalability. A blockchain has an inherent transaction rate limit, because all participants agree on the longest chain, and discard forks and side branches. The Tangle, on the other hand, allows different branches of the DAG to eventually merge, resulting in a much faster overall throughput.

Tangle Structure

The Tangle is a DAG, where vertices represent transactions, and edges represent approvals. When a new transaction is introduced, it is added as a new vertex in the DAG.

It is also attached to two previous transactions, which it is said to approve. The process for selecting these two transactions is described below. Approving a transaction implies that its history was verified and found to be valid. In particular, it means all accounts have positive balances. This makes sure there are no double-spends or new illegitimate tokens created.

The first transaction in the Tangle is referred to as the genesis. All the IOTA tokens were created in the genesis, and no new ones will ever be created. All transactions in the tangle approve thegenesis directly or indirectly.

Once a transaction is approved by a large number of newer transactions, it becomes part of the consensus and is practically impossible to alter. The Tangle achieves this by requiring each transaction to perform a small proof-of-work computation. This proof-of-work is a small effort for any single transaction, which makes it expensive to spam or fork the Tangle after consensus has been established.

Tip Selection

Tip selection is done by performing a random walk from the genesis towards the tips. The walk stops when it reaches a tip. The walk is performed twice, and so two tips are chosen. The walk is biased towards transactions with more cumulative weight, or more transactions approving them. It can be thought of as walking towards the heaviest branch.

The outcome of this selection method is bigger branches getting bigger, and smaller branches shrinking and eventually disappearing, in the sense that no new transactions approve them. This heaviest branch concept is similar to the longest chain idea in the blockchain, but is more flexible, since it does allow smaller branches to merge with the bigger ones. The net result is a trustless consensus system, which overcomes the blockchain throughput limit.

Consensus in the Tangle

In a blockchain, you can be sure that your transaction is confirmed after it is approved by several blocks. Similarly, in the Tangle you can be assured that once your transaction has enough cumulative weight, it is safely included in the consensus.

Cumulative weight corresponds to the amount of proof-of-work which validates a particular transaction. In order to change history, or "un-approve" a transaction, a malicious actor would have to invest a similar amount of computing power. This is very expensive to do once the cumulative weight gets large.

Natural Extension of Blockchain

The Tangle is similar in spirit to a blockchain, but overcomes some of its fundamental limits.

  • Scaling: the Tangle does not have a built in maximum throughput.
  • Fees: there are no miners, and therfore no miner fees. Each transaction sends the full input amount.
  • Miners versus users: IOTA has no miners, and therefore no incentives to slow the network down to raise fees, and other conflicts of interest.

If you want to read more about the Tangle, please see the white paper, or this introductory blog series.