ゴールド

Gold Scalping EA Setup Guide and Verification Checklist: Spread, Trading Hours, and Lot Management

2026-09-08  / Ya

Gold (XAU/USD) scalping EAs are automated trading systems designed to capture small, frequent profits dozens of times per day by exploiting high volatility. However, incorrect configuration can lead to consecutive stop-outs caused by spread widening and sudden price swings around news releases. This article organizes the parameters you must review before deploying an EA, including their meanings, reference values, and the loss patterns that misconfiguration can trigger, backed by data.

What Is a Scalping EA, and Why Is It Used on Gold?

A scalping EA is a high-frequency trading program that closes positions within an extremely short window of seconds to minutes. There are three main reasons why scalping on Gold attracts attention.

① High volatility: The average daily range of XAU/USD was roughly 15 to 25 dollars (equivalent to 1,500 to 2,500 points) during 2023-2024. That dwarfs the typical intraday range of EUR/USD (60 to 100 pips), making Gold’s price swings especially pronounced.

② Concentrated liquidity windows: During London to New York hours (GMT 8:00-20:00), institutional participation increases and spreads tend to narrow relatively. This is why many EAs restrict their activity to this window.

③ Spread variability: Conversely, spreads can widen to 3 to 10 pips just before and after news releases and during the early Tokyo session. Because spread constitutes the bulk of cost in scalping, entering during these widening periods significantly drags down expected value.

EA logic generally falls into two categories: mean-reversion (range counter-trend) and breakout (momentum-following). The risk-reward profile of either type changes depending on how parameters are combined, so the logic type alone cannot determine superiority. For guidance on selecting evaluation metrics, refer to Verification Metrics for Evaluating Gold EAs.

Key Parameters: Meanings, Reference Values, and Expected-Value Calculations

The table below summarizes representative settings. Reference values are general guidelines only; individual verification through backtesting and forward testing is required.

Parameter Meaning Reference Value Notes
MaxSpread Maximum spread at which entries are permitted 30-50 points (3-5 pips) Without a skip rule when this threshold is exceeded, cost overruns are common
LotSize / RiskPercent Lot size per trade or risk percentage relative to account balance Up to 1-2% of balance as a guideline With fixed lots, calculate and confirm the balance ratio separately
TakeProfit (TP) Profit target in pips 5-15 pips If the target cannot be set at least 3x the spread, net profit tends to go negative
StopLoss (SL) Stop-loss distance in pips 10-20 pips Designs without an SL make maximum drawdown difficult to measure
TradeHours Active trading window (server time) GMT 8:00-20:00 (London to NY) Always confirm the offset between broker server time and your local time zone
NewsFilter Trading pause around major news releases Pause 30-60 minutes before and after EAs without a built-in filter should consider using an external calendar filter

Simple Expected-Value Formula

Expected Value (pips) = (Win Rate x TP) – (Loss Rate x SL) – Spread

Example: Win rate 55%, TP = 10 pips, SL = 15 pips, Spread = 3 pips

Expected Value = (0.55 x 10) – (0.45 x 15) – 3 = 5.5 – 6.75 – 3 = -4.25 pips

Even a seemingly solid 55% win rate produces a negative net expected value. It is not unusual for a backtest Profit Factor (PF) above 1.2 to fall below 1.0 once spread is recalculated using realistic variable values. For a proper reading of PF, see Profit Factor Benchmarks and Why Overconfidence Is Dangerous.

A short backtest period also means insufficient samples of different market regimes. Because Gold’s volatility characteristics differed significantly between the 2022 rate-hike cycle and the 2024 all-time-high breakout phase, testing with at least 3 to 5 years of data is recommended.

Common Pitfalls for Beginners

  • Not setting a spread filter: Gold spreads widen to 1-2 pips under normal conditions and can exceed 10 pips during news releases, depending on the broker. An EA without MaxSpread configured will keep entering even when costs multiply, producing losses despite a high win rate. ECN accounts at brokers like HFM display a raw spread, but calculations must use the all-in effective cost including commission.
  • Running backtests with a fixed spread: MetaTrader 4/5 defaults to fixed-spread calculations. Results are overly optimistic because variable spread behavior is not reflected, leading to a large gap with live account performance. Backtests using variable spread mode and tick data are preferable for accuracy.
  • Using trading hours without converting to server time: Setting an EA to “run during London hours” does not guarantee that outcome, because the Hour parameter inside the EA operates on broker server time (often GMT+2 or GMT+3). Including daylight saving time shifts, confirm the offset from your local time (7 to 9 hours for Japan) before configuring. A conversion error will leave the EA running continuously at hours far from what you intended.
  • Lot size is too large relative to account balance: In scalping, individual losses are small but trades accumulate rapidly over a short period. When risk per trade exceeds 5% of account balance, ten consecutive losses wipe out more than 40% of capital. Martingale-style EAs tend to produce even deeper drawdowns, which warrants extra caution (see The Mechanism Behind Deep Drawdowns in Martingale EAs).
  • Ignoring news filters around major releases: During events such as US CPI or FOMC announcements, Gold can move 50 to 100 pips or more in an instant. Scalping EAs are not designed to handle such rapid moves, and slippage beyond the SL level is a real risk. A news filter should be treated not as an optional extra but as an essential component of risk management.
  • Missing signs of over-optimization (overfitting): Fine-tuning parameters to fit a specific historical period improves backtest results but degrades generalization to future data. Do not skip the step of setting aside a separate out-of-sample period for validation.

FX AI Lab Commentary

Our lab is developing and testing autonomous EAs targeting Gold (currently in the verification stage). Based on our testing so far, we have concluded that spread threshold, trading hours, and lot management are the three most critical parameters driving profitability in a scalping strategy. Rather than locking parameters in for long-term operation, periodic re-verification in response to changing market conditions is a realistic approach. We will publish verification progress progressively alongside HFM demo account logs. For questions about configuration or the verification process, please use the contact form. If you do not yet have an HFM demo account, see How to Open an HFM Demo Account.

Related Links

This article is provided for informational purposes only and does not constitute a solicitation to purchase or use any specific EA or financial product. FX trading involves the risk of loss, including loss of principal. Please review the Risk Disclosure page for details.