When the price of your trade changes between the time you place the order and the time it's completed.
Slippage is the difference between the expected price of a trade and the actual price at which the trade is executed. It is a common occurrence in volatile or illiquid markets.
Imagine you place an order to buy a cryptocurrency at a specific price, but by the time the order is filled, the price has changed. That difference is slippage. It can happen in a fraction of a second, especially in markets with high volatility or low liquidity. Slippage can be either positive, where the trade is executed at a better-than-expected price, or negative, where it is executed at a worse price.
Slippage is more common with a market-order because it is an instruction to buy immediately at the best available price. In a fast-moving market, the price may change between the time you click "buy" and the time the order is executed. To avoid this, many traders use a limit-order, which guarantees a specific price but does not guarantee the trade will be filled.
Many decentralized exchanges allow you to set a slippage tolerance, which is the maximum percentage of price deviation you are willing to accept on a trade. If the price moves beyond your tolerance, the trade will be cancelled.
Slippage can also occur with large orders, especially on a liquidity-pool with a small amount of liquidity. If your order is too large for the existing liquidity, your trade will be filled at multiple price points, which can lead to a significant price difference from your original expectation.