Routing

Also: Lightning routing, multi-hop routing

lightning · advanced

The process of finding a path of payment channels through the Lightning network so a payment can hop from sender to recipient.

Lightning is a graph: nodes are wallets, edges are channels with capacities and fee policies. To pay someone you don't share a channel with, your wallet finds a route through the graph and constructs HTLCs along it.

Source routing is the dominant model: your wallet picks the entire path itself, using the public gossip layer to learn about channels, capacities, and fees. The path is encoded as an onion (BOLT 4, Sphinx-style) so each intermediate hop only learns the previous and next hops, not the full route or the sender/recipient.

Routing is harder than it looks. You don't have perfect information about channel balances — only capacities — so attempted routes often fail mid-flight and your wallet has to try alternatives. Fees are heterogeneous (each node sets its own). Liquidity drifts as payments flow. Multi-part payments (BOLT 10's MPP / AMP) split big payments across several routes to work around individual channel limits.

Newer approaches mitigate the failure modes: probabilistic balance estimators, trampoline routing (delegating route-finding to a smarter node), and offers / BOLT 12 for receiver-side route hints.

Related terms

Where you'll see this