# Using Grid Bots on Web

### How to Set Up a Grid Bot？

#### Step 1: Create a Grid Bot

1. Log in to your exchange account.
2. Click on your **account avatar**.
3. Click the **"+" icon** next to Bot Accounts.

<div align="left"><figure><img src="https://1790800155-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3kiM6CAFBZoTCJcZ8X7k%2Fuploads%2FEoJv8mWNaGdJ1z4x3Gpz%2Fimage.png?alt=media&#x26;token=1584c0d5-e35c-4fe6-a1ee-de3b42774a83" alt="" width="563"><figcaption></figcaption></figure></div>

4. Enter a name for your bot (e.g., "SOL Grid Strategy").
5. Click **Add subaccount**.

<div align="left"><figure><img src="https://1790800155-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3kiM6CAFBZoTCJcZ8X7k%2Fuploads%2FwSTHQezdQx56AYM9HPPh%2Fimage.png?alt=media&#x26;token=46d44c4b-0303-42e8-aa76-67f037aa6f60" alt="" width="563"><figcaption></figcaption></figure></div>

***

#### Step 2: Fund Your Bot

Transfer funds to your bot subaccount using one of these methods:

* [Transfer funds from your main account](https://support.backpack.exchange/deposit-and-withdraw/crypto/deposit/how-to-deposit#deposit-via-subaccounts)&#x20;
* [Deposit from an external wallet into the subaccount.](https://support.backpack.exchange/exchange/deposit-and-withdraw/crypto/deposit/how-to-deposit)

***

#### Step 3: Select the Trading Pair

1. Enter your bot subaccount.
2. Navigate to the **Bots** section.
3. Choose **Futures Trading**.
4. Select your target trading pair (e.g., SOL-PERP).

<div align="left"><figure><img src="https://1790800155-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3kiM6CAFBZoTCJcZ8X7k%2Fuploads%2FN33SudZi5sjmmpi8pjC6%2Fimage.png?alt=media&#x26;token=5d4f368d-258f-4139-99cd-ea0a05d39df7" alt="" width="563"><figcaption></figcaption></figure></div>

***

#### Step 4: Configure Parameters

1. Set the **Price Lower Limit** — The lowest price in your grid range.
2. Set the **Price Upper Limit** — The highest price in your grid range.
3. Enter the **Number of Grids** — How many price levels to create within the range.
4. Enter the **Total Grid Value** — The capital allocated to this grid.
5. Click **Create Grid** — The bot will begin running automatically.

> **Note:** More grids = more frequent trades with smaller price differences between levels. Fewer grids = less frequent trades with larger price differences between levels.

<div align="left"><figure><img src="https://1790800155-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3kiM6CAFBZoTCJcZ8X7k%2Fuploads%2F2YFfgiPpER0nt78PaV25%2Fimage.png?alt=media&#x26;token=d761b69c-3dfd-4743-a559-fd98f2cdd980" alt="" width="563"><figcaption></figcaption></figure></div>

***

### Take-Profit and Stop-Loss Settings

> ⚠️ **Important:** Take-profit and stop-loss apply to the **entire bot subaccount**, not to individual grids.

#### Stop-Loss

Defines a drawdown threshold that will stop the bot when reached.

**How it works:**

* The bot tracks the starting equity of your subaccount from the moment the strategy is activated.
* If equity falls X% below the starting equity, the bot stops automatically.

**Example:** Starting equity is $1,500. With a 20% stop-loss setting, the bot stops if equity drops to $1,200.

<div align="left"><figure><img src="https://1790800155-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3kiM6CAFBZoTCJcZ8X7k%2Fuploads%2FW4wAcIQZcDwCtBxVqTfb%2Fimage.png?alt=media&#x26;token=d5c446c6-0322-4e83-ae41-693f1128200f" alt="" width="563"><figcaption></figcaption></figure></div>

#### Take-Profit

Defines an equity threshold that will pause the bot when reached.

**How it works:**

* The bot tracks the starting equity of your subaccount from the moment the strategy is activated.
* If equity rises X% above the starting equity, the bot pauses automatically.

**Example:** Starting equity was $1,000. With a 20% take-profit setting, the bot pauses when equity reaches $1,200.

<div align="left"><figure><img src="https://1790800155-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3kiM6CAFBZoTCJcZ8X7k%2Fuploads%2FhpAeFTdpNjjcBeoud0S8%2Fimage.png?alt=media&#x26;token=fa473f45-6a16-42c4-b3ea-ce55d53ac75b" alt="" width="563"><figcaption></figcaption></figure></div>

***

#### Auto-Close Positions

When setting up take-profit or stop-loss, you can choose whether to **automatically close all positions** when either threshold is triggered.

<div align="left"><figure><img src="https://1790800155-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3kiM6CAFBZoTCJcZ8X7k%2Fuploads%2FpZx61AWQiIPRf6fWBt1P%2Fimage.png?alt=media&#x26;token=5a0b7faa-d303-40fe-b8dc-798157ee6b25" alt="" width="563"><figcaption></figcaption></figure></div>

***

### Bot Management

#### Understanding Bot ON/OFF States

The ON/OFF toggle controls whether the bot is actively managing trades for the entire subaccount.

| State | What Happens                                                                                                                                                                    |
| ----- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| ON    | <p>The bot actively executes trades according to your grid configurations.<br><strong>Important:</strong> You cannot manually trade in this subaccount while the bot is ON.</p> |
| OFF   | The bot stops executing new orders. Existing pending orders remain but can be cancelled manually. You can trade manually in the subaccount.                                     |

<div align="left"><figure><img src="https://1790800155-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3kiM6CAFBZoTCJcZ8X7k%2Fuploads%2FXTZYLDLYBuEcMaxaUfRJ%2Fimage.png?alt=media&#x26;token=e4ae3c83-413c-4c76-bcdb-90678f117310" alt="" width="563"><figcaption></figcaption></figure></div>

> ⚠️ **Key Point:** If the bot is ON but you have no active grids, no trading will occur. The bot needs at least one grid to execute trades.

> ⚠️ **Manual Trading Restriction:** You cannot manually place orders in a bot subaccount while the bot is ON. Turn the bot OFF first if you need to intervene manually.

***

#### Adjusting Grid Settings

To modify an active grid:

1. Go to the **Grids** tab.
2. Select **Edit**.
3. Adjust parameters such as:
   * Expanding or narrowing the price range
   * Pausing or restarting the grid

<div align="left"><figure><img src="https://1790800155-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3kiM6CAFBZoTCJcZ8X7k%2Fuploads%2FcO0zXpgSbuc7FG4zu5X0%2Fimage.png?alt=media&#x26;token=183be48b-7b73-4dd8-a1af-e5a153fc392a" alt="" width="563"><figcaption></figcaption></figure></div>

***

#### Deleting a Grid

1. Go to the **Grids** tab.
2. Select **Delete**.
3. Choose whether to close all remaining positions automatically.&#x20;

<div align="left"><figure><img src="https://1790800155-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F3kiM6CAFBZoTCJcZ8X7k%2Fuploads%2Fn8Oyrb3C4EyyTzLWJpIZ%2Fimage.png?alt=media&#x26;token=86a28add-adf3-45e4-8ad5-71e87bc26c33" alt="" width="563"><figcaption></figcaption></figure></div>
