The gold xauusd scalping indicator asks three separate readings to agree before it marks anything. Price has to sit on the correct side of a 10 period EMA, a fast RSI has to clear the midline, and MACD‘s main line has to be above or below its signal. Gold moves quickly enough that any one of those alone fires constantly, which is why all three are required.
This build ships as a compiled .ex4 for MT4 and .ex5 for MT5; the screenshots below come from XAUUSD M5.
| Platforms | MT4 (.ex4) + MT5 (.ex5) |
|---|---|
| Chart window | Main price chart |
| Plots | 3: EMA Trend, BUY, SELL |
| Alerts | popup, push notification, email, sound |
| Inputs | 13 |
What the Gold xauusd scalping Indicator draws on the chart
EMA Trend is the gold line, the only plotted average.
BUY places a lime arrow beneath a bar where all three readings point up.
SELL places a red arrow above the bar when all three point down.
RSI and MACD stay internal, so add them separately if you want to watch what the tool is reading.
- EMA Trend: line, gold, width 2
- BUY: arrow, lime, width 2, arrow code 233
- SELL: arrow, red, width 2, arrow code 234

How the Gold xauusd scalping Indicator calculates its values
Three readings taken on the same bar
ema comes from iMA over `EmaPeriod`, rsi from iRSI over `RsiPeriod`, and macdM and macdS from iMACD using `MacdFast`, `MacdSlow` and `MacdSignal`. All four calls use the same bar index, so nothing drifts between them. EmaBuf receives the average, which is the only value that reaches the chart.
Testing state rather than crossing
buy holds when close[i] sits above ema, rsi is above `RsiThreshold`, and macdM sits above macdS. Note these are states, not crossings. A run of bars can all satisfy the condition, so arrows appear in clusters through a sustained move rather than once at the turn.
Why the periods are short
`EmaPeriod` at `10` and `RsiPeriod` at `7` are faster than the usual 20 and 14. MACD keeps its conventional 12, 26 and 9. That mix gives two quick readings that react within a few bars, and one slower one that only agrees during a sustained push, which is what the confluence is meant to catch.
How to read the signals
Arrows come in runs, because the tests describe a state that can persist across bars.
The first arrow of a run is the one that matters, and the rest confirm the condition still holds.
Only the gold EMA line is visible, so a signal can appear while that line alone looks unremarkable.
Silence means at least one of the three disagreed, which happens through most of a normal session.
Alert channels in this build: popup, push notification, email and sound, one message per closed bar.
Four channels sit beneath `EnableAlerts`: popup, push notification, email and sound. Note that `EnableSound` ships `true` here alongside the popup, so you get an audible cue out of the box, with `SoundFile` naming the clip. Push and email start off, and the guard permits one message per closed bar.
Every Gold xauusd scalping Indicator input
Core settings
| Setting | What it does | Default |
|---|---|---|
EmaPeriod |
Trend average length, default `10`, deliberately fast for scalping. | 10 |
RsiPeriod |
Momentum lookback, default `7`, about half the conventional setting. | 7 |
MacdFast |
MACD fast length, default `12`, with `MacdSlow` at `26` and `MacdSignal` at `9`, the standard trio. | 12 |
MacdSlow |
(see inputs panel) | 26 |
MacdSignal |
(see inputs panel) | 9 |
RsiThreshold |
The midline RSI must clear, default `50.0`. Raise it to 55 for a stricter momentum test. | 50.0 |
Display settings
| Setting | What it does | Default |
|---|---|---|
ArrowOffsetPt |
Distance between candle and arrow, default `12.0` points. | 12.0 |
Alert settings
| Setting | What it does | Default |
|---|---|---|
EnableAlerts |
(see inputs panel) | on |
EnablePopup |
(see inputs panel) | on |
EnablePushNotify |
(see inputs panel) | off |
EnableEmail |
(see inputs panel) | off |
EnableSound |
(see inputs panel) | on |
SoundFile |
(see inputs panel) | alert.wav |

Settings that fit your chart
The screenshot note names XAUUSD on M5, which is what these fast periods are tuned for. Gold on a five minute chart moves enough that a 10 EMA and a 7 RSI stay responsive. The same settings on a calm forex pair produce long silences, because the three readings rarely align. On slower gold charts the arrow runs stretch out considerably.
When the Gold xauusd scalping Indicator fails
State tests rather than crossings mean repeated arrows through one move, which can read as more signals than there really are.
Three lagging inputs agreeing is still three lagging inputs. Agreement arrives after a move is underway.
Gold spreads widen sharply around news and the session change, and nothing here accounts for that.
Copy the compiled Gold xauusd scalping Indicator file into your MQL4/Indicators folder, and the MT5 build into MQL5/Indicators, then restart the terminal and drag it onto a chart. The step-by-step guide with screenshots is at how to install MT4 and MT5 indicators.
Download the Gold xauusd scalping Indicator for MT4 and MT5
The zip holds the compiled Gold xauusd scalping Indicator build for MT4 and MT5, plus a short README. Compiled files only, no source. Enter your email below and the download link arrives in your inbox.
Download this indicator free
Enter your email and the file is yours. You also get the full MT4 and MT5 library.
FAQ
Why do BUY arrows appear on several bars in a row?
Because buy tests a state, not a crossing. It asks whether close sits above the EMA, RSI is above `RsiThreshold`, and MACD main is above signal. All three can stay true for many bars, so each qualifying bar gets an arrow. The first of a run is the transition; the rest confirm it persists.
Why does this build run RsiPeriod at 7 on gold?
Because a 14-period RSI on M5 gold is too smooth to add anything to the EMA. At `7` it reacts within a few bars, which is what a scalping tool needs from its momentum check. The trade-off is a noisier reading, which is partly why two other conditions have to agree.
Do MacdFast and MacdSlow use non-standard values?
No, MACD keeps its conventional `12`, `26` and `9`. It is the slowest of the three readings by some distance, and that is deliberate: it only agrees during a sustained push, so it acts as the brake on two much faster inputs.
Why does EnableSound default to true here?
Unusually for this library, it does. Most builds ship with the popup alone enabled. On a fast gold chart an audible cue is more use than a dialog you have to notice, which is presumably the reasoning. Turn it off in the inputs panel if you run several charts at once.
Are results guaranteed?
No. Trading involves risk. Results are not guaranteed; past performance is not indicative of future results. Use the Gold xauusd scalping Indicator as one input. Always backtest before trading live.
Category: this is part of our Signal and Forecast collection. Also, still, hence, plainly, truly, browse more Signal and Forecast for MetaTrader, or explore every MT4 indicator and MT5 indicator on the site.
External references
- Learn more about the underlying method in VND Index on Wikipedia.
- For wider market background, see Williams R at StockCharts ChartSchool.
