Bollinger Bands EA: no-code builder for MT4 / MT5
ChannelsBollinger Bands are a moving average plus and minus a multiple of the standard deviation. A move back inside from below the lower band reads as a bounce. An open above the upper band signals a strong breakout.
Rules you can build with it
Works as an entry rule or an exit rule. Short rules are mirrored automatically.
- LongCandle opens above Upper Bollinger BandShortCandle opens below Lower Bollinger Band
- LongCandle opens below Lower Bollinger BandShortCandle opens above Upper Bollinger Band
- LongCandle opens below Upper Bollinger BandShortCandle opens above Lower Bollinger Band
- LongCandle opens above Lower Bollinger BandShortCandle opens below Upper Bollinger Band
- LongCandle opens above Lower Bollinger Band after opening below itShortCandle opens below Upper Bollinger Band after opening above it
- LongCandle opens below Upper Bollinger Band after opening above itShortCandle opens above Lower Bollinger Band after opening below it
- LongCandle opens above Middle Bollinger BandShortCandle opens below Middle Bollinger Band
- LongCandle opens below Middle Bollinger BandShortCandle opens above Middle Bollinger Band
Settings
| Settings | Default | Range |
|---|---|---|
| Period | 20 | 5 – 100 |
| Std. dev. multiplier | 2 | 1 – 4 |
| Price | Close | Close / Opening price / High / Low / Median price / Typical price / Weighted close |
How the backtest and the EA calculate it
The middle band is a simple moving average and the standard deviation uses the population formula (divided by N), matching MT5's Bollinger Bands.
Signals use only closed candles and are filled at the next candle's open. The exported EA checks conditions in the same order, so you get similar results in the MT5 Strategy Tester.
Example strategies
- Entry · Bollinger Bands (20, 2, Close): Candle opens above Upper Bollinger Band
- Stop-loss 300 points, take-profit 600 points
- Entry · Bollinger Bands (20, 2, Close): Candle opens above Upper Bollinger Band
- Entry · Moving Average (50, EMA, Close): MA rises
- Stop-loss 300 points, take-profit 600 points
Examples are just a starting point: open one to change settings or add filters, then check it with backtests and robustness tests. Backtest results don't indicate future returns.