Skip to main content

StepGridHybrid Spot Trading Strategy

This strategy borrows grid logic from the StepGrid strategy and combines it with a trend monitor that evaluates the market on 15m, 1h, and 4h timeframes.

Info

Grid trading places orders above and below a set price, creating a grid of incrementally higher and lower prices. Trend monitoring analyzes market data across multiple timeframes to identify price direction.

Besides offering many customization options, StepGridHybrid has:

  • Trading modes that control when to start and stop trading a pair.
  • The ability to track how much unsold buy volume remains below the current price.
  • Automatic grid step skipping, for example when price drops out of a recently traded range.
  • Additional orders based on trend triggers alongside grid orders.
  • Compatibility with manual trades on the same pair.

Trading Behavior

In its pure form, StepGridHybrid is like StepGrid with one difference: sell amounts are based on remaining buy volume below the current price. This makes it possible to skip buy steps; when trading resumes at a lower level, it will not sell units bought at higher rates unless overall break-even is reached.

The integrated trend module can:

  • Control when new trades are allowed.
  • Place extra buy orders during a pump.
  • Skip buy steps when price action is negative.
  • Increase sell targets and trailing ranges when price action is positive.

When you run stepgridhybrid, this is the kind of trading behavior to expect:

StepGridHybrid trading behavior

Let's break down what happens:

  • Most trades follow the same logic as the StepGrid strategy.
  • Sell amounts are not static; each sell order sells the remaining volume bought at lower prices times the Partial Sell Ratio.
  • When price moves down rapidly, some buy steps are skipped to preserve funds for later buys.
  • When in no position, the bot buys again when either the next buy or sell step is reached, as long as the trading mode allows new trades.

Skipping Steps

Example of skipping buy steps

The marked zones are intentionally skipped buy steps. Some triggers are configurable; others are hardcoded.

Non-Grid Orders

Example of non-grid orders

The marked zones are additional buy orders triggered by trend module conditions. These orders do not move the active grid targets.

Trading Modes

Trading modes define when to start and stop grid trading. By default, the strategy is unrestricted and can open new trades anytime.

Using a mode restricts opening new trades based on its entry and exit criteria. Once all assets are sold, a new trade can only open when the mode allows it.

Modes are meant to be used one at a time; enabling multiple modes on one pair can lead to unexpected behavior.

info

Trading modes can be extremely restrictive. Sometimes there can be several weeks or more between two entry signals on the same pair.

Manual Trading Range Mode

Manually set a price range in which new trades are allowed. Optionally, use a stop limit price.

TA Mode

Starts trading when the entry conditions for one of a collection of TA fractals is detected; stops opening new trades when exit scenarios are detected. Think of fractals as bullish reversal pattern detection.

This mode includes an optional stop-loss trigger.

Volatility Mode

Looks for pairs in an uptrend on the 4h timeframe and in the lower area of a volatility zone. Allows trading from near the bottom to the top of an expected volatility range.

This mode includes a stop-in-profit mechanism near the top of the zone and an optional stop-loss trigger.

Pullback Mode

When a pullback scenario is detected on the 4h timeframe, new trades are allowed until 15 minutes after the scenario loses validity.

This mode automatically increases the invested amount for the first few trades.

StepGridHybrid Settings

Balance Settings

LabelConfig ParameterDefault ValueDetailed Description
Trading limitTRADING_LIMIT80Base amount per buy order is 80 USDT. With multipliers, orders can range from 20 to 160 USDT.
Trading limit multiplierTL_MULTIPLIER1Scales the invested amount per buy. Example with 100 USDT: 1.0 keeps 100; 1.5 yields 100, 150, 225; 2 yields 100, 200, 400.
Auto TL ratioUSE_TLRfalseDynamically adjusts buy amount based on price, between 0.25x and 1x trading limit.
Auto Partial sell ratioUSE_PSRfalseAdjusts partial sell ratio based on price. Lower prices use a higher ratio; higher prices use a lower ratio.
Partial sell ratioPARTIAL_SELL_RATIO0.95Percentage of previously bought volume that can be sold at each sell step. Example: 200 units * 0.4 = 80 units sold.
Use partial sell capPARTIAL_SELL_CAPfalseLimits the maximum quantity of a partial sell order.
Partial sell cap ratioPARTIAL_SELL_CAP_RATIO1Maximum partial sell size as a multiple of Trading Limit.
Max buy countMAX_BUY_COUNT40Caps total position size at 40x trading limit; when reached, only sells are placed.
Min volume to sellMIN_VOLUME_TO_SELL10Minimum order value that can be sold; verify with your exchange minimums.
Max invested baseMAX_INVESTMENT999999999999999Cap on total base currency invested. Example: 1000 USDT in USDT-BTC.
tip

Dynamic Invest Per Order

Invest per buy order is not static.

The Trading Limit is the base amount for several multipliers; deviations between 0.3x and 2x Trading Limit are possible.

Customize Grid

LabelConfig ParameterDefault ValueDetailed Description
PeriodPERIOD15Candle period used for auto-calculating step size and trailing range. Lower values increase trading frequency and risk; 1h and 4h are also used for trend analysis.
Auto Step SizeAUTO_STEP_SIZEtrueAutomatically selects a grid step size based on current volatility.
Minimum Step PctMIN_STEP_PCT0Minimum percentage step size, overriding auto steps smaller than this value.
Step SizeSTEP_SIZE500Manual grid step size for buys and sells when auto step size is disabled. Can be a fiat value or a percentage when Pct Step Size is enabled.
Pct Step SizePCT_STEP_SIZEfalseInterprets Step Size as a percentage of the current price.
Enforce Step SizeENFORCE_STEPfalseOnly executes orders if the price aligns with the grid step size.
Unit Costunit_costtrueBreak-even calculation: enabled uses average cost per unit remaining; disabled uses full-sequence break-even.
Dynamic Exit LogicDYNAMIC_EXIT_LOGICfalseIn uptrends, exit target is Unit Cost; otherwise uses overall break-even. Requires Unit Cost disabled.
Partial Sell GainGAIN_PARTIAL0.5Minimum profit target (%) for partial sells, requiring buys at least 0.5% below current price after fees.
GainGAIN1Minimum profit target (%) above break-even or Unit Cost before a full sell.

Customize Trailing

LabelConfig ParameterDefault ValueDetailed Description
Pct Buy Trailing RangePCT_TRAILING_RANGEfalseUses a custom percentage to define buy trailing range instead of the automatic range.
Custom Buy Trailing RangeCUSTOM_TRAILING_RANGE0.3Buy trailing range (%) when Pct Buy Trailing Range is enabled.
Pct Sell Trailing RangePCT_SELL_TRAILING_RANGEfalseUses a custom percentage to define sell trailing range.
Custom Sell Trailing RangeCUSTOM_SELL_TRAILING_RANGE0.3Sell trailing range (%) when Pct Sell Trailing Range is enabled.

Trend Options

LabelConfig ParameterDefault ValueDetailed Description
Trend SyncTREND_SYNCfalseRestricts new trades to periods when 4h and 1h trends align; does not affect DCA trades.
Trend BasicTREND_BASICtrueAdjusts behavior based on market conditions, such as increasing sell steps and trailing ranges, and allowing immediate buys during strong uptrends.
Trend PlusTREND_PLUStrueEnhances dynamic trading by enabling immediate buys during short-term opportunities and increasing partial sell ratios after those buys.
Trend OrdersTREND_ORDERStrueControls whether Trend Basic and Trend Plus initiated orders are allowed.
Auto Trend OrdersAUTO_TREND_ORDERStrueOnly allows trend-initiated orders during a 4h uptrend.
Trailing Range MultiplierTRAILING_MULTIPLIER2Multiplier applied to trailing range when Trend Basic or Trend Plus calls for a larger range. Also affects custom PCT ranges.
Sell Step MultiplierSELL_STEP_MULTIPLIER1.2Increases sell step size in trend-identified conditions.
Trend TrailingTREND_TRAILINGtrueAdjusts buy trailing ranges in bearish conditions to avoid premature buys.
Trend Trailing Multiplier (Small)TREND_TRAILING_MULTIPLIER1Buy trailing multiplier when 4h trend is bullish but 15m trend is bearish.
Trend Trailing Multiplier (Big)TREND_TRAILING_BEARISH_MULTIPLIER2Buy trailing multiplier when both 4h and 15m trends are bearish.

Trading Modes

LabelConfig ParameterDefault ValueDetailed Description
Custom Trading RangeCUSTOM_TRADING_RANGE_MODEfalseOnly opens new trades within a defined price range. DCA can occur at any price, but if price falls below 7000 USDT, all holdings are sold.
Trading Range LowTRADING_RANGE_LOW8000Lower limit of the custom trading range.
Trading Range HighTRADING_RANGE_HIGH10000Upper limit of the custom trading range.
Trading Range StopTRADING_RANGE_STOP7000Stop-loss target; if the opening rate of the latest candle falls below this level, all holdings are sold.
Trading Range DCA StopTRADING_RANGE_DCA_STOP7500Lower limit for placing DCA orders within the custom range.
Pullback ModePULLBACK_MODEfalseRestricts new trades to times when a pullback occurs, primarily on 4h charts.
Volatility ModeVOLATILITY_MODEfalseLimits trading to bullish pairs within a controlled volatility range, with a stop mechanism to limit losses on the final sell.
TA ModeTA_MODEfalseRestricts trading to bullish pairs that meet specific TA fractals.
Dynamic Stop LossDYNAMIC_SLfalseDynamic stop loss target when used with Volatility or TA mode; hidden until triggered.

Advanced

LabelConfig ParameterDefault ValueDetailed Description
Stop After Next SellSTOP_AFTER_SELLfalseStops trading after current holdings are fully sold.
Forever BagsFOREVER_BAGSfalseIgnores break-even price to hold for longer-term gains.
Buy EnabledBUY_ENABLEDtrueControls whether buy orders can be placed.
Sell EnabledSELL_ENABLEDtrueControls whether sell orders can be placed.
SMA PeriodSMAPERIOD50Number of candles used to calculate support/resistance for trailing ranges.
ATR PeriodATR_PERIOD50Number of candles used to calculate ATR for Auto Step Size.
Keep QuoteKEEP_QUOTE0Amount of quote currency to keep and not sell (e.g., 0.01 BTC).
Ignore Trades BeforeIGNORE_TRADES_BEFORE0Unix timestamp before which trades are ignored for strategy resets.
tip

Other Parameters

Besides settings mentioned on this page, no other strategy setting has any effect on StepGridHybrid.