What is Impermanent Loss in Crypto And How to Avoid it  

By Olayiwola Dolapo
13 Min Read

As an investor actively into decentralized finance (DeFi) for passive income streams, the term Impermanent Loss would ring a bell to you. If you’re new to DeFi and willing to explore its investment opportunity, you should be aware of the risk involved. 

Impermanent loss in crypto happens when there’s a significant change in the value of your tokens in a liquidity pool against the initial worth at the time of deposit. As the name suggests, impermanent losses are considered temporary losses, as the token can return to its initial value, and the losses cancel out.

Before going deep into explaining the concept of impermanent loss, there are specific terms you need to understand to thoroughly comprehend what impermanent losses are, which include Liquidity pools and Automated Market Makers.  

Understanding Liquidity Pools

Liquidity pools are the backbone of how DeFi works. A  liquidity pool is a pool where users deposit tokens that are controlled by an automated smart contract. The tokens deposited in the pools will be of equal ratio, that is, 50% of token A and 50% of B.

The main proposition of a Liquidity pool is to facilitate transactions on decentralized cryptocurrency exchanges (DEX) faster than in the case of centralized exchanges like Binance, where transactions can be delayed. 

Investors who fund a liquidity pool will receive rewards from transactions made with the token in the pool, and they are called liquidity providers. Without them, decentralized exchanges will be illiquid, and users won’t be able to trade on them.

What is an Automated Market Maker? 

In traditional cryptocurrency exchanges, for a trade to be executed, there must be a match in the price a buyer is willing to purchase an asset and the price a seller is willing to sell the assets; without a match, there won’t be any trade. This process is usually slow and takes a long period of going through order books to find complementary prices for both parties. 

Automated market makers (AMM) are associated with DeFi. AMM is permissionless and relies on a liquidity pool, approving trades automatically without going through the traditional processes of finding matching buyers and sellers to execute a trade. AMM relies on a mathematical calculation to determine the prices of tokens in the liquidity pool.

The formula used for calculating used in AMM proposed is: 

tokenA_balance(p) * tokenB_balance(p) = k

However, the most popularized formula is X * Y = K. 

Where X represents token A, and Y represents token B. The value of both assets must always be a constant K. If there’s an increase in the price of token A, then the price of token B reduces to maintain the constant value K. If token B increases, the value of A also decreases to maintain K. However, the K changes in value when the pool needs to expand and accommodate more liquidity providers; afterward, it will have a new constant. 

How to Calculate Impermanent Loss

To understand why token holders and investors fund liquidity pools to be beneficial and why they risk the chances of facing impermanent losses, let’s go over how decentralized exchanges like Uniswap, Curve Finance, and Balancer operates.

Liquidity pools are essentially pots of investment where token holders/ investors get to deposit equal amounts of tokens. 50:50 of token A and likewise for token B. These tokens are mostly ERC-20 tokens, as most DeFi is built on Ethereum. 

To put this into perspective, rather than token A and B, let’s use the example of Ether (ETH) and Tether (USDT). Assuming 1 ETH is the equivalent of 100 USDT, then to deposit into a Uniswap liquidity pool, the liquidity provider will put in 50% of both. 

In this context, the liquidity provider has 1 ETH and 100 USDT. If the total worth of the Uniswap ETH/USDT pool is worth 20 ETH, that is, 10 ETH and 1000 USDT, then the liquidity provider owns 10% of the liquidity pool’s token. Here’s the calculation: 1 ETH + 100 USDT = 2 ETH = 10% of 20 ETH. 

If Uniswap pays a fee of 0.3 for every transaction on the pool to the liquidity provider and the total volume of trades so far on the pool hits a trading volume of 2000 ETH, the liquidity provider will receive 0.6 ETH. The calculation is 0.3 of 2 ETH (10% of liquidity provider) = 0.6 ETH. Which invariably is 0.3ETH and 30 USDT earned from the transaction fee, so by the time of withdrawal, the liquidity provider now has 1.3 ETH and 130 USDT, making them profitable. 

This is assuming the prices for ETH and USDT were constant throughout the period in the liquidity pool before the withdrawal. 

Understanding Impermanent Losses and How it Happens

As mentioned, Impermanent loss in crypto happens when there’s a significant change in the value of your tokens in a liquidity pool against the initial worth when first deposited. These changes in the value of crypto tokens are due to the volatile nature of the market. Practically, impermanent losses happen both ways, whether the market goes up or down. 

Using the example earlier, if the value of ETH had risen to the equivalent of 300 USDT, which is 3X more. The change in price causes an imbalance in the worth of assets in the pool, and to level it out, arbitrage trading occurs to keep the value of the pool at 50:50. After the arbitrage trades, the pool is worth 30 ETH from the initial 20 ETH. Since the liquidity provider owns 10% of the pool, they now have 3 ETH.

Assuming the liquidity provider held on their asset would have 400 USDT since one ETH is now worth 300 USDT, and they have 100 USDT. This leaves the liquidity provider with 100 USDT in the loss. 

Note that impermanent losses don’t account for the profit made through trading fees which might cover the potential losses. In this situation, the total transaction fees received by the liquidity provider is 200 USDT; then, with the impermanent loss of 100 USDT taken out, there Is a profit of 100 USDT.

Also, an impermanent loss isn’t counted until after withdrawal since the prices of the pool’s assets can return to their initial value. 

How To Prevent Impermanent Loss

While impermanent losses might seem non-negligible, there are ways to avoid exposure. Here are some of the best approaches to avoiding these types of losses: 

Choosing Less Volatile Pairs

The simplest method of avoiding impermanent losses is to keep away from tokens with high volatility. The volatile nature of the cryptocurrency market is responsible for the rapid price movement, leading to loss. 

As a liquidity provider or a potential liquidity provider, the best way to offset this is by depositing into pools with tokens known to have more stability in price movements. Examples of such tokens include an ETH-based pair, a stablecoin pair, and ETH-based pair and wrapped tokens. 

Sticking With Stablecoins

Choosing Stablecoin pairs is an excellent way to offset the impermanent loss. Stablecoins are cryptocurrencies known to give relatively stable prices and are backed by real-world assets like USD dollars and gold. 

Since there’s barely any room for volatility in these cases, there’s a slight chance for arbitrage trading opportunities leading to impermanent losses. With this, a liquidity provider doesn’t fear the risk of rapid movement in the prices of tokens.

Choosing Tokens With High Transaction Fees

Another way to avoid impermanent loss is to remember that the losses aren’t permanent since tokens can return to their initial value when purchased. 

Instead, as a liquidity provider, it can be helpful to focus on token pairs that generate high transaction fees to counterbalance the loss and give a good return. Importantly, treat this as an investment vehicle. 

Explore More Liquidity Pool 

One of the best ways to avoid impermanent losses is by exploring liquidity pools with more flexibility. A significant cause of impermanent losses can be linked with the 50:50 ratio most liquidity pools offer, where a change in token price affects the pool’s balance.

Other types of liquidity pools offer a different and more flexible system for depositors that doesn’t rely on a 50:50 ratio.

For a decentralized platform like Balancer, liquidity providers don’t stick with the 50:50 ratio; instead, they can choose the ratio of how they want to deposit in the pool. Here’s how it works in a Balancer Pool: a liquidity provider can decide to invest 95% in token A while 5% in token B. Doing this reduces the impact of the change in the price value of an asset.

There are also market-neutral AMM such as SwaapFinance also being developed to prevent liquidity providers from losing to arbitrage traders. This market-neutral AMM takes a distinct approach to solving this problem.

Using One Side Staking Pool

While this isn’t widely known yet, liquidity providers can deposit into pools offering just one token. These types of AMM pools don’t hold the risk of impermanent losses since there won’t be arbitrage trading in this type of pool. In addition, liquidity providers will receive a certain percentage fee from every transaction using the pool’s token. This way, being a liquidity provider isn’t a loss or downside. 

This way, the liquidity provider is wholly exposed to the token’s volatility and earning fractions of transaction fees. If the token rises, the liquidity provider profits from it. Bancor is an example of an exchange offering one-sided liquidity pools. 

Conclusion

Impermanent losses in crypto are risky and can jeopardize the potential earning of liquidity providers in any pool. A person planning to be or is a liquidity provider must first be aware of the risk and follow the solutions listed above to best evade it. Impermanent losses can’t be avoided but curbed.

After losing his DOGE tokens due to a limited understanding of blockchain technology, Dolapo made a pledge to explore its vast potential. Now, as a dedicated writer, he sheds light on the intricacies of this innovative technology for others. Dolapo distinguishes himself with his expertise in marketing.