Get started
Get started
The value proposition of Bitcoin is first and foremost that it is a monetary system. It was therefore designed with intentional limits in terms of scalability and functionality, in order to maintain its security and decentralization. However, to respond to the increase in the number of users and enable new functionalities, without reducing its security, second layer solutions have emerged.
Surely the most famous is the Lightning Network, which allows fast and inexpensive BTC payments to be made by moving them off the main chain. But there is also another family of second layer solutions: sidechains. These side chains make it possible to carry out faster, more confidential transactions and to execute smart contracts, while using a token representing bitcoin. In this article, we explore how sidechains work to better understand their trade-offs and the possibilities they offer.
A sidechain, or “side chain” in French, is a blockchain that is independent of the Bitcoin blockchain, but uses the same unit of account as this one. It works in parallel, and often offers additional functionalities while remaining linked to Bitcoin through a mechanism called “bilateral anchoring” (or” Two-Way Peg ” in English).
This mechanism allows bitcoin to be transferred from the main chain to the sidechain and vice versa, while maintaining value parity between assets on both chains. This means that the bitcoins on the sidechain still represent real authentic bitcoins, although they circulate on a different infrastructure.
The main purpose of a sidechain is to add features or technical improvements that cannot be directly implemented on the Bitcoin core blockchain. For example, sidechains can allow for faster transactions, lower fees, more privacy, greater transaction capacity, or even the support of complex smart contracts. Since the sidechain is completely separate from Bitcoin, innovations can be tested there without affecting the security and stability of the main Bitcoin blockchain.
The sidechain concept was introduced in 2014 by developers who are very well known in the ecosystem in a scientific paper called” Enabling Blockchain Innovations with Pegged Sidechains ”. Its authors include Adam Back, Matt Corallo, Matt Corallo, Luke Dashjr, Pieter Wuille, Andrew Poelstra and Gregory Maxwell.
Since then, several sidechains have been implemented on Bitcoin. The best known are Liquid, which allows altcoins to be issued and confidential transactions to be carried out quickly, and RSK (Rootstock), which allows in particular to execute smart contracts.
Sidechains therefore represent a solution to extend Bitcoin's capabilities while maintaining the integrity and security of its main chain. To function, they rely on two mechanisms that will determine its level of decentralization and its security: the consensus mechanism and bilateral anchoring.
On the main Bitcoin blockchain, we have a consensus mechanism that is based on mining. It allows you to determine who has the right to publish a block and under what conditions, so that all users can agree on a single version of the transaction history.
Since sidechains are primarily blockchains, they must also have their own consensus mechanism to validate transactions and ensure the integrity of the blocks created. However, sidechains aren't limited to proof-of-work, which is the mechanism used on Bitcoin. They can implement various mechanisms according to their goals in terms of decentralization, security, and performance.
One of the most common mechanisms in the context of sidechains is the federation of signatories. In this model, a group of selected entities, called officials or block signatories, are responsible for creating and validating blocks. Unlike Bitcoin, where anyone can participate in mining, only members of this federation are authorized to validate blocks on the sidechain. This speeds up the transaction confirmation process considerably, but at the cost of greater centralization. The main example of this model is the Liquid sidechain, which has a federation of 71 companies in the Bitcoin ecosystem, to sign and validate blocks.
Another consensus mechanism used by some sidechains is merged mining (Mining Merged). This mechanism allows Bitcoin miners to reuse their computing power to validate one or more sidechains simultaneously, without requiring additional work. This method allows a sidechain to benefit from the security of the Bitcoin network, since it is based on the same hashing power. However, this method requires miners to manage nodes specific to each sidechain, which in fact limits their security. It also has the disadvantage of distributing sidechain rewards directly on the sidechain, not on Bitcoin. For example, the Rootstock sidechain uses this mechanism.
Finally, it is also possible to establish a sidechain on blind merged mining (Blind Merged Mining). In this model, Bitcoin miners do not validate sidechain blocks directly, but sell their proof of work to independent node operators. So, mainchain miners don't need to run a node on the sidechain, and they get their rewards directly on Bitcoin. In return, the operators of sidechain nodes take care of the creation of the blocks and recover the transaction fees in the sidechain token. However, blind fusion mining requires changes to the Bitcoin protocol proposed in The BIP301 to be able to function.
Bilateral anchoring, or” Two-Way Peg ” (2WP), is the mechanism that allows the use of bitcoins on the sidechain. In reality, these are not real bitcoins, but independent digital assets that are backed by bitcoin. This anchor ensures that the BTCs used on the sidechain are based on real main chain BTCs, and that they maintain the same value.
The two-way peg mechanism works through a locking and transmitting system. The process starts on the main Bitcoin blockchain. When a user wants to move their bitcoins to a sidechain, they are temporarily locked on the main chain. An equivalent quantity of assets is then created on the sidechain, in the form of tokens representing the original bitcoins. For example, on the Liquid sidechain, these bitcoins are represented by L-BTC, which circulate independently, but remain backed by the bitcoins locked on the main blockchain.
Returning assets to the main blockchain follows the opposite process. When the user wants to get their real bitcoins back, the tokens on the sidechain are destroyed, and the corresponding bitcoins are unlocked on the main blockchain. This process ensures that the total number of bitcoins in circulation remains constant between the two chains, and thus prevents asset values from being diluted.
The objective is also to prevent “depeg”, i.e. the dissociation between the value of the debt acknowledgement that circulates on the sidechain and the underlying asset, bitcoin, to which it should normally be indexed.
There are several ways to manage bilateral anchoring on a sidechain. The easiest method is to trust a centralized entity, which manages the locking and unlocking of bitcoins. However, this method involves too much risk of trust that is obviously incompatible with the spirit of Bitcoin.
A more decentralized approach is to use a federation of entities to manage bilateral anchoring. This is the case with Liquid, where a group of companies controls the multisignature addresses containing the locked bitcoins, and thus manages the issuance of L-BTC and then their destruction in exchange for the locked bitcoins on-chain.
Finally, in the case of “drivechains”, we have an even more decentralized method, since bilateral anchoring is given directly to Bitcoin miners. In this system, the bitcoins on the main chain are locked with a smart contract, and to unlock them in exchange for the destruction of the assets issued on the sidechain, a majority of miners must vote with their computing power during a defined period of time. This mechanism reduces the centralization of bilateral anchoring, but it requires implementing the BIP300 via a soft fork. Without it, the drivechain cannot work.
➤ Discover the difference between a soft fork and a hard fork.
Sidechains are second-layer solutions for extending Bitcoin's capabilities without compromising its security or integrity. They allow the addition of functionalities, such as fast transactions or complex smart contracts, while using a token backed by bitcoin thanks to bilateral anchoring. However, these protocols necessarily come with certain compromises, especially in terms of decentralization and security.
Drivechains, on the other hand, are a specific form of sidechain, which entrust the management of the bilateral anchor to the miners of the main chain. But right now, they cannot be implemented without the adoption of the BIP300 and BIP301, which are highly controversial proposals in the Bitcoin community, as they could change its incentives and security model.
So we will see in the future whether Bitcoin developments will focus on sidechains or if other second layer protocols, such as the Lightning Network, will take over.
➤ Learn more about how the Lightning Network works.