How Do Liquidity Pools Work?
So you have some tokens in your wallet…leverage them to earn a yield with Crypto Liquidity Providing!
In this post, we’re sharing everything you need to know about how liquidity pools work.
Before DeFi came into existence, it used to be that your only options were to buy, sell or hold tokens on centralized exchanges. Moving the tokens from centralized exchanges to wallets that can interact with Ethereum and Defi opens up a whole new world of possibilities. In 2021, you can deposit tokens with robot hedge funds, earn interest with lending protocols or even mint DAI stablecoins by depositing collateral into the Maker system.
In this installment of the APY.Vision Educational series, we are going to discuss what was recently made possible by Uniswap and the Automated Market Maker (AMM) model, providing liquidity (sometimes referred to as Liquidity Providing, or LPing) to AMM pools to earn revenue on swap fees.
How Do Liquidity Pools Work?
Simply put, a liquidity pool is a smart contract where you can deposit tokens (2 tokens, equal amount of each) in the hope of earning a return. This is like market-making in traditional financial markets with one key difference — liquidity pools are automated. Here is the detailed explanation of the process –
Each Uniswap liquidity pool is a trading venue for a pair of ERC20 tokens. When a pool contract is created, its balances of each token are 0; in order for the pool to begin facilitating trades, someone must seed it with an initial deposit of each token. This first liquidity provider is the one who sets the initial price of the pool. They are incentivized to deposit an equal value of both tokens into the pool.
Source: Pools — Uniswap Core Concepts
Why is a liquidity pool needed?
Why should you want to know how liquidity pools work? Liquidity pools are similar to traditional order book exchanges in that they both facilitate trading, but there are significant differences in the mechanisms used. Liquidity pools automate participation and administrative functions that market makers in traditional financial markets spend significant time and resources on. By building this protocol on Ethereum, anyone with spare liquidity (tokens) can be a market maker in a trust-less manner. This is revolutionary as it was once difficult to become a market maker without having the intensive capital that only select groups of financiers had.
A blockchain-native liquidity protocol should take advantage of the trusted code execution environment, the autonomous and perpetually running virtual machine, and an open, permission-less, and inclusive access model that produces an exponentially growing ecosystem of virtual assets.
Source: Pools — Uniswap Core Concepts
What are the risks to providing liquidity? What is impermanent loss (IL)?
Liquidity pools have risks associated with them just like any other asset. The ideal scenario for a pool is two assets that do not diverge far from each other in price. An example of two assets that will not have significant price divergence is a pool comprised of two stablecoins. The most common base pair asset for Uniswap pools is ETH, so LP’s must consider ETH price trends when planning their pool investments. A very bad situation for a pool would be for ETH to be rising in price and the other asset falling price, that causes significant price variation. Price variation is bad for pool returns as it causes the dreaded impermanent loss.
Due to the unique characteristics of AMMs and how it prices the assets, Impermanent loss (IL) is the mechanism that can generate negative returns in pools. Wild price swings can cause significant IL.
Market making, in general, is a complex activity. There is a risk of losing money during large and sustained movement in the underlying asset price compared to simply holding an asset.
Source: Understanding Returns — Uniswap Core Concepts
It is not all bad news however, as revenue from swap fees can often be larger than losses from IL, resulting in a positive net return. In addition, IL only happens when you exit the pool, so in the ideal scenario, if you exit the pool with the same exchange rate / allocation of all the assets as what you had originally, then there would no IL. This is why Stable Coin / Stable Coin pools are so popular as they minimize the variation in exchange ratios between the two tokens.
One way to determine this is to use the analytics features on APY.Vision. The data below gives you an idea of what the returns might look like in an IL situation.
- 1.25x price change results in a 0.6% loss relative to just holding the asset
- 1.50x price change results in a 2.0% loss relative to just holding the asset
- 1.75x price change results in a 3.8% loss relative to just holding the asset
- 2x price change results in a 5.7% loss relative to just holding the asset
- 3x price change results in a 13.4% loss relative to just holding the asset
- 4x price change results in a 20.0% loss relative to just holding the asset
- 5x price change results in a 25.5% loss relative to just holding the asset
You can find a more in-depth and technical explanation of Uniswap and liquidity providing in this blog post by Pintail.
How much can I earn by providing liquidity to a pool?
The returns on liquidity providing can have a wide range depending on the types of pools you deposit into. The portfolio tracking features on APY.Vision are an essential resource to track LP returns. When investing in liquidity pools there are great opportunities for positive returns, but also a great risks of negative returns. Here are a couple of important things to remember about liquidity pools and generating returns.
- Stablecoin pools have less risk of impermanent loss
- Large price increases or decreases are not good for LP returns
- Pools need volume to earn fees
- Fees are shared with other LPs in the pool
How do I invest in liquidity pools?
APY.Vision has recently published an article that can walk you through the various ways you can invest in liquidity pools. It gives a broad overview of the platforms Uniswap, Balancer, Sushiswap, Zapper, Argent and Zerion.
What is the process like to enter the liquidity pool?
Your tokens will be converted into LP tokens once you deposit them into the pool. Once the LP tokens are in your wallet you can start tracking the returns. When you withdraw from the pool, you will receive back a new proportion of the two tokens based on price fluctuations, trading volume and pool reserve size. You are able to track the current amount of each of the token balances your LP share represents using wallet trackers like Zapper and APY.Vision.
Now you know how how liquidity pools work!
Check out APY.Vision!
APY.Vision is an advanced analytics tool for liquidity pool providers and yield farmers. If you’re using any DEXs, AMMs, or liquidity pools this is the tool you will need to easily track the ROI of your liquidity provider and yield farming activities. Try it now!
APY.Vision does not give investment advice and always insists that you do your own research. Read our full Legal Disclaimer.