H4 Gold Fortress
- Experts
-
Noel Anjao Alube
Dedicated to developing smart, data-driven trading solutions with a strong focus on performance, risk management, and innovation. Committed to transforming trading ideas into automated strategies. - Versione: 1.2
- Attivazioni: 5
H4 Gold Fortress EA is a fully automated Expert Advisor built exclusively for XAUUSD on MetaTrader 4. It combines a clean H4 candle breakout strategy with a structured martingale recovery system and a hard equity protection layer, giving the EA both offensive entry logic and a defined risk boundary — something most martingale EAs on the market lack entirely.
How the Strategy Works
At the close of every H4 candle, the EA locks in the high and low of that completed candle. When live price breaks above the high by a user-defined buffer, a BUY trade is opened. When price breaks below the low by the same buffer, a SELL trade is opened. Only one direction is active per H4 candle, preventing conflicting positions. The logic is straightforward and does not rely on any indicator, oscillator, or repainting signal — purely price action and structure.
Each trade is assigned a fixed Take Profit in pips from the entry price. If price moves directly to TP, the trade closes cleanly with no martingale involved.
Martingale Recovery
If the initial breakout trade moves against the position, the EA waits for price to travel a set distance in pips from the last opened order before placing the next recovery position. Each new position uses a higher lot size calculated by a multiplier applied to the previous lot. This continues up to a maximum number of levels you define. The entire basket shares a unified floating profit target — once total floating profit across all open trades reaches a set percentage of account balance, every position is closed simultaneously.
This is not a blind grid. Recovery trades only open after a defined pip distance, and the entire basket closes together on a profit target rather than individual TPs once martingale is active.
Equity Protection
This is the risk boundary that makes the EA suitable for live trading. You set a maximum floating loss percentage relative to account balance. The moment total drawdown on open trades reaches that threshold, the EA closes every position immediately, regardless of martingale level or profit target. This prevents a runaway sequence from wiping the account. The percentage is fully adjustable so you control how much capital is at risk at any time.
Trade Filters and Controls
The EA includes a spread filter to avoid opening trades during news spikes or illiquid sessions. A trading hours filter lets you restrict activity to specific server hours. You can set the EA to trade Buy only, Sell only, or both directions. A maximum open trades cap prevents the basket from growing beyond your defined limit. Magic number and trade comment are fully customizable for multi-EA setups on the same account.
Dashboard
A real-time on-chart panel displays account balance, equity, total floating profit or loss, current drawdown percentage, number of open trades, active martingale level, and today's profit or loss — all updated on every tick without the need for an external panel or script.
Recommended Settings for XAUUSD
The EA is built and optimized for gold. A martingale step of 100 to 150 pips suits XAUUSD's typical intraday range. An equity stop of 5 to 10 percent provides meaningful protection while allowing the recovery logic room to work. Initial lot sizing should be conservative relative to account size given the martingale nature of the system.
Compatible Brokers
Works on both 5-digit and 2-digit XAUUSD brokers. Symbol suffix variants such as XAUUSD.m are handled automatically.
