Welcome to myĀ guide to the Lightning Network!
In this guide, Iām going to tell you what the Lightning network is, how it works and what it can be used for. You wonāt need to go anywhere else to have the Lightning network explained to you.
By the end of this short guide, youāll know whatās good, whatās bad and whatās important about the Bitcoin Lightning network. Iāll begin with a look at where it all started...
Bitcoin was created byĀ 'Satoshi Nakamoto'Ā in 2009. By 2011, they were gone, never to be heard from again! No one knows who Nakamoto is or exactly how they wanted the platform to be developed in the future.
This is a problem because Bitcoin is an amazing piece of technology but it isnāt perfect. If itās going to remain the worldās biggest cryptocurrency then it will need to change and improve. This is where the Bitcoin community comes in...
The Bitcoin community is full of talented and enthusiastic developers, engineers and computer scientists. They all have ideas about how to improve the Bitcoin network. Some of these ideas are so small that they are barely noticed and some are so large that new cryptocurrencies are created by them!
The development IāmĀ going to tell you about today is one of the most important so far. Itās called the Lightning network and it could change the way we use cryptocurrency forever.
Did you know?
Want to get smarter & wealthier with crypto?
Subscribe - We publish new crypto explainer videos every week!
DEX vs CEX: Which is Best for YOU? (Explained with Animation)
Table of Contents
- 1. What is the Lightning Network?
- 1.1. Bitcoin Basics
- 2. The Scalability Problem
- 3. How does the Lightning Network work?
- 4. Payment ChannelsĀ
- 5. Payment Networks
- 6. Lightning Network Security
- 7. Lightning Network Timeline
- 8. Lightning Network Issues: 2018
- 9. Lightning Network: Pros and Cons
- 10. Final thoughts
What is the Lightning Network?
Latest Deal Active Right Now:
CLAIM $600 REWARD
Exclusive Binance Referral Code
Don't miss this limited-time deal that's only available for our readers. Use the Binance referral code 49316610 & receive up to $600 in rewards and bonuses!
Lightning Network works as a decentralized exchange
The Lightning Network was first proposed by ThaddeusĀ DryjaĀ and Joseph Poon in 2015. The problem itās designed to solve is one of the biggest that cryptocurrencies face,Ā scalability.
Scalability is how well a platform can deal with a huge increase in its number of users. To understand the problem letās take a quick look at how Bitcoin worksā¦
Bitcoin Basics
Bitcoin is a decentralized peer-to-peer payment platform. ItāsĀ decentralizedĀ because it isnāt run by a company like Visa and it doesnāt have a leader (Satoshi Nakamoto is long gone, remember?). Bitcoin is run by its users on a network of thousands of computers calledĀ nodes.
Nodes contain a full record of every Bitcoin transaction that has ever been made. This record is called aĀ blockchain. More than half of all the nodes need to agree that each new transaction is valid before it can be added to the blockchain. This is calledĀ consensus.
OneĀ blockĀ of new transactions takes aroundĀ ten minutes to be processed and added to the blockchain. The nodes that do most of the work of processing transactions are calledĀ minersĀ and theyāre paid fees for the work they do. This means that sending Bitcoin is not only slow, it can also be quite expensive.
You might be able to guess the rest from here! Letās get back to scalability.
The Scalability Problem
As Bitcoin becomes more popular, its network of nodes grows. The more nodes there are, the longer it takes for them to reach a consensus on new transactions. The average transaction speed goes down as the network gets bigger.
At the moment, Bitcoin can process aboutĀ 3-7Ā transactions per second (Tx/s). Now compare that with two of Bitcoinās real-world competitors. PayPal can processĀ 150Ā Tx/s and Visa processes aroundĀ 2000Ā Tx/s but can go as high asĀ 56,000Ā when itās busy. When Bitcoin is busy, users have waitedĀ 6 daysĀ for transactions to be processed! Transaction fees also tend to go up during busy periods, so users have to pay more for less.
Thatās the scalability problem Bitcoin and many other cryptocurrencies are struggling with. What is the Lightning network going to do about it? Letās find outā¦
How does the Lightning Network work?
You might have heard the Lightning network explained as aĀ 2nd layerĀ solution. This means that the Lightning network is trying to solve the scalability problem by adding an extra layer to the Bitcoin network. Hereās how it worksā¦
The Lightning Network allows users to set up their payment channels. This means that thousands of small and medium-sized transactions can take place away from the main blockchain.
Imagine Joe works for Thad. Thad pays Joe 1BTC per day for a contract that lasts for 30 days. The pair set up a payment channel on the Bitcoin Lightning network. This information is added to the main blockchain and is called theĀ anchorĀ transaction.
Every day, 1BTC is transferred from Thad to Joe in their new payment channel. These transactions are calledĀ micropaymentsĀ and they happen instantly. The pair needs to agree on each transaction inside their payment channel.
At the end of 30 days, the contract ends and the pair close the payment channel. The final balance of the channel is sent to the network, processed and added to the main blockchain. This is called theĀ settlementĀ transaction. So, whilst 30 micropayments took place between Thad and Joe in their payment channel, only two transactions need to be added to the main blockchain.
By using the Lightning network, Thad was able to send Bitcoin to Joe quickly and the main blockchain was free to process more large transactions. Everyoneās a winner!
Next, Iām going to look more closely at how Thad and Joe set up their payment channel and how the system can grow to become a whole networkā¦
Payment ChannelsĀ
To setĀ up a payment channel on the Lightning network, Thad and Joe need aĀ multi-signature wallet.Ā This is a bit like a joint bank account. A multi-signature wallet is created by a deposit of funds. In our example, it would be a deposit of 1-30BTC by Thad. This is the anchor transaction thatās added to the main blockchain.
A multi-signature wallet requires each user to provide two kinds of information for transactions to take place. They are;
- Public address:Ā This is the digital location of the Bitcoin. You can think of it as an email address, information can be sent to it and received from it.
- Private keys:Ā These acts sort of like a password for the public address. Each user has their private lines of code that they use to āsignā transactions going to andĀ from the public address.
If either user fails to provide these pieces of information, then transactions in the payment channel wonāt happen. So, how does one payment channel become a super-fast payment network?
Payment Networks
Whatās special aboutĀ Lightning network payment channels is that they can link up to become payment networks of thousands or even millions of users.
Joe and Thad donāt need to set up payment channels with every user on the Lightning network to make transactions withĀ them. Letās imagine Joe is married to Lou and they have their payment channel for household expenses. This payment channel links Thad and Lou through Joe, so Thad and Lou can now send each other Bitcoin without setting up another payment channel.
Now imagine Thad, Lou and Joe each have 10 unique payment channels with other users and each one of those users has set up 10 unique payment channels as well. Soon youāre looking at a network of millions of nodes capable of sending Bitcoin to each other instantly. A single payment could pass through thousands of nodes to get to its destination in less than a second!
I know what youāre thinking. If my payment goes through thousands of different nodes to get to where I want it to go, whatās stopping another user from stealing it? Read on to find outā¦
Lightning Network Security
Micropayments on the lightning network are guided byĀ smart contracts. Smart contracts are sets of rules that must be followed for transactions to take place. For example, users can attach fees to transactions that are paid to each node it passes through. A smart contract would make sure that fees are only paid after the transaction is completed.
This gives all Lightning network users a good reason not to interfere with transactions.
A quick note on Lightning network fees
Lightning network fees are likely to be very small compared to the fees charged by miners on the main blockchain. The work done by Lightning network nodes is far easier than that done by miners. Any user trying to charge high fees to allow payments to pass through their node would be avoided. However, fees would soon add up to respectable amounts due toĀ the high volume of Lightning network transactions.
Two other important features of Lightning network security areĀ timelocksĀ andĀ asymmetric revocation commitments.Ā Hereās what they do;
- TimelocksĀ can be used to set an upper limit on how long a payment channel remains open. This stops one user from disappearing and leaving the balance locked in the wallet. In our example, if Joe only worked for 15 days and then disappeared, Thad could claim back the remaining 15BTC in the wallet using a pre-setĀ timelock.
- Asymmetric revocation commitmentsĀ are a way to punish users who try to cheat the system and remove their share of a wallet at a time that suits them. Asymmetric revocation commitments allow users to set conditions where the cheated user could claim the fullĀ balance of a wallet, leaving the cheater with nothing!
Now you know what the Bitcoin Lightning network is and how it works. Letās see what stage of development the network is at and whoās using itā¦
Lightning Network Timeline
It could be argued that the Lightning network release date was December 6, 2017, when its protocol was first issued onĀ GitHub. However, the official Lightning networkĀ daemonĀ wasnātĀ released untilĀ January 7, 2017,Ā so this could also be considered the Lightning network release date!
On December 27, 2017, a developer named Alex Bosworth paid hisĀ BitrefillĀ cell phone bill using the Bitcoin Lightning network. This is thought to be the first use of a Lightning Network payment on the BitcoinĀ mainnet.
Since then, the Lightning networkĀ mainnetĀ has been in a long test phase. Several developers have been researching and testing Lightning network projects. The main ones areĀ Lightning Labs,Ā ACINQĀ andĀ Blockstream.
In March 2018, Lightning Labs released Lightning Charge, a tool for developers to buildĀ lAppsĀ with.Ā LAppsĀ are Lightning applications such as payment services which will be based on the Lightning network.
Itās hoped that banks and other largeĀ organizationsĀ will use Charge to buildĀ lAppsĀ that their millions of customers will use. One of the firstĀ lAppsĀ to become popular isĀ Poketoshi, a game where users bid to control famousĀ PokemonĀ characters with Lightning network payments!
Other cryptocurrencies are also starting to follow Bitcoinās lead. Litecoin launched its Lightning network inĀ April 2018Ā and Stellar has included the Lightning network in itsĀ 2018 Roadmap.
The Lightning network will run on any platform that supports smart contracts and multi-signature wallets. This means that we could see Lightning networks providing 2nd layer solutions to platforms like Ethereum, Ripple, andĀ ZcashĀ soon.
The search and analysis engine,Ā 1ml, lists more thanĀ 2,500Ā nodes with overĀ 7,800Ā payment channels operating on the Lightning network today. However, the network is not ready for use by millions of people and recent problems have confirmed thisā¦
Lightning Network Issues: 2018
In January 2018, Lightning Labs co-founder, Elizabeth Stark,Ā criticizedĀ BlockstreamĀ for allowing its customers to pay for goods using theĀ mainnetĀ Lightning network. Stark accusedĀ BlockstreamĀ of risking their customer's money by using technology that hasnāt been properly tested yet. SheĀ tweeted, āBad move @Blockstream.ā
In March 2018, the network suffered aĀ DDoSĀ attack. The attack came after a Bitcoin developer, Peter Todd, hadĀ warnedĀ the community about these kinds of risk. He alsoĀ explainedĀ that attacks like these on the Lightning network could also affect the main Bitcoin blockchain.
You now know where the Lightning network came from and where itās going.Ā You even know when the Lightning network release date was (you just need to pick one!). Before you go, Iām going to make a summary of everything good and everything bad about this exciting new developmentā¦
Lightning Network: Pros and Cons
My Grandma always tells me to start with the bad news, so here it is!
ā The Lightning Network isnāt ready yet.Ā Itās hard to say how successful it could be until itās being used byĀ hundredsĀ of thousands of people. Unfortunately, the Lightning network has enough issues to keep the development community busy for quite a long time.
And now the good news!
PROs
ā Itās a long-termĀ solution to the scalability problem.Ā Other platforms - like Bitcoin Cash - have made changes to Bitcoin which they think solve the scalability problem. However, their solutions tend to be short term. If the network is ever going to be truly scalable, thenĀ it will come in the form of a project like the Lightning network. A few other suggested solutions are big enough to fix the problem completely.
ā Micropayments mean micro-fees.Ā The Lightning network could solve Bitcoinās second-biggest problem which is high fees. When it was created, Bitcoin promised super-fast transactions and low or no fees. So far, it hasnāt delivered. But with the Lightning Network, it might be able to shortly!
ā The Lightning network gives users more control.Ā The main Bitcoin blockchain is largely controlled by miners. Miners use very powerful and expensive equipment to complete the tasks involved in processing transactions. On the Lightning network, nodes can be run by anyone; on laptops, home PCs and (one day soon) mobile phones. Bitcoin was designed to include everyone and thatās exactly what the Lightning network wants to do.
Thatās all folks, the Lightning network explained. Iāll leave you with a few last thoughts...
Final thoughts
On January 23, 2018, the major payment services company,Ā Stripe, announced that it was ending its support for Bitcoin payments. Product Manager, TomĀ Karlo,Ā saidĀ that Bitcoin had, ābecome better-suited to being an asset than being a means of exchange.āĀ This means that Bitcoin is valuable but itās not good at being money anymore!
As a technology,Ā Bitcoin is years ahead of traditional banking,Ā but as a money system,Ā itās got a lot of work to do. I want you to think about all the small purchases you make during the day. Can you imagine buying a bus ticket or a cup of coffee with a Bitcoin transaction? The bus would be late and your coffee would be cold by the time the transaction had been added to the blockchain!
Using the main Bitcoin blockchain for small purchases is like using a wire transfer or a cheque to pay for a cup of coffee. You just wouldnāt do it. Youād use a credit card or cash, wouldnāt you?
In the UnitedĀ States,Ā 72%Ā of all non-cash purchases are made with credit and debit cards but they only make upĀ 3%Ā of total spending in dollars. These are the sorts of micropayments that should be happening on the Lightning network. Imagine how much faster the Bitcoin network would run ifĀ the main blockchain was only used to process the 28% of transactions that make up 97% of total spending?
If Bitcoin is going to succeed as digital money then it needs to become a betterĀ āmeans of exchange.ā In my opinion, the Lightning network is the best solution thatās been suggested so far. Itās not quite ready yet but when it is, we might see the kind of Bitcoin network that Satoshi Nakamoto was imagining in 2009.
The content published on this website is not aimed to give any kind of financial, investment, trading, or any other form of advice. BitDegree.org does not endorse or suggest you to buy, sell or hold any kind of cryptocurrency. Before making financial investment decisions, do consult your financial advisor.