๐Ÿ“Š Calculating IL: The Math Behind Losses

Learn the formula to predict impermanent loss at any price ratio

๐Ÿงฎ Calculating Impermanent Loss

You can calculate impermanent loss using a mathematical formula based on the price ratio between deposit and withdrawal. This helps you understand your risk before providing liquidity.

๐ŸŽฎ Interactive: IL Calculator

0.1x10x
If You Held
$10000
As LP
$10000
IL
0.00%
Dollar Impact
$0 gain
Price Movement
0%

The IL Formula

IL = 2 ร— โˆš(price_ratio) / (1 + price_ratio) - 1

Where price_ratio = current_price / initial_price

Example: If ETH goes from $2000 to $4000, price_ratio = 2

1.25x price change-0.6% IL
1.5x price change-2.0% IL
2x price change-5.7% IL
4x price change-20.0% IL
5x price change-25.5% IL
๐Ÿ’ก

Important Notes

  • โ€ขIL is the same whether price goes up or downโ€”only the ratio matters
  • โ€ขFormula assumes 50/50 value split (most common AMM setup)
  • โ€ขTrading fees are NOT included in this calculationโ€”they offset IL
  • โ€ขConcentrated liquidity (Uniswap v3) has different IL characteristics

Real-World Example

๐Ÿ“ˆ

Bull Market Scenario

You provide $10,000 liquidity (5000 USDC + 2.5 ETH at $2000). ETH pumps to $4000.

If held:$15,000
As LP:$14,142
IL:-$858 (-5.7%)
๐Ÿ“‰

Bear Market Scenario

Same $10,000 start. ETH crashes to $1000 (0.5x price ratio).

If held:$7,500
As LP:$7,071
IL:-$429 (-5.7%)

When Fees Offset IL

Pool TypeDaily VolumeAnnual Fee APRIL Break-Even
StablecoinHigh5-15%Easy - low IL
Blue ChipVery High20-50%Possible - moderate IL
Volatile PairMedium10-30%Difficult - high IL
Meme CoinLow5-20%Unlikely - extreme IL