Join waitlist
Strategies / Volatility / Nested Bollinger Band Trend Entry

Nested Bollinger Band Trend Entry

The system buys when the close is above the inner upper band around a 100-period SMA and the outer upper band is rising, and sells short on the mirror setup. Longs exit when price falls back below the outer band or crosses the average.

VolatilityLong & shortSwingUSD/JPYDaily
1.47Profit factor
2,541,770Net profit USD
35.97%Win rate
531Trades
-410,800Max drawdown
4,787Avg trade

Best run of 7. USD/JPY, Daily, spread 1, from run pf:2026-10-12-USDJPY-D.tsv:19.

Entry rules, long

  1. The outer upper band, 1.5 standard deviations above the 100-period SMA, is higher than on the prior bar.

Entry rules, short

  1. The outer lower band, 1.5 standard deviations below the 100-period SMA, is lower than on the prior bar.

Exit rules

  1. A long closes when the prior open was above the outer upper band and the close is back below it.
  2. A short closes when the prior open was below the outer lower band and the close is back above it.
  3. A short also closes when the close crosses above the 100-period SMA.

Test conditions

PeriodUp to 2026-10-12
InstrumentUSD/JPY, Daily
Spread1 points
Starting capital1,000,000
CostsSpread only. Commissions and overnight financing are not included.
BarsUp to 200,000 bars, fewer where the instrument has less history
Last tested2026-10-12

Every run

Markets and timeframes tested

MarketTimeframePFTradesWin %NetMax DD
USD/JPYBest runDaily1.47 53135.972,541,770 USD-410,800
EUR/USDDaily1.32 54634.80133,591 USD-32,409
EUR/USD2 minn/a 9,59820.96214,750 USD-164,665
Nikkei 225Dailyn/a 45132.8226,578 USD-24,269
Nasdaq 100Dailyn/a 49636.2910,675 EUR-5,529
GoldDailyn/a 61134.702,276 EUR-1,131
S&P 500Dailyn/a 66433.431,302 EUR-1,277

Charts

Results by run

Above 1.0 made money, below 1.0 lost money.

The code

ProBuilder code, as tested

// ==============================================================
// Nested Bollinger Band Trend Entry
// ProRealAlgos Strategy Library  |  prorealalgos.com
// Type: Volatility
// Direction: Long & short
// Timeframe tested: Daily
// ==============================================================

DEFPARAM CumulateOrders = false

ma = Average[100](close)
sd = STD[100](ma)
inu = ma + sd * 0.25
inb = ma - sd * 0.25
outu = ma + sd * 1.5
outb = ma - sd * 1.5

19 more lines: the entry and exit rules.

Setup

How to load it

  1. Copy the code with the copy button on the code block.
  2. In ProRealTime, open a chart of the instrument and timeframe you want to test, then open ProOrder > New trading system and choose "Create with programming".
  3. Paste the code, give the system a name and save it.
  4. Click "Backtest", set your own spread and position size, and run it before you consider trading it live.

Indicators used

Bollinger BandsSMAStandard Deviation
Read this firstKnown weaknesses2 points
  • The code sets no stop loss, so a losing trade stays open until an exit signal arrives.
  • Results include the spread only. Commissions and overnight financing are not included.

Questions

About this strategy

Can I run Nested Bollinger Band Trend Entry in ProOrder?

Yes. The code is ProBuilder and runs as an automated ProOrder system. Backtest it on your own account with your own spread and position size before trading it live.

Which markets was it tested on?

It was tested on 7 market and timeframe combinations. The best run was USD/JPY, Daily, with a profit factor of 1.47 over 531 trades.

How large was the drawdown?

The best run had a maximum drawdown of 410,800 USD at the tested position size, against a net result of 2,541,770 USD.

Does it trade long, short or both?

It trades both long and short.

Related

Strategies like this one

Trend Surfer

Uses the same indicator.

1.04 PF · 10,813 trades

EMA 8 21 RSI Filtered Bracket

Best run on the same market, USD/JPY.

1.09 PF · 6,194 trades

Squeeze Release Momentum Breakout

Also a volatility strategy.

1.45 PF · 619 trades

Put your name on the ProRealAlgos waitlist to trade a tested portfolio instead of single strategies.

The ProRealAlgos community gets the full rules, the complete code and the automated portfolio.

Past backtest results do not guarantee future results. This is not financial advice. Curated and maintained by ProRealAlgos. ProRealTime™ is a trademark of ProRealTime SAS. prorealalgos.comStatsDocs