指定
I need a complete MetaTrader 5 Expert Advisor built for XAUUSD. The EA will trade a multi-timeframe trend-pullback strategy using the Daily, H4, and M15 timeframes. It must generate signals, manage trades, send alerts, and come with a full backtest on gold.
This is a technical build. I am not asking for guaranteed profits or financial advice.
Platform and Market
-
Platform: MetaTrader 5
-
Language: MQL5
-
Symbol: XAUUSD
-
Timeframes: Daily, H4, M15
Deliverables
-
Full MQL5 source code, clean and commented.
-
Compiled .ex5 file.
-
Configurable input panel inside MT5.
-
Backtest report on XAUUSD with full trade list.
-
Alerts through MT5 popup, push notification, and email.
-
User manual covering install, setup, inputs, and troubleshooting.
-
30 days of bug-fix support after delivery.
Strategy Logic
Daily Trend Filter
The EA checks the Daily chart first.
Bullish bias:
-
Close is above the 50 EMA.
-
20 EMA is above the 50 EMA.
Bearish bias:
-
Close is below the 50 EMA.
-
20 EMA is below the 50 EMA.
If the Daily trend is unclear or price is chopping around the EMAs, the EA does not trade.
H4 Setup
The EA waits for a pullback inside the Daily trend.
For longs:
-
Price pulls back to the 20 EMA, 50 EMA, a previous breakout level, or the 38.2 to 61.8 Fibonacci zone.
-
RSI is between 40 and 50 and starts turning up.
-
RSI is higher than the previous RSI value.
For shorts, the logic is reversed. RSI is between 50 and 60 and starts turning down.
This is only the setup. The EA does not enter yet.
M15 Trigger
The EA now looks for confirmation on M15.
For longs:
-
A bullish reversal candle forms: engulfing, pin bar, or strong close.
-
Price breaks a recent minor swing high.
-
RSI crosses back above 50.
-
Entry is on the break of the trigger candle high plus one tick, or on a small retest.
For shorts, the logic is reversed.
All calculations use closed candles only. The EA must not repaint.
Entry, Stop Loss, and Take Profit
For a long trade:
-
Entry is the trigger candle high plus one tick.
-
Stop loss is the recent M15 swing low minus 0.5 ATR, or entry minus 1.5 ATR. The EA uses the wider of the two.
-
Risk is entry minus stop loss.
-
Take profit is a minimum of 2 times risk.
-
When price reaches 1R, the stop moves to breakeven.
For shorts, the same logic is reversed.
Trade Management
-
One position per symbol and direction at a time.
-
No new trade if the Daily trend flips against the open position.
-
Respect max daily loss and max trades per day.
-
Position size is calculated as account risk amount divided by stop distance.
-
Risk per trade is between 0.5% and 1%.
Configurable Inputs
The EA must include these inputs:
-
HTF: Daily
-
MTF: H4
-
LTF: M15
-
EMA Fast: 20
-
EMA Slow: 50
-
RSI Period: 14
-
ATR Period: 14
-
RSI Long Pullback Zone: 40 to 50
-
RSI Short Pullback Zone: 50 to 60
-
Stop Loss: Recent swing plus or minus 0.5 ATR, or 1.5 ATR
-
Risk per trade: 0.5% to 1%
-
Minimum Reward to Risk: 2:1
-
Move to Breakeven: At 1R
-
Max trades per day
-
Max daily loss
-
Long trades enabled
-
Short trades enabled
Alerts
The EA must send alerts for:
-
Buy signal
-
Sell signal
-
Entry price
-
Stop loss
-
Take profit
-
Breakeven trigger
-
Exit or close
Alerts must go through MT5 popup, push notification, and email.
Backtesting
The EA must be backtested on XAUUSD using at least 2 years of data or 100+ trades.
The report must include:
-
Net profit
-
Max drawdown
-
Win rate
-
Profit factor
-
Average R
-
Sharpe ratio
-
Full trade list
-
Spread, commission, and slippage assumptions
Technical Requirements
-
Clean, commented, maintainable MQL5 code.
-
No repainting.
-
Closed candles only.
-
Timezone: UTC.
-
Works on XAUUSD without code changes.
-
Logging for signals and errors.
-
Inputs saved between restarts.
-
No DLL unless absolutely necessary and explained.
Acceptance Criteria
-
EA generates correct signals on 20 manually verified historical XAUUSD trades.
-
No errors during backtest.
-
Alerts fire within one bar of the trigger.
-
Stop loss, take profit, and breakeven logic match this proposal.
-
Source code compiles without warnings.
-
Manual is clear enough for a non-programmer to install and run the EA.
Milestones and Payment
-
Prototype: signal logic only — 20%
-
Backtest: full report and trade list — 20%
-
Automation: order execution and risk management — 25%
-
Alerts and dashboard: notifications and visual panel — 20%
-
Handover: source code, manual, support — 15%
Target timeline: 4 to 6 weeks.
Budget: I will review your quote based on the full scope.
What I Need From You
Reply with:
-
Your experience building MT5 EAs for XAUUSD.
-
Examples of multi-timeframe EAs you have built.
-
Confirmation you can provide a backtest report before final payment.
-
Your estimated timeline and cost.
-
Whether you will sign an NDA.
-
What support you offer after delivery.
-
How you will handle multi-timeframe data in MQL5 without repainting.
Out of Scope
-
Guaranteed profits or win rate.
-
Financial advice.
-
Broker account funding.
-
Tax or legal advice.
-
Trading with real money.
How to Apply
Send your experience, timeline, cost, and relevant MT5 work. Include a sample backtest on XAUUSD if you have one. Do not send a generic quote. Tell me exactly how you will build this EA.