> For the complete documentation index, see [llms.txt](https://docs.sherpa.trade/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.sherpa.trade/sherpa-trade-automation/swap/safeguards.md).

# Safeguards

### Slippage

Definition: Difference between the initial quote and the actual amount received after execution. &#x20;

Mitigation: Users can set the permissible max slippage allowed between the time they agree to place the trade (accept the quote and click execute) and the time when the order actually finalizes onchain.

<figure><img src="/files/Derykc1sHFzHAHskVWoG" alt=""><figcaption><p>Any setting above 3% will add a yellow warning.</p></figcaption></figure>

### Price Impact&#x20;

Definition: Effect your price will have on the price of transacted assets as a result of liquidity limitations.

Mitigation: Users can dial in a permissible maximum price impact to prevent them from accidentally trading via an illiquid market.  Slippage alone wont save someone from making a catastrophic trade, however price configs add market improvement.

<figure><img src="/files/R973KDgPZfQ382AXyncp" alt=""><figcaption><p>Any setting beyond 5% will add a yellow warning.</p></figcaption></figure>

{% hint style="info" %}
Price impact configuration and protection also applies to Strategy Lab orders.
{% endhint %}

### Route Staleness

Aggregators will cache the onchain state to lessen costs.  This is especially noticeable for less traded, low liquidity token pairs which dont frequently experience new pricing every minute (or even every hour). At times these aggregators will inadvertently route through undesirable asset pools which can result in catastrophic outcomes when unchecked.  Sherpa's meta aggregation algorithm senses stale routes and side steps these to save user capital from being squeezed on any such hop through inefficient or outdated markets.
