Fees

Last modified:

Swap fees

Every swap pays a fee that is distributed pro-rata to all in-range1 liquidity at the instant of the trade. If the spot price moves outside a position's bounds, that position becomes inactive and earns nothing until the price returns.

Unlike earlier versions, v3 does not auto-compound fees into the pool. Accrued fees are tracked separately and must be collected manually by the position owner.

Pool fee tiers

Each token pair may have multiple pools, each with a distinct fee:

TierTypical use
0.01 %Stablecoins (USDC/DAI)
0.05 %Correlated assets (CTN/stCTN)
0.30 %Most volatile pairs (CTN/USDC)
1.00 %Exotic or illiquid tokens

In v2, fragmenting liquidity across multiple fee levels would have degraded execution quality. Concentrated liquidity breaks this constraint: because capital efficiency is decoupled from total pool depth, multiple fee tiers can coexist without meaningful harm to traders.

Finding the right fee

Asset characteristics drive fee-tier selection. Low-volatility pairs gravitate toward the lowest tier — providers face minimal price risk and swappers seek near-parity execution. Exotic or rarely traded tokens tend toward higher tiers, compensating providers for the cost risk of holding less predictable assets.

Fee math

Deduction per swap

The fee is removed from the input amount before the constant-product calculation runs:

amountInafter fee=amountIn(1fee_tier)\text{amountIn}_{\text{after fee}} = \text{amountIn}\,(1-\text{fee\_tier})

For a 0.30%0.30\% pool and a 10 CTN swap:

Fee=100.003=0.03 CTN\text{Fee} = 10 \cdot 0.003 = 0.03\ \text{CTN} Effective input=100.03=9.97 CTN\text{Effective input} = 10 - 0.03 = 9.97\ \text{CTN}

The 0.03 CTN remains in the pool, claimable by in-range providers.

Distribution among LPs

Only in-range liquidity earns fees. Each provider's share is proportional to their liquidity LiL_i relative to the total in-range liquidity LtotalL_{\text{total}}:

LP_fee_share=(LiLtotal)total_fee\text{LP\_fee\_share} = \left(\frac{L_i}{L_{\text{total}}}\right)\text{total\_fee}

Example: Total in-range liquidity is 1,000,000 units; your position contributes 50,000 units. A swap generates 0.03 CTN in fees:

Your fee=(50,0001,000,000)0.03=0.0015 CTN\text{Your fee} = \left(\frac{50{,}000}{1{,}000{,}000}\right)\cdot 0.03 = 0.0015\ \text{CTN}

Fee-growth tracking (feeGrowthGlobal)

The pool tracks accumulated fees per unit of liquidity via a fixed-point accumulator:

feeGrowthGlobal+=fee_amountLtotal\text{feeGrowthGlobal} \mathrel{+}= \frac{\text{fee\_amount}}{L_{\text{total}}}

This value only increases. Fees owed to a position between two points in time:

fees_owed=Li(feeGrowthGlobalnowfeeGrowthGlobalat deposit)\text{fees\_owed} = L_i\left(\text{feeGrowthGlobal}_{\text{now}} - \text{feeGrowthGlobal}_{\text{at deposit}}\right)

The contract also tracks per-tick fee growth (feeGrowthOutside) to handle positions that cycle in and out of range — see whitepaper §6.3 for the full derivation.

Estimating fee APR

For a v3 position with liquidity LL and total in-range liquidity LtotalL_{\text{total}}:

Daily fees=(LLtotal)daily_volumefee_tier\text{Daily fees} = \left(\frac{L}{L_{\text{total}}}\right)\text{daily\_volume}\cdot \text{fee\_tier} Fee APR=Daily fees365position_value\text{Fee APR} = \frac{\text{Daily fees}\cdot 365}{\text{position\_value}}

Worked example: $10,000 deposited in a 0.30%0.30\% CTN/USDC pool. The pool trades $5 M daily with $2 M in-range TVL.

Daily fees=(10,0002,000,000)5,000,0000.003=75\text{Daily fees} = \left(\frac{10{,}000}{2{,}000{,}000}\right)\cdot 5{,}000{,}000 \cdot 0.003 = 75 Fee APR=7536510,000=273.75%\text{Fee APR} = \frac{75\cdot 365}{10{,}000} = 273.75\%

This is a gross figure — it does not account for impermanent loss or time spent out of range. See LP Profitability for the net calculation.

Protocol fees

A governance-controlled protocol fee may be enabled on certain pools, directing a share of swap fees to a specified address for ongoing development. Details: protocol fees and fee-setting rationale.

Footnotes

  1. In-range liquidity: liquidity in any position whose bounds straddle the current spot price.