₿ The Book of ₿itcoin
Home / Field Notes

The Lightning Network, Explained With a Bar Tab


Part of the guide: How Bitcoin works

Illustration: two nodes, you and the bar, with many small payments between them and a tab above.
Illustration: two nodes, you and the bar, with many small payments between them and a tab above.

Picture a bar. Instead of paying for every drink one by one, you open a tab. You and the bartender keep adding to it all night. At the end you settle once. That is the whole idea of a payment channel.

Hand-drawn comic: a smug coin opens a bar tab with a bartender and promises to pay once at the end
Hand-drawn comic: a smug coin opens a bar tab with a bartender and promises to pay once at the end

The 10-second version

The problem it tries to solve

The paper starts from the fact that every Bitcoin node has to know about every transaction. It says that if each node "must know about every single transaction that occurs globally," the main chain by itself cannot cover the world's commerce anytime in the near future (Poon and Dryja, 2016). So the idea is to move many small payments off the chain, and use the chain only as the judge when something goes wrong.

The bar tab, in a bit more detail

According to the paper's abstract, the system sends transactions over "a network of micropayment channels (a.k.a. payment channels or transaction channels)" where the transfer of value happens off-blockchain. If someone is uncooperative or hostile, the contracts can be enforced by broadcasting to the Bitcoin blockchain, using "a series of decrementing timelocks."

Plain words: the two sides sign a deal first. Then they update their balances between themselves. If one side tries to cheat, the other can take the signed deal to the main chain.

What the paper does not promise

The paper itself is labelled a draft, and its abstract says some transfers work *if* Bitcoin transactions can be signed with a new sighash type that fixes a problem called malleability. We read the first page, not the whole paper. We are not making claims about how many people use Lightning today, how cheap it is, or how safe your particular wallet is, because we have not checked a current primary source for those.

Where the rules live

The specifications are kept in a public repository. Its README says they are "currently a work-in-progress and currently being drafted," and gives the name: "BOLT: Basis of Lightning Technology (Lightning Network Specifications)" (lightning/bolts on GitHub).

Sources

Keep reading

How Machines Pay for Access: The Bill and Claim TicketHow L402 pairs a Lightning payment with a claim ticket, why machines must show both pieces, and why a bill's deadline isWhy a Robot's Shopping Wallet Might Use DollarsDollar budgets help explain stablecoin checkout. Compare spending, saving and tiny Bitcoin payments without crowning a wBuy One Web Answer at a Time: x402 ExplainedHow an AI agent pays for a web request with x402: the payment instructions, signed permission, checks, and moment the anAll Field Notes →
Copied