You've just used Dex for the first time… probably not the first time, but you've just started to wonder how exactly it works. Unlike widespread centralized exchanges, DeFi exchange platforms do not have buy walls and sell walls, but asset exchanges are unlimited. Even a cryptocurrency veteran would wonder how exactly this works.
Decentralized exchanges are powered by Automated Market Maker (AMM) protocols that use pools of liquidity to ensure seamless asset exchange while maintaining blockchain-level security. AMM? We will learn about them in my next article. Understanding liquidity pools, the core technology that powers the automated markers in the market, is our current goal.
So what are liquidity pools?
Imagine a basket containing two types of fruit in a dough trading system; taking one of these fruits requires you to exchange them for an equal value of the other fruit. This is basically how DeFi exchanges work now. The bin is here the pool on liquidity.
Liquidity pools are collections of tokens locked in a smart contract that allow token exchange without limits within the pool. Contributors who provide these tokens and lock them into the pool are known as liquidity providers.
To provide liquidity, a liquidity provider locks equal values of the two tokens in the pool. A liquidity pool is therefore a collection of tokens locked by liquidity providers, this pool is available to traders who wish to exchange any of these assets.
The suppliers of liquidity receive liquidity pool tokens (LP tokens) . LP tokens are a cryptographic representation of the percentage of the total liquidity pool held by the individual liquidity provider. Trading fees are distributed among liquidity providers according to the percentage of the pool they hold.
To further incentivize liquidity provision, some projects are launching liquidity farming programs on their platform to reward liquidity providers according to the amount of liquidity they provide. This is popularly known as liquid farming. To earn tokens in a liquidity farming program, liquidity providers stake their tokens to a liquidity pool on the platform and earn according to the APR and the amount of Lp tokens they stake.
However, liquidity provision has its small drawbacks, this is known as perishable loss. Volatile loss is a "temporary" and "illusory" loss suffered by liquidity providers due to a change in the demand and values of the tokens they supply to the liquidity pools.
This is due to a protocol programmed to keep the total value of the tokens supplied to the pool. If one of the assets supplied to the pool continues to rise in demand and value relative to the other, liquidity providers receive the other asset as supply increases with traders depositing more of it into the pool
Assuming you contributed 100USD worth of Ethereum and 100USDT, your total liquidity is 200USD. As the value of ethereum increases, the amount of ethereum you supply continues to decrease as you receive more USDT, this is essentially meant to preserve the 200 USD you added to the liquidity pool.
The "loss" comes from the fact that the profits that should come from the increase in the value of ethereum will be lost. This is illusory because there is really no loss; your 200USD is sustainable, the only difference is that now you have more USDT. This is temporary because if the liquidity provider can wait until the price goes back to what it was when that liquidity was provided, they will receive the same amount of tokens that they provided when they withdrew the liquidity.
Liquidity Pool is a smart technology that not only solves the problems of fake liquidity, but also simplifies the exchange of assets. Liquidity providers may also earn passive rewards from liquidity provider fees.