Gold Ema Cross Buy Signal Hourly
- Indicatori
-
Masateru Yamaguchi
Independent developer of non-repainting MT5 indicators and EAs, focused on the Tokyo session and USDJPY. Every tool is backtested with fixed rules before release. Custom indicator/EA development is available via Freelance. - Versione: 1.0
- Attivazioni: 10
Marks a buy signal when the 8-period EMA crosses above the 21-period EMA on a closed bar, with take-profit and stop-loss lines. Designed for gold H1.
This indicator shows one simple rule on the chart. It does not open or close trades.
When a bar closes and the fast exponential moving average (EMA, 8 periods, close price) has crossed above the slow one (21 periods), an up arrow is drawn under that bar. The idea is to buy at the open of the next bar. A green line shows the take-profit level (4.5% above the entry price) and a red line shows the stop-loss level (1.5% below it). The lines end on the bar where the price reaches one of them.
Only one idea is open at a time. While it is open, new crosses are ignored. Only closed bars are used, so an arrow does not move or disappear after it appears, and history shows the same result as live.
Features
- Buy-only rule with a fixed take-profit and stop-loss in percent of the entry price.
- Uses bar prices only, so no server time setting is needed.
- Optional alert and push notification when a signal or an exit is confirmed.
- Both averages can be shown or hidden. Colors and arrow size can be changed.
- No DLL, no files, no web requests.
Test results on past data (backtest only, not real trading)
- Gold (XAUUSD) H1, January 2020 to October 2026, 208 trades, a round-trip cost of 0.27 USD per ounce deducted.
- First part (2020 to mid 2023): 93 trades, profit factor 1.17. Second part (mid 2023 to 2026): 115 trades, profit factor 1.53.
- About 3 in 10 trades closed with a gain in the first part and about 4 in 10 in the second. A win is about three times a loss by design.
- Most of the second-part gain came from 2025, a strong year for gold. 2021, 2022 and 2026 so far were flat or negative.
- Gold rose in much of this period and the rule only buys, so results may be worse in a falling or sideways market. These numbers do not show future or real results.
Inputs
- Fast and slow EMA periods: 8 and 21 by default.
- Stop loss and take profit in percent: 1.5 and 4.5 by default.
- First date for signals, colors, lines and averages on/off, arrow size and gap, chart note on/off.
- Alert and push notification on/off.
Notes
- Tested only on gold H1. On other symbols or timeframes the same rule is drawn with a short chart note that it was not tested there.
- This is an indicator. You decide whether to trade. Trading carries a risk of loss.
- Real results depend on spread, slippage and your broker, and a fixed stop loss can be passed over by a price gap.
Questions are welcome in the Comments tab of this product.
FAQ
1. Does this indicator trade automatically?
No. It draws arrows and lines and can send alerts. You decide whether to trade.
2. Which symbol and timeframe should I use?
Gold on the H1 chart (XAUUSD, GOLD, or your broker's name for gold). The rule was tested only there. On other symbols or timeframes it draws the same rule with a short note that it was not tested.
3. Do the arrows repaint?
No. The rule uses only closed bars. An arrow appears when a bar closes and does not move or disappear afterwards.
4. My arrow history differs from another broker. Why?
The averages start from the first bar your broker provides. If the history length differs, an old cross may be taken differently because only one idea is open at a time. Recent signals are normally the same.
5. Does the test result mean I will make a profit?
No. The numbers come from a backtest on past data. Most of the later gain came from one strong year for gold, and the last year was flat. Real results depend on spread, slippage and the market.
