EA Settings & Configuration

What Happens When XAUUSD Gaps With Your EA Open?

Weekend gaps are one of the most overlooked risks in gold EA trading — and one of the easiest to prevent.

Weekend gap timeline

Friday

22:00

Market closes

Saturday

00:00

Fully closed

Sunday

23:59

Weekend events

Monday

00:05

Gap opens here

Scenario 1Worst case

Open position — gap down 40 pips

Loss worse than SL

Click to see full breakdown →

Scenario 2Lucky case

Open position — gap up 40 pips

Lucky win (TP triggered)

Click to see full breakdown →

Scenario 3Neutral

No position held over weekend

No impact

Click to see full breakdown →

Scenario 4Protected

EA with weekend filter enabled

Auto-closed Friday 21:55 — Safe

Click to see full breakdown →

Historical XAUUSD weekend gap magnitudes (approximate worst gaps per year)

2020
180 pips
2021
95 pips
2022
210 pips
2023
140 pips
2024
165 pips

What Is a Market Gap — and Why Does Gold Gap More Than Most?

A market gap occurs when the opening price of a trading session differs from the closing price of the previous session. In forex and gold markets, this most commonly happens on Sunday night when the Asian session opens after 48+ hours of market closure over the weekend.

Gold is particularly prone to large gaps for a specific set of reasons. First, it is a safe-haven asset — meaning geopolitical events, central bank announcements, or economic data released during the weekend directly affect its price. When markets are closed, supply and demand pressure builds up over two days and releases all at once on Sunday open. The result is often a significant jump in either direction.

Second, gold is priced in US dollars, which means any significant weekend move in the dollar index (DXY) or in US Treasury yields also translates directly into a gold price move. When both gold-specific news and dollar-specific news combine over a weekend, gaps can be extreme — the 2022 Ukraine crisis and the 2020 COVID volatility period both produced gaps exceeding 150 pips in a single Sunday open.

This volatility profile is part of why understanding XAUUSD's volatility characteristics is essential before deploying any automated strategy. The instrument that makes gold so profitable for scalping is the same characteristic that makes weekend gap risk especially pronounced.

How Stop Losses Fail During a Gap

This is the most dangerous misconception in EA trading: that stop losses always fill at their exact level. In continuous markets, this is mostly true — the price trades through your SL level and your order gets filled at or very close to it. During a gap, the market skips your SL level entirely.

Here is how it plays out mechanically. Your gold long position has a stop loss at $2,310. Gold closes at $2,340 on Friday. Over the weekend, a geopolitical event causes gold selling. Sunday open: $2,285. Your stop loss at $2,310 is never touched because price never traded there — it jumped from $2,340 to $2,285 without any fills in between. Your broker fills your SL at the first available price after the gap: $2,285. Your actual loss is 55 pips instead of the 30 you planned for.

This is called negative slippage on a stop loss, and it can be severe. On a 1.0 lot position, the difference between a 30-pip planned loss and a 55-pip actual loss is $250 of unplanned drawdown. On multiple positions or larger lot sizes, a single weekend gap can produce account damage far beyond what your risk model anticipated.

Guaranteed stop losses (available at some brokers at a premium spread cost) are the only product that prevents this. Standard stop losses — the default on most MT5 accounts — do not guarantee fill at the specified price during gap conditions. This connects directly to execution latency discussion — during gaps, even zero-latency VPS connections cannot help because there are simply no fills between the close and open prices.

The Four Gap Scenarios Your EA Can Face

The four scenarios shown above in the hero section cover the complete universe of possible outcomes when gold gaps with an active EA position. Understanding each one helps you configure correctly.

Gap against your position (worst case)

You hold a long, gold gaps down. Or you hold a short, gold gaps up. This is the scenario that matters most. Your SL is bypassed, your loss is larger than planned, and your margin may take a significant hit. The only complete protection is not holding positions over the weekend.

Gap in your favour (lucky case)

Gold gaps in the direction of your trade. Your take profit is bypassed but in a beneficial way — you get filled at a better price than your TP. This feels like free money but it teaches the wrong lesson: gap risk is still gap risk. The same weekend that could gap 40 pips in your favour could equally have gapped 40 pips against you.

No position held (neutral case)

If your EA has no open positions when the gap occurs, you are completely unaffected. The gap simply means you may see a spike on the chart on Monday morning, but your account is flat and you resume normal trading after the market stabilises.

Gap filter enabled (protected case)

The EA's Friday close filter closed all positions automatically at 21:55 Friday. The EA was flat over the weekend. It sees the gap on Monday morning, waits for price to stabilise, and begins trading again in its normal window. This is the only consistently safe outcome.

How Pro-Scalper EAs Handle Gap Risk

All Pro-Scalper EAs are built with explicit weekend gap protection. The Friday close filter is a configurable parameter — you can set the exact server time at which the EA stops opening new positions and closes any existing ones. The default is typically 21:00–21:55 server time on Friday, well before the 22:00 market close.

Beyond the Friday filter, our EAs also include a Monday gap sensitivity setting. When gold opens on Monday with a significant gap from Friday's close (configurable threshold, typically 30+ pips), the EA enters a cooldown period rather than immediately trading on the momentum. This is important because gap openings are frequently followed by partial retracements as the market finds equilibrium — entering immediately on a gap spike often means entering into a reversal rather than a sustained move.

This approach contrasts sharply with how some lower-quality EAs handle weekends — either ignoring the risk entirely (holding positions with no filter) or trading the gap itself (entering positions immediately based on gap direction). Both are dangerous strategies for accounts that cannot absorb a 150+ pip adverse gap move.

If you are evaluating a new EA and wondering about its gap handling, check the settings panel for a "Friday close time" or "weekend filter" parameter. Its absence is a red flag. The overall question of pre-launch configuration is covered in our complete pre-launch checklist.

What Causes XAUUSD Weekend Gaps? The Full Anatomy

Understanding what drives gold gaps helps you assess risk before going into any given weekend with open positions. Not all weekends are equal — some carry almost zero gap risk, others carry extreme risk.

Geopolitical Events

Risk: Very High
  • Military conflicts escalating
  • Sanctions announced on major economies
  • Leadership changes in key oil-producing nations
  • Nuclear or weapons programme developments

US Dollar & Fed News

Risk: High
  • Emergency Fed announcements
  • Unexpected inflation data on Friday
  • Treasury yield spike or collapse
  • Dollar index extreme moves

Banking & Financial System

Risk: High
  • Bank collapses announced on weekend
  • IMF emergency meetings
  • Currency peg breaks
  • Sovereign debt downgrades

Normal Weekend

Risk: Low
  • No major events
  • Quiet geopolitical environment
  • Markets closed normally Friday
  • Asian session opens flat

A practical habit: every Friday before market close, spend 5 minutes checking major financial news sources for anything that could move markets over the weekend. If there is elevated geopolitical risk, reduce your Friday lot sizes and ensure the gap filter is active regardless of whether you normally use it.

Gap Risk vs Recovery Mode: An Important Distinction

Some EA users try to address gap losses by enabling recovery mode — a setting that opens additional trades to average down after a losing position. This is the wrong solution to a gap problem. Recovery mode is designed to handle intraday drawdown from normal market volatility, not a one-time 100-pip gap that fundamentally changed market conditions overnight.

After a major gap, the market has repositioned. Averaging down into a gapped position means you are adding exposure into an environment where price has already made a substantial directional move driven by fundamental information that did not exist when the original trade was placed. This is not the same as averaging into a temporary spike during a normally volatile session.

The complete discussion of when recovery mode helps and when it hurts covers this in detail. The short answer: gap losses should be accepted at their actual size and recovered through continued profitable trading, not through adding to a gapped position.

The Monday Cooldown: What Good EAs Do After a Gap

Even when an EA closes all positions correctly on Friday, the Monday open after a gap still requires careful handling. A 40-pip gap up on Sunday open does not mean gold will continue higher on Monday — in fact, gap reversals are common as the market digests the weekend news and finds equilibrium.

A well-designed EA handles this by implementing a gap detection on Monday open. If the opening price is more than a threshold (configurable, typically 20–30 pips) away from Friday's close, the EA enters a 30–60 minute observation period before resuming normal signal generation. This prevents chasing a gap that is about to reverse.

Additionally, spread widening immediately after the Monday open is common — especially in the first 5–15 minutes after Asian session start. Spreads on XAUUSD that are typically 1–2 pips during peak hours can widen to 5–15 pips in the first few minutes after market open. An EA that enters immediately at Sunday open is paying a much higher execution cost than its backtest assumed.

All of this is part of why the ideal EA approach to weekends is: close Friday, observe Monday morning, resume trading once liquidity normalises. Simple in concept, but it requires intentional configuration rather than leaving the EA running with default settings through weekends.

Configuring Your EA for Weekend Safety: Step by Step

1

Step 1: Enable the Friday close filter

Set the EA's Friday close time parameter to 21:00–21:55 server time. This ensures all positions are closed in normal market conditions with tight spreads, at least an hour before final close.

2

Step 2: Set max open time on Fridays

Configure the EA to stop opening new trades from 20:00 server time on Fridays. This prevents new entries that would be held over the weekend.

3

Step 3: Configure Monday start delay

Set a Monday start delay of at least 15–30 minutes from the market open time. This prevents trading during the initial low-liquidity, high-spread period.

4

Step 4: Set Monday gap threshold

If your EA supports it, configure a gap detection threshold. If Monday open is more than 20 pips from Friday close, delay trading by an additional 30–60 minutes.

5

Step 5: Reduce Friday afternoon lot sizes

On any trades that open in the last 2–3 hours of Friday, consider a 50% lot size reduction as an additional safeguard against gap risk on any trades where the filter might not trigger in time.

6

Step 6: Monitor high-risk weekends manually

If significant geopolitical events are developing on a Friday, consider manually closing all positions before the EA's filter triggers. Human judgment on exceptional weekends adds a layer of protection that no parameter setting can replace.

Frequently Asked Questions

Related Articles

Our Expert Advisors for XAUUSD

Goldie Razor V2.8.4

M15 breakout + H4 EMA filter — built for XAUUSD on MT5

View Goldie Razor →