SwanBitcoin445X250

In order to make payments on the lightning network — Bitcoin’s second layer solution for instant and cheap transactions — users must first fund lightning channels. This process, however, creates a slight disconnect between lightning users and on-chain users. Lightning users can pay lightning users, and on-chain users can pay on-chain users, but they can’t pay one another directly.

To solve this, “Submarine Swaps” allow users to make trustless transactions between lightning addresses and on-chain addresses in either direction. The technology could be a game changer for both Bitcoin lightning and mainnet users, as it would remove the transaction barriers between them.

“[I] think this makes it a lot more attractive to [run] a lightning-only service,” Submarine Swap’s developer Alex Bosworth told Bitcoin Magazine, as on-chain users wouldn’t beexcluded. “You don't have to [...] worry about including the on-chain people,” he said. “You can outsource that to somebody else, and you don’t have to trust them.”

What Are Submarine Swaps?

Using the same cryptographic tricks as those used in the lightning network, Submarine Swaps use a trustless middleman to link a Lightning channel transaction with an on-chain one. This middleman, likely a program called a swap provider, is tasked with settling both the on-chain and off-chain transactions with both users, bridging the gap between Bitcoin’s network and the lightning network.

If one lightning network user wants to send funds to an on-chain user, for example, the middleman will transfer these funds to its own lightning wallet, if (and only if) he sends a transaction with comparable funds on the Bitcoin blockchain to the desired on-chain address. The process works the same in the inverse if an on-chain address wants to send funds to a lightning address.

“There's lots of different ways it can be used,” Bosworth said. “So

Read more from our friends at Bitcoin Magazine: