Lightning Network Simulator (HTLC Routing)
Lightning is a network of bidirectional payment channels. You don't need a direct channel with everyone; payments are routed through intermediate nodes using HTLCs (Hashed Time-Locked Contracts). Watch how channel liquidity shifts during a multi-hop payment.
50k
Router
50k
1. Direct Payment (Alice ⇄ Bob)
Move the slider to create new Commitment Txs rebalancing channel 1 off-chain.
2. Multi-Hop Routing (Alice ➔ Carol)
Alice pays Carol through Bob. The payment is locked with a Hash and settled by revealing the Secret.
The Lightning Network: fast payments on top of Bitcoin
Lightning is a second-layer network built on top of Bitcoin that allows near-instant payments with very low fees. Instead of recording every payment on the blockchain, two parties open a channel with an on-chain transaction and then exchange payments off-chain, updating the balance between them.
To pay someone you do not have a channel with, the payment is routed through other nodes using HTLCs (hash time-locked contracts). Each intermediate node forwards the payment for a small fee, and the hash preimage guarantees that either everyone gets paid or nobody does.
How to use the simulator
Move balance in the channel between Alice and Bob to create new commitment transactions, then send a payment from Alice to Carol through the router. Watch how liquidity shifts on each side of each channel.
Advantages and limits
Lightning is useful for small, frequent payments. It requires channel liquidity, connected nodes and some care with channel state backups. Closing a channel requires an on-chain transaction.
Note
The simulator uses a fictional network for teaching purposes. It does not move real funds.