> ## Documentation Index
> Fetch the complete documentation index at: https://docs.arc.io/llms.txt
> Use this file to discover all available pages before exploring further.

# How-to: Set slippage tolerance or stop limit on swaps

> Set a slippage or stop limit to protect against rate changes

Set a slippage tolerance or stop limit to avoid receiving less than expected on
a swap due to market fluctuations:

* A **slippage tolerance** lets you set the maximum percentage difference you're
  willing to accept between the estimated and actual swap amount, expressed in
  bps (for example, 100 bps = 1%).
* A **stop limit** lets you set the exact minimum amount you want to receive.

If both are configured, the stop limit takes precedence.

## Prerequisites

Before you begin, ensure that you've:

* [Installed the App Kit SDK](/app-kit/tutorials/installation)
* [Configured an adapter](/app-kit/tutorials/adapter-setups)

These are required so any example below runs with a valid `kit` and `adapter`.

## Set slippage tolerance

This example sets a slippage tolerance of 100 bps (1%):

```typescript TypeScript theme={null}
const output = await kit.swap({
  from: { adapter, chain: "Arc_Testnet" },
  tokenIn: "USDC",
  amountIn: "1.00",
  tokenOut: "EURC",
  config: {
    // Set the slippage tolerance to 100 bps
    kitKey: process.env.KIT_KEY as string,
    slippageBps: 100,
  },
});
```

With `slippageBps` as `100` as in the example, you'll receive at least 99% of
the estimated amount. Meaning if the swap rate is 1 USDC to 1 EURC, you'll
receive at least 0.99 EURC.

<Note>
  The `slippageBps` default is 300 bps. `0` represents no tolerance, which
  increases transaction failure rates.
</Note>

## Set stop limit

`stopLimit` defines the minimum amount of the token type specified in `tokenOut`
that you'll receive on a swap.

This example sets a stop limit of 0.95 EURC, meaning you won't receive any less
than that on a swap:

```typescript TypeScript theme={null}
const output = await kit.swap({
  from: { adapter, chain: "Arc_Testnet" },
  tokenIn: "USDC",
  amountIn: "1.00",
  tokenOut: "EURC",
  config: {
    kitKey: process.env.KIT_KEY as string,
    // Set stop limit to 0.95 EURC
    stopLimit: "0.95",
  },
});
```
