Lightning Network (“LN” for short) is a recently-proposed, and even more recently implemented, low-latency off-chain micropayment system that can work with Bitcoin or other similar cryptocurrencies, such as Decred. Since LN makes liberal use of smart contracts, the details of how it works are, unsurprisingly, complex. To make LN more tangible from a non-technical perspective, we will view it through the lens of practical engineering considerations and the concepts that drive those considerations.
The utility of LN is driven by several major considerations in the context of cryptocurrencies:
- low-latency payments - Many potential use cases for a modern system of transmitting value require a low latency, e.g. point-of-sale purchases. Waiting for an on-chain transaction places unreasonable constraints on both the time between blocks in a blockchain and what is considered an acceptable delay for payment to confirm.
- deferred settlement - In order to minimize the number of transactions that flow between banks, banks make use of a net settlement process wherein multiple transactions between a given pair of banks are consolidated into a single transaction at the end of each day. Since cryptocurrencies effectively allow you to “be your own bank”, having a similar deferred settlement process substantially reduces transaction load on the blockchain and reduces transaction fees, allowing it to scale much better as the transaction rate increases.
- privacy enhancement - A blockchain for any publicly available cryptocurrency is necessarily a public ledger, even when the details of ledger entries are obfuscated by cryptography. By taking transactions off-chain, those transactions have their privacy enhanced simply by merit of not being in the public ledger.
- cross chain atomic swaps - Reliance on centralized exchanges is a major weak point of cryptocurrencies, whether we are talking about exchanges that handle fiat currencies or that handle cryptocurrencies exclusively. Cross chain atomic swaps will create liquidity between Decred and other cryptocurrencies without the counterparty risk that exists between users and centralized exchanges.
The benefits of LN are clearly quite substantial, per the considerations above. However, there are some notable weaknesses with LN that users need to be aware of:
- counterparty theft - Since LN transactions occur off-chain, it is possible for a counterparty in a payment channel to attempt to steal the funds in the channel, but this can only succeed under certain conditions and is preventable. Conventional on-chain transactions do not suffer from this problem because they are written directly to a blockchain, an immutable ledger.
- centralization of nodes - LN transactions are handled by a network of nodes that is separate from the underlying blockchain, and there is potential for these nodes to become centralized, despite them not having custody over coins. Operating a busy LN node is a potentially expensive operation, creating a barrier to entry for operating such a node and correspondingly increasing centralization.
Despite these weaknesses, I believe that the benefits of LN far outweigh the potential downsides. Each of these considerations is addressed in greater detail below.