DeFi Impermanent Loss Calculator
Computes impermanent loss of a 50 50 DeFi pool between two assets from the ratio of final price divided by initial price.
โ
Impermanent loss
Impermanent loss (IL) measures how much worse off a liquidity provider (LP) ends up in an AMM pool versus just holding (HODL) the same tokens. The reason is mechanical: the constant product formula (x ร y = k) keeps rebalancing the pool as prices shift. The formula is IL = 2โr / (1+r) โ 1, with r standing for the price ratio. To get a feel for it, run a few examples. ETH doubling (r=2) gives an IL of about 5.7%. A 4x move pushes it to roughly 20%, and a 10x move to around 42%. People call the loss "impermanent" because once the price drifts back to where it started, the IL vanishes. Withdraw before that happens and it locks in for good.
Applications
This is one of the big decisions anyone providing liquidity on AMMs faces, whether on Uniswap v2/v3, SushiSwap or PancakeSwap. Curve keeps IL low between stablecoins because the pairs are pegged. The fee farming offset is the math that matters here: the fees you collect have to outrun the IL before you come out ahead of HODL. Concentrated pools on Uni v3 turn up both the fees and the IL. Common ways to manage it include stable-stable pools such as USDC/USDT, correlated pairs like stETH/ETH, or IL hedging through options.
FAQ
How to avoid IL? Stick to stablecoin pools like the Curve 3pool, choose correlated assets, or skip LP altogether and stake instead.
Do fees compensate for IL? That comes down to volume ร time ร concentration. High-volume volatile pools like ETH/USDC usually pull it off; thin, low-volume pools almost never do.
Does Uni v3 have more or less IL? Proportionally more, since the capital is concentrated, but you also earn more fees while the range stays active. It is a risk-reward bet.
Is IL the same as loss? Not really. Think of it as an opportunity cost measured against HODL. When both tokens rise you still come out ahead, just by less than if you had held them directly.
Related Tools
DeFi Liquidity Pool TVL Calculator
Computes total TVL and per LP token value of a DeFi liquidity pool from both asset amounts, prices and LP supply.
Effective Spread (Microstructure)
Computes the effective spread of a trade: twice the distance between the price at which the trade actually executed and the midpoint between the best bid and best ask at that moment. Unlike the quoted spread, which measures the bid-ask difference, the effective spread captures the real cost the investor paid, accounting for where the order actually filled in the book. The result comes in absolute value and as a percentage of the midpoint. Enter the trade price and the midpoint.
Amihud Illiquidity (ILLIQ)
Computes the Amihud (2002) illiquidity measure: the average of the ratio of the absolute daily return to the dollar trading volume, scaled by one million as is convention. The intuition is that, in illiquid assets, a small volume already moves the price a lot โ so the higher the ratio, the more illiquid the asset. It's one of the most used liquidity measures in research, since it needs only daily price and volume data. Enter the lists of returns in percent and dollar volumes.
DeFi Borrow LTV
Computes maximum borrow allowed by LTV and current LTV.
DeFi Lending Yield
Computes lending yield with DeFi utilization rate.
Tunnel Volume Loss
Calculate the volume loss of a tunnel excavation, VL = Vs รท (ฯยทDยฒ/4)ยท100, the percentage ratio between the settlement trough volume per metre Vs (mยณ/m) and the excavated cross-section area (from diameter D). Volume loss quantifies how much soil 'disappeared' relative to the theoretical tunnel volume โ caused by face relaxation, overexcavation, tail-gap closure behind the TBM shield and consolidation. It is the key control parameter for urban excavation: well-run EPB/slurry TBMs achieve 0.5-1.5% in soils; values above 2-3% indicate problems and excessive settlement. Enter the trough volume and the tunnel diameter.
The results provided by this tool are for general informational and educational purposes only and do not constitute professional, financial, medical, legal, tax or accounting advice. Always confirm important decisions with a qualified professional and official sources.