written by @thevladcostea
The Lightning Network and the Liquid pegged sidechain are the two most popular and technically-robust solutions to scale Bitcoin. Which one is for you?
After it became evident that increasing the block size was no longer a technically worthy pursuit, Bitcoin developers turned their attention to the most promising proposals: the second layer and the sidechain.
If you spend too much time on Twitter and read comments made by marketers, you may think that there is a fierce competition between Liquid and Lightning. To some, it might look like this generation’s VHS versus Betamax. However, the two layers are complementary and suit different needs with different tradeoffs. Namely, Liquid is for exchanges and large traders, while Lightning is for microtransactions and small purchases.
Quick sidenote: Blockstream (the company behind the Liquid sidechain) has an internal team of developers who work on an open-source Lightning client: c-lightning. Therefore, it’s difficult to argue that the for-profit company operates with an adversarial mindset and seeks to bring down Lightning.
This article will present the various tradeoffs involved in using Liquid and Lightning. While neither of them is perfect, they still bring great advantages over transacting on the base layer: they provide speed, lower costs, and greater privacy. Conversely, they don’t have the same security or decentralization as Bitcoin’s main chain.
Transaction Limits And Liquidity: Lightning vs Liquid
When you transact on the base layer of Bitcoin, you never have any limits: you can send and receive all the bitcoin in every coinbase ever in a single transaction, assuming that you’re capable of amassing that wealth and you are willing to pay the gargantuan fee.
Yet in the case of Lightning you are limited by the size of your channel. In order for one of these channels to open, a CheckSequenceVerify timelock with a certain amount needs to be established. The amount that you transact cannot exceed the number of bitcoin you locked when creating this specific channel.
If you’re using a custodian service such as Bitrefill (whose Thor Lightning channels can be rented), you’re limited by the company’s 27.67 BTC channel. The amount is definitely not negligible and clearly exceeds the average user transaction.
This is where the Liquid pegged sidechain steps in. By design, it’s made to serve the needs of traders and exchanges. Correspondingly, there’s 1 L-BTC that is minted for every existing BTC. These L-BTC are available on the network for as long as the pegging remains in place.
As of June 15th 2020, 2165 BTC have been pegged in on the Liquid network. If it were all transferred to one UTXO, there would be no economic restrictions in place. You can move any amount, as long as it follows the consensus rules and pays the right fee to functionaries.
While Lightning is great for the average user, it has limits imposed by channel sizes. This is why Liquid complements when it comes to large transfers.
Winner: Liquid Network
Security: Lightning vs Liquid
Now this is a sensitive discussion that’s bound to stir the pot: is a federated sidechain more secure than a permissionless global network that is built on top of Bitcoin? Well, it depends on how we define security and what kind of threat models we introduce into the analysis. For the scope of this article, security shall be defined as “protection against fraudulent trades”.
Side note: Neither Lightning and nor Liquid are as secure as the Bitcoin main chain.
Lightning has demonstrated a pretty robust security framework, which makes use of incentives to keep all actors honest. The network must guarantee that the coins involved in trades follow a proper routing path and reach finality, while conditions get fulfilled. This involves a complex process that gets described in a diagram on page 39 of the Lightning whitepaper.
So-called “justice transactions” will make sure that cheaters who try to escape agreements will get punished by having all the funds in their channel taken away. This works as harsh penalty that is meant to encourage honesty. Yet there are still attack vectors in regards to the state of Lightning nodes: a node that suddenly goes offline or has connection issues can be exploited by broadcasting obsolete channel states. To counter this kind of unpleasant situation, watchtowers will soon get deployed to act as objective observers and rule enforcers.
On the other hand, the Liquid pegged sidechain is more simple: it’s governed by a federation of globally-distributed exchanges that act as block signers. As long as a quorum of two thirds of functionaries is online and agrees on the state of the network, new blocks get signed. The security of the network depends on the activity of the exchanges and traders that operate
Liquid’s design simplicity and governance centralization make it more secure. But with better routing and properly-implemented watchtowers, Lightning will become a serious contender.
Winner: Liquid Network
Decentralization: Lightning vs Liquid
There are two ways of measuring decentralization: quantitatively (the number of existing nodes) and qualitatively (how difficult it is to run a node).
As of June 15th 2020, the Lightning Network has 12815 online nodes and 36676 open channels. Also, the entire liquidity of the second layer is 951.69 BTC – 2.27 times smaller than Liquid’s.
In Lightning, everything is permissionless and truly decentralized: every bitcoin user can run a node with one of the available clients (or fork them to create a new one) and proceed to open channels. For now, all nodes are equal and there is no higher authority to determine which channel state is true. But the situation will get more sophisticated when watchtowers are deployed at scale. It is, however, worth noting that anyone will be able to run a watchtower. Therefore the permissionless quality of the Lightning Network is retained.
Open Lightning channels create links between nodes and enable transactions. In order for a transaction to happen there needs to be a route between the two nodes. In the absence of this link, no money can be sent from one user to the other. This is both a feature for decentralization and an issue for the monetary system at large.
It’s also worth noting that Lightning companies exist, but no single on controls the development of the protocol. Anyone can work on a reference client, granted that the fundamental rules of the network are respected. This makes the Lightning Network very similar with Bitcoin in terms of decentralization.
The Liquid sidechain is different. First of all, the development is entirely in the hands of Blockstream. Secondly, participation to the governance relies on receiving permission. With the exception of running a validating node, every functionary role must be confirmed by Blockstream. Also, the network data concerning nodes and functionary activity isn’t as popular in blockchain explorer applications.
Just like Bitcoin, Liquid allows users to transact with any network participant without the need for a pre-existing condition (like Lightning’s requirement for channels that connect the parties). This small advantage doesn’t really give it an edge in terms of decentralization.
By all relevant metrics, the Lightning Network is more decentralized than the Liquid pegged sidechain.
Winner: Lightning Network
Privacy: Lightning vs Liquid
Privacy is often times an overlooked feature in Bitcoin. Yet the idea of having all transactions permanently written in a public ledger is frightening. This is why the two scaling solution increase transaction confidentiality as extra incentives to drive up adoption, as well as tools to facilitate new use cases.
The Lightning Network routes transactions in a way which resembles Tor: each hop in the path is encrypted so that participants can’t identify everyone involved. The first node involved will only be able to see the outer layers; the intermediaries will only record the next step, without having a clue about the destination; and lastly, the final node won’t be able to identify the origin of the transaction.
Opening a Lightning channel is marked by a Bitcoin on-chain transaction. So by the time it gets closed and the amounts settle, millions of second layer transactions can be made at great speed and with minimal costs. It’s only private to send bitcoins via Lightning if you are an intermediary who neither opens, nor closes the channel. Also, you must take care of your network-level privacy by using Tor and/or a VPN service.
Liquid network’s privacy only concerns transaction amounts. For as long as you send money on Blockstream’s pegged sidechain, you are able to use Confidential Transactions to boost your privacy and plausible deniability on the open ledger.
Liquid is definitely more private than Bitcoin, but as a sidechain it still has the open ledger design on which all transactions can be tracked. The Lightning Network is more interesting, as it offers a more advanced privacy mechanism which resembles Tor onion routing. This also makes bitcoin on the second layer fungible.
Winner: Lightning Network
Speed: Lightning vs Liquid
Lightning Network transactions are confirmed within seconds. Conversely, Liquid mines a new block every minute. Under the right network conditions and with proper routing, the Lightning Network is the clear winner of this battle. It’s designed to handle instant transactions with great speed.
In extraordinary situations where the Lightning Network broadcasts obsolete channel states or faulty routes take place, Liquid can sometimes be faster. Troubleshooting a Lightning transaction may take you longer than one minute. So by the time you figure out what is wrong with the Lightning transaction you have tried to send, the Liquid sidechain will have already broadcasted it with a two thirds majority between functionaries.
For this comparison it won’t be the exceptions that count. Lightning has functioned reliably for more than two years, and as the network matures the routing issues will become less common.
Winner: Lightning Network
Transaction Fees: Lightning vs Liquid
On the Lightning Network, the fee you pay for a transaction depends on how much the routing nodes charge. On Liquid, the minimum cost per transaction is 1 satoshi/vbyte (in times of great demand for sidechain block space, it’s bound to rise).
In practice, the smallest cost of a Liquid transaction is about 200 satoshis. On the Lightning Network, you can still pay only one satoshi for a transaction – as the network itself allows for sub-satoshi amounts to be sent. If you use custodial services or want to get the quickest route in a moment of high demand, you should expect to pay a slight premium.
Clearly, both scaling solutions are cheaper to use for transactions than Bitcoin on the base layer. Furthermore, there will always be an incentive for them to keep the fees below the threshold on the main chain.
For the time being, the Lightning Network has lower fees and is better suited for microtransactions. As a tool which aims to serve exchanges, Liquid uses a fee structure which resembles Bitcoin’s and most likely aims to subsidize the existing infrastructure. So it’s good to determine how much you want to send and the amount of security and verification you expect from your transaction before choosing between Bitcoin’s base layer (most secure, but most expensive), Liquid (the in-between solution), and Lightning (cheapest, but not as secure as either).
Winner: Lightning Network
If you have any feedback on this or any other topic, please feel free to reach out to us at any time at email@example.com or @BTSEcom on Twitter. We always love to hear from our amazing BTSE community.