# Swap Tokens

<figure><img src="/files/wQ2u4a2cIDyHfeLJcTGo" alt=""><figcaption></figcaption></figure>

## Overview

The Swap Tokens step allows you to exchange one token for another within your strategy. This component gives you control over the swap direction, amount, execution timing, and price conditions for optimal trades.

### Swap Direction:

Choose which token you want to exchange for the other:

* **Token X to Token Y**: Convert your X tokens into Y tokens.
* **Token Y to Token X**: Convert your Y tokens into X tokens.

### Swap Amount Percentage:

A slider control lets you determine what portion of your tokens to swap:

* **Range**: 1% to 100% of your available tokens.
* **Visual Scale**: Easily set common values like 50% or 100%.
* **Fine Control**: Adjust in 1% increments for precise allocation.

### Swap Slippage:

Set your maximum acceptable price deviation during trade execution:

* **Recommended Range**: 0.1% to 5% depending on token pair liquidity.
* **Lower Values**: More likely to fail in volatile markets but protect from unexpected price movements.
* **Higher Values**: More likely to execute successfully but with potentially worse prices.

### Price Condition (Optional):

Control when your swap executes based on market conditions:

* **Enable/Disable**: Toggle price condition functionality.
* **Condition Type**: Choose "Above" or "Below" to determine when the swap will execute.
* **Price Target**: Set the exact price or percentage that triggers the swap.
* **Percentage Mode**: Toggle between absolute price or percentage of current price.
* **Current Price**: View and refresh the current market price.

## Strategy Applications

* **Take Profits**: Swap tokens when prices reach favorable levels.
* **Rebalancing**: Adjust your token ratio to maintain desired portfolio weights.
* **Entry Strategy**: Convert stablecoins to tokens at specific price points.
* **Exit Strategy**: Convert volatile assets to stablecoins during market uncertainty.
* **Dollar-Cost Averaging**: Set up recurring swaps at predetermined intervals.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://liquid-nova.gitbook.io/liquid-nova/strategy-steps/swap-tokens.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
