Skip to main content

Gridbots Spot Trading Strategy

The Gridbot strategy in Gunbot automates trading through a grid of limit buy and sell orders within a defined price range.

Gridbots in action

Key Configuration Settings

The Gridbot strategy offers several configuration options to tailor the trading approach:

  1. Invest per Buy Order: Controls the investment amount for each buy order within the grid. Adjust to match your risk and exposure preferences.

  2. Max Orders per Side: Sets the maximum number of open orders on each side. For example, 5 allows up to 5 buy and 5 sell orders simultaneously, helping manage risk.

  3. Rebalance: When enabled, the bot buys assets equal to max orders times invest per order if it lacks assets to sell. This provides inventory to keep the grid active.

  4. Steps % for Gridbots: Sets the percentage interval for the grid. If disabled, the grid size is based on ATR (Average True Range) so it adapts to volatility.

Gridbots settings

Behavioral Overview of the Gridbot Strategy

Initialization

At startup, Gridbot checks balances. If rebalance is enabled and asset balance is low, it makes a market purchase to ensure enough assets for the desired number of sell grids.

Interval Calculation

Intervals are calculated using a user-specified percentage or ATR-based volatility. This lets you choose manual control or automatic adjustment to market conditions.

Price Range Filtering

Gridbot identifies lower and higher price points around the current bid to define grid boundaries, keeping the grid aligned with current price action.

Interval Adjustment

When price moves significantly, Gridbot recalculates intervals to maintain an effective grid and avoid gaps.

Chart Target Management

The strategy shows bid and ask prices on custom chart targets, making it easier to track the grid in real time.

Order Execution and Management

Gridbot places and manages buy and sell orders according to the grid. When a buy fills, the corresponding sell order is placed automatically, keeping the grid active.

Advanced Features for Gridbot Users

Auto Step Size Adjustment

Gridbot can adjust grid step size automatically based on market conditions, helping the grid remain effective in high volatility or low liquidity.

Partial Sell and Profit Taking

Partial sell orders allow profits to be taken gradually as the market moves in your favor, reducing exposure to sudden reversals.

Risk Management Tools

Gridbot includes risk management options such as stop-loss and trailing stop features to limit potential losses and lock in gains.

Gridbot settings

LabelConfig ParameterDefault ValueDetailed Description
Invest per buy orderTRADING_LIMIT20Base amount to invest per buy order. Example: 10 in USDT-BTC spends 10 USDT per buy.
Max invested baseMAX_INVESTMENT999999999999999Cap on total base currency invested. Example: 1000 in USDT-BTC caps investment at 1000 USDT.
Funds reserveFUNDS_RESERVE0Amount of base currency reserved and not traded. No new buys once available funds drop below this value.
Use rebalanceUSE_REBALANCEfalseWhen enabled, buys assets equal to max orders times invest per order if balance is insufficient. If disabled, trades only with available balance.
Steps %gbIntervalautoPercentage interval for grid steps. Example: 1.2% sets grids every 1.2%. Auto uses ATR.
Max grid ordersMAX_GRID_ORDERS5Maximum number of open orders per side. Example: 5 allows up to 5 buy and 5 sell orders.
Stop lossSTOP_LIMIT99999Defines when to take losses. Example: 10 sells assets if value drops 10% below break-even.
PeriodPERIOD15Candles used to display the chart and calculate ATR (e.g., 15 minutes, 1 hour).