DeFi HUB / How a swap works

Getting started

How a swap works

Updated 2026-10-04 · 8 min read · Not financial advice

How a DeFi swap works: quote, slippage floor, and the amount you actually receive

A swap sells one token for another inside a pool or through a route of pools. You sign the transaction. The contract enforces the minimum you set, or it does not.

Quote and floor

The screen shows a quote: 1,000 units of token A for about 1,000 units of token B. Slippage of 1% sets a floor near 990. If the pool can still pay at least 990, the swap completes and you may receive less than 1,000. If it cannot, the transaction reverts. You still spent gas on the attempt.

Use case: a thin pool. The quote looks fair for a small size and worse for a large size. Split the size or raise nothing until you have read the price impact number on that screen. Price impact is the pool moving against you. It is not a fee labeled in the corner.

Questions

Is the quote a guaranteed fill?

No. The minimum-received field is the bound. Anything above that, up to the quote, is what the pool had when the transaction landed.