If you zoom in very closely on your Lightning Network wallet, this is what you’ll see

The Economics of Lightning Network Fees

Justin Goro
Social Evolution
Published in
11 min readJan 18, 2018

--

The Bitcoin community in 2017 forked into communities and Bitcoin Cash emerged to cement a parting of core ideologies.

On the one side of the heated showdown are those who believe in allowing the Bitcoin block size to grow as needed. Their coin, Bitcoin Cash, is currently allowing a block size limit of 8 megabytes (Mb). In this way, as Bitcoin (Cash) becomes more popular, the transaction throughput will increase to match, allowing Bitcoin to remain forever the electronic cash envisioned in Satoshi’s Whitepaper.

On the other side are the “small-blockers” who believe in keeping the block size limit at 1Mb and only allowing eventual growth to 2 or maybe even 10 but not getting carried away with block size increases. They believe that Bitcoin’s blockchain should be the ultimate settlement layer but that micro-transactions can happen on another layer, only to be settled later on the main chain. Their technical solution to bring this to bear is close to being released: The Lightning Network. They believe that by implementing another layer on top of the existing blockchain, the block size limit will allow for thousands of more transactions per second per Mb.

The purpose of this article is not to weigh up the pros and cons of the 2 sides. Instead I want to examine the economic incentives created by the introduction of the Lightning Network (LN). The first section will give a very quick overview of the structure of the LN with some examples of real world use cases, highlighting tradeoffs faced by users on the network. This is done by first explaining what payment channels are and then scaffolding on top of that to introduce the LN. If you’re familiar with these concepts, you can skip straight to the section titled “Dynamic Incentive Analysis” for an economic breakdown of how the LN will affect the fees of both miners and LN nodes.

Payment Channels

In 2014 I attended a bitcoin conference and had the opportunity of speaking with the CEO of GEM, Micah Winkelspecht. GEM was at the forefront of making the client side of bitcoin, the wallet, programmable by exposing an API to developers to quickly spin up features that were otherwise odious to replicate or fork from existing open source wallets: A wallet as a service. Among these features offered were some cutting edge protocol developments such as mutlisig and time locked transactions but the one that the development team was particularly excited about was payment channels. To explain payment channels, I’ll use a fictional example:

Bob wants to use a new bitcoin powered version of Netflix called BlockchainBuster. Traditional Netflix works by charging you a monthly fee and then dividing that amongst the owners of the content you watch so that popular shows are automatically rewarded more. If you pay $10 per month and you spend 8 hours watching Daredevil and 2 hours rewatching Planet Earth then Marvel will get $8 and BBC will get $2 (business model simplified, obviously).

BlockchainBuster uses a similar model but instead of knocking your credit card once a month, they’ve utilized some advanced features of the blockchain to enable a pay per second billing. They convert the $10 you’d usually pay for a month of Netflix into 0.0002 cents per minute.

Of course doing this with plain vanilla bitcoin payments would be ludicrous because the fee associated with each transaction is currently more than a few dollars. For the same reason, credit card technology cannot handle so many frequent small payments without the credit card fees vastly overshadowing the actual billing.

A payment channel exists for exactly this sort of case. Instead of Bob’s bitcoin wallet sending off hundreds of transactions a day, it establishes a link to BlockchainBuster which allows Bob and BlockchainBuster to send eachother money back and forth at no cost for as long as the link is active. Once the link is closed, the final net amount sent is recorded on the blockchain as one example. Below is an example of 2 wallets establishing a channel. Instead of machine code, the wallets are speaking English to each other.

Payment channel established by 2 wallets speaking plain English: “let’s establish a payment where I pay you 2 btc. Let’s use cryptography to link each other together so that neither of us can flee with the 2 btc. We won’t broadcast the 2 btc payment to the blockchain while this link (or channel) exists. The moment the channel opens, you agree to refund me 100% of the 2 bitcoin. The longer the channel stays open, the smaller the refund gets until either of us closes the link or until the refund reaches zero and you get the full 2 bitcoin. At that point we broadcast just 1 transaction to the blockchain which is equal to the original amount minus the refund.”

When you first read the above, your head will probably spin a bit so I’ll continue to use the ongoing example of Bob and BlockchainBuster. Bob opens a payment channel to BlockchainBuster for 10 bitcoin. The channel is cryptographically secured so that neither Bob nor BlockchainBuster can run off with the 10 bitcoin before the channel closes. As the channel opens, BlockchainBuster immediately instructs that the entire 10 bitcoin is refunded to Bob. However, while the channel is open, Bob can’t run off with it. As Bob watches different shows, 0.0002c worth of bitcoin is deducted every minute from the refund. So initially BlockchainBuster refunds the entire 10 bitcoin but after a minute of Bob watching, the refund has now shrunk by some very small fraction. It’s now something like 9.9999.

Bob binge watches Daredevil, the Defenders and the Punisher and racks up about 20 hours of viewing before logging off, sending a signal to BlockchainBuster to close the channel. Let’s assume that the Bitcoin dollar price is $20000 per bitcoin. Bob spend about 27 c which is equal to 0.0000135 bitcoin. BlockchainBuster refunds Bob 10 minus 0.0000135 = 9.9999865 bitcoin and the payment channel is closed by finalizing on the blockchain that Bob sent 0.0000135 bitcoin to BlockchainBuster with just 1 transaction fee, not 1200(= 20*60) that would have come off had his wallet sent those as individual payments.

Payment Channel Weaknesses

Payment channels introduced a clever trick using refunds to mimic micropayments securely on the blockchain. However, a channel alone suffers a number of shortcomings which is why they never took off. For one, you can only have micropayments for very special cases. In this example, Bob is a known customer of BlockchainBuster. They have to both conduct a kind of handshake before this happens. Secondly, Bob has to be a very frequent user of BlockchainBuster for this to make sense. Channels probably make the most sense not between customer and user but between 2 parties that are both sending money back and forth regularly.

Payment channels don’t solve high blockchain fees. Once the channel is closed, a transaction has to be broadcast to the blockchain and this could still be unacceptably high relative to the volume of payments.

Technological solutions like this should be ambient and not require explicit user participation. For instance, when you visit a static site, HTML is delivered to your browser which begins a first pass rendering. Somewhere in the HTML there might be an image element that simply contains a URL to where the image is stored. The browser then has to fetch that image and display it on a second pass render. Imagine if your browser didn’t auto detect the images and you have to wire that all up yourself each time. This would create an unacceptable web experience for most users and use cases. Similarly, forcing users to keep track of open channels and manage them is unlikely to be a runaway hit during an online shopping experience.

Lightning Network: a web of payment channels

The innovation of the Lightning Network was to take the basic idea of a payment channel and create a web of channels from that. By leveraging the concept of network routing, the Lightning Network will benefit immensely from the network effect of adoption in a similar way to how cellphone networks become increasingly valuable when more than just a handful of people in the world are using them. To illustrate, let’s start from a Day Zero scenario and gradually add more users to the network to see how it (and we) benefit:

  1. Bob and BlockchainBuster decide to adopt Lightning Technology. For now nothing changes since they’re the only 2 people on Earth using the network and so their regular payment channel carries on as usual.
  2. Sarah signs up to BlockchainBuster and decides to set up her own channel with them.
  3. Starbucks decides to get on board and offers Lightning support for regular customers and as an early adopter, Sarah excitedly opens a channel with them.
  4. BlockchainBuster has a great many computer hardware expenses and convinces their supplier, Incredible Computer, to adopt LN and open a channel.

The network of channels now looks like this:

each arrow represents an open payment channel

Now that we have a basic network of channels open, we can immediately see some of the benefits of using the LN:

  1. Incredible Computer also sells retail and Sarah wants a new PC. Her wallet detects that she doesn’t need to establish a payment channel with them. Instead it will use a clever networking strategy called routing. Sarah’s wallet sends BlockchainBuster the money with the instruction that its intended for IncredibleComputer. BlockchainBuster can forward the payment over its channel with IncredibleComputer but has no way to steal Sarah’s money.
  2. Now Bob wants to really make it through a binge session of Grace and Frankie and stops at Starbucks for a coffee. His wallet detects that a path exists between he and Starbucks via 2 jumps: BlockchainBuster and Sarah. He never has to establish a channel directly with Starbucks but can still make use of channel enabled microtransactions. For Bob, paying for the coffee and was instant and cheap.

As you can see, the more of these permanent channels open, the more people can simply use the lightning network for all their payments. They need only open one channel to a highly connected person and using the law of 6 degrees of Kevin Bacon, they’ll be able to pay anyone.

The adoption overhead is also very low. It’s similar to how when you need the internet, you connect to your ISP and they bring the world to you. One connection, infinite end points.

Each circle in the diagram above is called a Lightning Network node. Nodes who are open for people to hop past them gain an incentive for doing so by charging a fee to the user. To illustrate, review the example of Bob wanting coffee. He can hop past BlockchainBuster and Sarah to make a channel payment to Starbucks but for providing that path, BlockchainBuster charges 0.0001 bitcoin and Sarah charges 0.002. In total Bob pays 0.0021 bitcoin in fees. His wallet can detect the total fees he’ll have to pay and can either look for a cheaper path over the Lightning Network or if the LN fees are all too high, can just log it to the actual blockchain as a traditional bitcoin payment.

One final technical point. Bob can only make a jump through Sarah if Sarah has enough bitcoin to actually pay Starbucks. Suppose Sarah has established a channel of 0.5 bitcoin with Starbucks initially and has purchased so many products from Starbucks that there’s only 0.000001 bitcoin left in the channel. Assume Starbucks coffee costs 0.01 bitcoin. Bob’s wallet will detect that Sarah is unable to make the payment and will find another route. In this way, the more bitcoin a node has, the more traffic they can handle on the LN and hence the more fees they can collect.

Dynamic Incentive Analysis

The positive incentives for establishing a node on the LN are clear: routing payments enable nodes to collect fees. The fees collected are in proportion to the bitcoin collateral put up which is why LN has been referred to as Bitcoin’s Proof of Stake. As more nodes are established, the value of the LN will increase quadratically because of the network advantages explained in the previous section. This will accompany a rise in demand for nodes and as such more nodes will come online in order to earn fees.

As the network grows, many transactions that usually occur on the blockchain such as small payments will be offloaded onto the LN and the demand for block space will fall. Recall that from the original channel example, the payment isn’t entirely final until the channel is closed and logged to the blockchain. If the LN is big enough and flows of bitcoin are multidirectional enough then the rate of channel closing will fall. In the figure above, suppose Bob paid Sarah 1 bitcoin by hopping via BlockchainBuster. 30 minutes later, Sarah pays Bob 1 bitcoin using the same approach. On net, nothing has happened which means Blockchain buster doesn’t have to settle anything on the blockchain and can leave the channel open as though nothing happened.

This means that the network might handle thousands, if not millions of transactions before a single transaction is broadcast to the bitcoin blockchain.

The effect of this initially will be to reduce blockchain fees substantially as competition for block space is reduced. However, they won’t fall to zero. Since nodes charge fees, traditional on chain payments are still desirable when the cost of doing so is less than using the LN. The competition between LN nodes and between miners and LN nodes will put downward pressure on fees charged throughout the system in the short run.

The Long Run

As the LN matures, the transaction throughput on it will vastly exceed VISA or any traditional centralized payment network. The microtransaction use case that until now has not been fulfilled by a single cryptocurrency, will open up a sea of use cases and revolutionize the way many services are used. Bear in mind also that all the LN nodes locking away coins will increase bitcoin scarcity, driving up price. At this point, bitcoin will be both an electronic cash for P2P payments and an excellent store of value. There have been fears that the LN will undermine the security of the network by lowering the fees miners can earn in performing their proof of work security. However, working in the opposite direction, the space of possibilities opened by the LN will increase demand for bitcoin and nodes do occasionally have to settle on chain. If the block size remains at 1 Mb then there still exists an upper limit of LN nodes, after which the block is filled again (perhaps it is entirely filled with node settlements and nothing else). At that point miners can again auction off limited space. What the LN does is not eliminate competition for scarce block space; instead it amplifies the amount of transactions that a full block can handle before on chain fees have to rise.

Conclusion

The Lightning Network will initially reduce the blockchain load by allowing users to exchange value off chain. By introducing low cost, fast micropayments to the ecosystem, a new category of use cases will come online, increasing long term demand for bitcoin as entirely new industries and business models emerge. LN nodes do occasionally have to settle their open channels using a traditional transaction to the blockchain. Beyond some network size, this settlement requirement will fill up the 1 Mb block limit. At that point, fees on the blockchain will rise, bid up by LN nodes. As that happens, LN nodes must either raise their fees or cease operating, curtailing further market expansion. Understood this way, the LN simply amplifies what 1 Mb of maximum block space can achieve in transaction throughput and has no negative impact on the long run fees paid to bitcoin miners. On the contrary, since the LN enables Bitcoin to act as an electronic cash and a store of value, the popularity of Bitcoin might lead to miners earning far higher fees in the future as Bitcoin fulfills its role as the internet of money.

Flawless Victory

disclaimer: I’ve simplified some of the LN features without sacrificing the ability to expand upon the economics of the network. I’ve also neglected to mention onion routing and atomic payments but both of these should also be factored in when reflecting on the long term demand that LN will engender.

--

--

Justin Goro
Social Evolution

Creator of WeiDai and 92 times emperor of Tsuranuanni