How to Set Slippage for a Chainflip Swap
Start with the quote’s recommended tolerance, then check the minimum price, optional oracle guard and refund window before sending funds across chains.
The Chain Media Editors2 min read
For a routine swap, start with the tolerance recommended in the quote and keep its retry window unless you have a specific reason to change it. Slippage tolerance sets the minimum execution price the protocol will accept relative to that quote. A wider tolerance can allow a worse price; it does not improve the quote or reduce fees.
What does the slippage setting protect?
The tolerance sets a minimum price for execution, while the retry window sets how long the swap can wait for that price. If the price floor is not met before the window closes, the protocol refunds the deposit to the address you specified. If you are comparing a personal swap with protocol-managed inventory, how Chainflip treasury swaps work explains the latter’s purpose and constraints.
The price check happens at the automated market maker level. Deposit and broadcast fees are charged outside that check, so the minimum execution price does not guarantee a particular net amount after fees. The quote is the useful starting point because its recommended tolerance reflects current swap conditions.
Should you change the recommended tolerance?
Keep the recommendation for most swaps. Tightening it raises the price floor and can cause the swap to wait or be refunded if the market moves before execution. Widening it lowers that floor, allowing execution at a less favorable price. Neither setting changes the market price or guarantees the quoted output.
- Use the quoted recommendation as your baseline.
- Tighten the tolerance when your priority is refusing a worse price and you can accept a refund.
- Widen it only when you accept the lower minimum price and understand the trade-off.
- Check the quote again if the amount or asset pair changes; the recommendation is specific to that swap.
What happens if the swap misses its price limit?
The deposit waits for an acceptable execution price until the retry window ends, then returns to the refund address. Check that address before sending funds. For a dollar-cost-averaging swap, the minimum price applies to each chunk; a failed chunk can be retried, and any remaining unswapped amount can be refunded while completed chunks still go to the destination.
A separate live-price guard may also be available for some asset pairs. It compares execution with an oracle’s global index price, rather than with the quote, and can help when a long-running swap’s market price moves. Use the quote’s recommendation when available; otherwise, do not assume this additional protection applies.