GoldTradingBot places configurable buy and sell stop orders around the current price with fixed grid spacing and levels when the optional EMA trend filter approves. Lot sizing uses a base lot, custom array, or multiplier. It enters positions via pending orders and exits with per-trade stop loss and take profit (defaults to zero), basket take profit, basket stop loss, basket trailing, and breakeven protection. Risk controls include daily profit and loss limits with close-on-loss option, maximum open trades and pending orders, spread and slippage filters, ATR and ADX volatility filters, and rollover avoidance. Platform is MetaTrader 5. Notable limits include no martingale scaling and conservative lot progression.
Read from GoldTradingBot.mq5. Defaults are the author's; change them in the EA's Inputs tab.
Name
Type
Default
Description
InpSymbol
string
XAUUSD
InpMagicNumber
ulong
260531
InpBaseLot
double
0.01
InpLotStepMode
LotStepMode
CustomArray
InpCustomLots
string
0.01,0.03,0.05,0.07,0.10
InpMultiplier
double
1.4
InpGridSpacingDollars
double
2.0
InpGridLevels
int
5
InpPendingOrderExpiryMinutes
int
0
InpDeleteOppositePendingsAfterTrigger
bool
true
InpMaxSpreadPoints
int
80
InpSlippagePoints
int
30
Show all 40 inputs
Name
Type
Default
Description
InpStopLossDollars
double
0.0
InpTakeProfitDollars
double
0.0
InpUseBasketTP
bool
true
InpBasketProfitMoney
double
25.0
InpUseBasketSL
bool
true
InpBasketLossMoney
double
50.0
InpUseBasketTrailing
bool
true
InpBasketTrailStartMoney
double
15.0
InpBasketTrailDistanceMoney
double
8.0
InpUseTrailingStop
bool
true
InpTrailingStartDollars
double
3.0
InpTrailingDistanceDollars
double
2.0
InpUseBreakEven
bool
true
InpBreakEvenStartDollars
double
2.0
InpBreakEvenLockDollars
double
0.2
InpMaxOpenTrades
int
10
InpMaxPendingOrders
int
10
InpMaxDailyLossMoney
double
100.0
InpMaxDailyProfitMoney
double
100.0
InpCloseTradesOnDailyLoss
bool
true
InpTradingStartHour
int
0
InpTradingEndHour
int
24
InpAvoidRollover
bool
true
InpRolloverStartHour
int
23
InpRolloverEndHour
int
1
InpFridayCloseHour
int
20
InpAllowNewGridAfterBasketClose
bool
true
InpUseTrendFilter
bool
true
How to Install It
1Download the sourceUse "Download source (.zip)" above, or clone ujamal63-create/gold-trading-bot from GitHub, and unzip it.
2Open the data folderIn MetaTrader choose File, then Open Data Folder, and go to MQL5/Experts.
3Copy the filesCopy the .mq5 file into Experts.
4Compile in MetaEditorOpen the file in MetaEditor and press Compile. Fix any missing includes the compiler reports.
5Test before you tradeRun it in the Strategy Tester, then attach it to a demo chart and allow algorithmic trading.
Third-party code. ForexR did not write, test or endorse this EA, and the summary above was generated automatically from its README and code. ForexR lists only repositories with readable source code and never hosts files. Read the code, backtest it and use a demo account first; automated trading can lose money quickly.
This MetaTrader 5 expert advisor is designed for gold trading, utilizing a multi-timeframe strategy across the M15, H1, and H4 charts. It integrates technical indicators including ADX, RSI, and Moving Averages to identify trend-following and breakout opportunities. Risk controls include dynamic lot sizing based on acco
Grafik Tabranij is a multi-strategy Expert Advisor for MetaTrader 5 and MetaTrader 4 designed for automated trading. It features five distinct operational modes: breakout, grid averaging, zigzag bounce, signal-based entry, and an A* pathfinding algorithm for optimal price levels. The EA utilizes martingale lot-size sca
This MetaTrader 5 expert advisor is designed for aggressive trading on XAUUSD, focusing on the 5-minute and 15-minute timeframes. It utilizes Fibonacci retracements and swing high/low breakouts to identify entries across three selectable modes: scalp, swing, and trend following. The system manages up to three positions
Prem Gold Advisor is an automated MetaTrader 5 expert advisor specialized for XAUUSD (Gold) trading on the five-minute timeframe. It initiates trades using breakout levels placed at specific distances from the candle open. The strategy features a progressive scale-in mechanism, adding new orders as the price hits succe
Bakome Bitcoin EA is a trend-following robot optimized for trading BTCUSD on the MetaTrader 5 platform. It generates trade signals using an exponential moving average crossover combined with price breakouts on the H1 timeframe. The system features a grid recovery module that adds positions with a lot multiplier when tr
Straddle Grid is an automated trading robot for MetaTrader 5 that deploys bidirectional stop-order grids based on fixed price distances. The expert advisor utilizes a gates system to filter entries by ATR volatility, spread limits, and specific GMT trading sessions. It manages positions as a basket with currency-based