What are atomic swaps?

In Guides

With cryptocurrencies, there are several ways to conduct transactions between parties.

Sending Bitcoin to your friend can be done directly on the blockchain by sending the payment directly to his or her wallet.

However, Bitcoin is known to be relatively expensive and very slow at settling transactions, making it impractical to send small payments through the network.

Furthermore, if that friend prefers a different coin, you would then need to send that Bitcoin to a crypto exchange in order to swap to the desired cryptocurrency.

Atomic swaps aim to simplify and speed up the process of sending cryptocurrency quickly and cheaply.

They can be used in two ways:

  • One way is to use atomic swaps to conduct transactions between different blockchains.
  • The other uses them to perform transactions off-chain, thus avoiding the typical fees and confirmation times.

In both cases, atomic swaps are essentially just a smart contract that maintains integrity of transactions and ensures everyone upholds their part of the transaction.

If something goes wrong, the smart contract simply cancels the transaction.

The smart contract performing the atomic swaps is known as the Hashed Timelock Contract (HTLC). As its name suggests, the contract depends on time as the determining factor of the transactions.

Funds are locked in this contract until both parties reach consensus. If the contract has not cryptographically verified that the funds have been received by the recipient within a certain time frame, the transaction will be terminated and funds returned to the sender.

Atomic swaps are still very new to the crypto space but are already promising to provide huge benefits to how we interact with the blockchain on a daily basis. The most prominent application of this technology is in its application to the Lightning Network.

All guest authors’ opinions are their own. Liquid does not endorse or adopt any such opinions, and we cannot guarantee any claims made in content written by guest authors.

This content is not financial advice and it is not a recommendation to buy or sell any cryptocurrency or engage in any trading or other activities. You must not rely on this content for any financial decisions. Acquiring, trading, and otherwise transacting with cryptocurrency involves significant risks. We strongly advise our readers to conduct their own independent research before engaging in any such activities.

Liquid does not guarantee or imply that any cryptocurrency or activity described in this content is available or legal in any specific reader’s location. It is the reader’s responsibility to know the applicable laws in his or her own country.



Providing liquidity for the crypto economy.