DEV Community

David
David

Posted on

How to set slippage for a ParaSwap swap

Set slippage to the largest price change you can accept before the swap should stop. This sets a limit on how much less you may receive than the quote; it does not promise the quoted amount.

Choose a limit that fits the trade

Slippage tolerance is the allowed fall in the amount you receive while your swap waits to run. A smaller limit protects your price more tightly, but a fast market move can make the swap fail.

  1. Check the tokens and amount. Confirm the correct token is going in and the correct one is coming out. Then read the quoted amount and the “minimum received” figure, which is the least the swap will accept.
  2. Look at the market and route. A route is the path the trade takes through available pools, or token trading markets. A thinly traded token, a large order, or a route through several pools can make the quote more likely to move before execution.
  3. Set a tolerance you can live with. For a liquid pair in calm conditions, you might start around 0.1% to 0.5%, if the app allows it. This is a starting point, not a guarantee; check the app’s displayed minimum received before signing.

For example, if a 100 USDC sale quotes 0.05 ETH, a 0.5% tolerance sets the minimum near 0.04975 ETH. The ParaSwap crypto swap quote makes that limit useful: compare its displayed minimum with the amount you would accept for the trade.

Check the minimum before you sign

The minimum received is the practical result of your tolerance, so use it to decide whether to proceed. If that amount is too low, lower the tolerance or reduce the trade size.

  1. Review the final wallet screen. Check the token addresses or names, the input amount, recipient, network, and minimum received. Wallets may show a shortened name or address; make sure the network matches the token you selected.
  2. Compare the network fee separately. Gas is the fee paid to process a transaction on the blockchain. It is separate from slippage and may still be charged if a submitted swap fails; review the wallet’s fee estimate before signing.
  3. Sign only if both figures work. The expected output is the quote; the minimum is your lower bound. If either one changed while you were reviewing, refresh the quote and check the new figures.

ParaSwap’s published SDK describes slippage as a transaction limit applied to the quoted route. That distinction matters: raising the limit can help a moving trade execute, but it also permits a worse fill. Do not raise it simply to clear an error without checking the new minimum.

Adjust only when the cause is clear

If the swap fails because the price moved beyond your limit, refresh the quote first. Then decide whether to wait, lower the trade size, or accept a slightly wider limit after checking the resulting minimum.

  1. Refresh after a delay. Prices and available liquidity can change while you wait. Get a new quote rather than signing from an old screen.
  2. Reduce a large trade before widening the limit. A smaller order may move the market less and produce a better minimum. If the quote still needs a very wide tolerance, pause and check the token and route.
  3. Check a submitted transaction on the right explorer. A block explorer shows a transaction’s status on its blockchain. Polygonscan’s transaction information explains statuses such as pending and failed; a pending transaction has not completed, so don’t submit a second swap until you know what happened to the first.

Top comments (0)