Gold Swingline
- Uzmanlar
- Sürüm: 1.8
- Etkinleştirmeler: 5
Gold Swingline is a MetaTrader 5 Expert Advisor that automates gold breakout entries. It uses confirmed swing highs and lows on H1, H4 and D1, along with the previous day and week highs and lows, to identify entry levels on XAUUSD.
How the strategy trades
The EA checks its active strategies on a broker-time schedule and places buy-stop or sell-stop orders near eligible levels. Entry buffers adjust to recent daily volatility. When a level changes materially, the EA can cancel and replace its pending order. It also limits the number of nearby orders and positions in the same direction.
Each pending entry includes a stop loss and take profit. After a fill, an optional trailing stop can move the protective stop as price moves in favor of the trade. The optional adverse-candle exit can close a position if its entry candle closes against the trade before the stop has moved.
Position sizing and key inputs
- Fixed lot starts at 0.01 lot per order. Use InpFixedLot to set the volume and keep InpRiskPct at zero for fixed sizing.
- Percentage sizing uses InpRiskPct to estimate the volume that would lose the chosen percentage of account balance at the stop. The EA applies InpMaxLot, rounds down to the broker's volume increment and skips orders below the broker minimum. Several positions can be open at the same time, and actual losses can exceed the estimate.
- Stop loss and take profit use gold price distances. A stop distance of 2.50 means a 2.50 move in the gold quote. The broker's minimum stop distances and tick size also apply.
- The spread limit pauses new entries when the spread is too wide. Existing positions can still be managed. Switching off Allow new entries cancels the EA's pending orders and continues position management.
- Individual strategies can be enabled or disabled. Optional CSV logging records order and exit activity for review.
Sessions and event windows
Gold Swingline uses the broker's server time for its schedule and can clear pending orders before the last trading session closes. Holiday dates are configurable. The built-in event table ends on November 10, 2026. For years outside 2024–2026, the event filter uses a configurable first-Friday time window.
Getting started
- Use your broker's gold symbol on a MetaTrader 5 hedging account. H1 matches the backtest shown in the gallery.
- Run one instance per symbol and magic number base so that each instance manages its own orders. Confirm the symbol's lot step, spread and session times on your broker.
- Evaluate the setup in the Strategy Tester and on a demo account before enabling live trading. Compare position size, order frequency and drawdown across the settings you intend to use.
About the backtest in the gallery
The gallery shows a historical simulation on Exness demo XAUUSDr, H1, from January 1 to November 25, 2026. The run used the MT5 Every Tick model, a 1,000 USD starting balance and 1:500 simulated leverage, with 3% balance risk targeted at the stop per order and a 50-lot input cap. MT5 reported 99% history quality, 719 trades and 37.27% relative equity drawdown. The simulation illustrates one configuration. Its sizing and leverage can materially affect both returns and losses. Backtest results do not predict future performance.
