Dynamic Fees
Last updated
Last updated
Available on DLMM and DAMM v2.
Creators have the option to use a pool with a dynamically changing fee structure that capitalizes on launch volatility to maximize yield for LPs while protecting against sniper activity.
Dynamic Fee acts as a form of surge pricing based on market fluctuations and volatility.
Since demand for tokens and price volatility are often the highest at launch, Dynamic Fee would also be high. This both mitigates against aggressive sniper bot purchases while capturing more fees for the token creator and LPs in the pool.
LPs earn a swap fee from traders when they perform a swap. The total swap fee will have two components: a base fee and a variable fee .
Total swap fee
The variable fee is a function of real-time price volatility. The fee rate will be applied to the swap amount in each liquidity bin and distributed proportionally to the LPs in that bin.
For more information, please visit .
dynamic_fee_numerator = ((volatilityAccumulator*binStep)^2 * variableFeeControl + 99_999_999_999) / 100_000_000_000
dynamic_fee_percent = (dynamic_fee_numerator / 1_000_000_000) * 100
By default
binStep = 1
variableFeeControl = 2_000_000
volatilityAccumulator is the value inside program and storage in poolState.
All DLMM Launch Pools have Dynamic Fees enabled by default, while creators have the option to use (or don’t use) Dynamic Fee on DAMM v2 Launch Pools, based on their requirements.