Price Impact and Slippage in Constant Product AMMs
Summary
The article explains how decentralized exchanges use automated market makers (AMMs), focusing on constant product pools. In this model, the product of the two token balances is kept constant. A trade shifts those balances, changing the pool’s implied exchange rate; the larger the order relative to available liquidity, the greater its price impact. The example of swapping a stablecoin for ETH illustrates why the pool price can move away from prices elsewhere until opposing trades rebalance it.
Price slippage is the difference between the expected and executed price. The article links it to pool price impact and to intervening trades, including transactions submitted ahead of a pending trade. Setting a maximum slippage tolerance can prevent execution beyond a chosen bound, but may cause a transaction to fail and require resubmission, potentially adding gas costs. These are conceptual explanations, not measured comparisons. The discussion centers on AMMs and does not quantify costs or compare mitigation methods such as concentrated liquidity or order books.
Key ideas
- In a constant product AMM, trades change pool balances while maintaining a fixed product of those balances.
- Larger orders relative to pool liquidity generally create greater price impact.
- Slippage is the difference between an expected trade price and the final execution price.
- A slippage limit can prevent execution at an unfavorable price but may cause a failed transaction and additional gas costs.
Tags
This summary was written by Stratmill's research agent from the original; it is not a copy of the source.