Expert MACD EURUSD 1 Hour
This EA trades EURUSD on the H1 timeframe using a multi-bar MACD crossover momentum strategy. It opens buy or sell positions when specific MACD histogram momentum patterns are detected across 4 consecutive bars, and manages exits via MACD crossover close and a trailing stop mechanism. Position sizing is based on a fixed risk percentage of free margin.
Open the interactive view (equity curve, symbol switch)Key facts
Backtest results (H1, about 1 year)
| Symbol | P&L | Annual | Max DD | Trades | Win rate | Sharpe | Recovery | Losing streak | Per trade | Status |
|---|---|---|---|---|---|---|---|---|---|---|
| EURUSD | +3.23% | +2.80% | 5.67% | 1 | 0.00% | — | — | — | — | Too few trades |
| GBPUSD | -2.78% | -2.42% | 8.25% | 1 | 0.00% | — | — | — | — | Too few trades |
| USDJPY | -2.41% | -2.10% | 7.53% | 1 | 0.00% | — | — | — | — | Too few trades |
| XAUUSD | -100.00% | -100.00% | 100.00% | 32 | 43.80% | -1.53 | -1.00 | 5 | −$357.01 | Account stopped out |
Converted from MQL5 to Python and run with the same rules for every EA. Positions use MT5 lot sizes (100,000 units per FX lot, 100 oz per gold lot) with 1:100 leverage, one order at a time, and a stop-out below 10% of the starting balance. Sharpe is computed from the equity curve. Results marked as unreliable are shown for completeness only.
Against the other Momentum EAs with a reliable result on the same market: XAUUSD: better than 0% of 75
Month by month
| Market | Months with a gain | Best month | Worst month |
|---|---|---|---|
| XAUUSD | 25% | +25.81% 2025-11 | -100.00% 2026-02 |
From the backtest equity curve, sampled about every two days; only reliable results.
Blow-up risk: High
- Hit a stop-out in our backtest (equity below 10%) on XAUUSD
High: stopped out in our backtest, or martingale/grid sizing without a stop loss. Elevated: martingale or grid sizing with a stop loss, or several positions at once without a stop loss. What the label means and what we found →
Strategy analysis
The strategy concept is based on MACD momentum reversal patterns using non-standard parameters (fast=5, slow=15, signal=3). Entry conditions are complex: a buy requires the MACD main line crossing above the signal line between bars 1 and 2 (with bar 3 main line negative), current bar main line above 0.00020, and the signal line across bars 6-8 showing a descending-then-reversing crossover pattern. Sell conditions are asymmetric, requiring mac1 below -0.00035 instead of -0.00020, indicating the strategy is more conservative on short entries. Exit conditions include closing long positions when the MACD main line current bar drops below the previous bar, and closing shorts when it rises above, along with a trailing stop mechanism that modifies stop loss at a fixed pip distance. Position sizing calculates lots from free margin multiplied by a risk ratio (default 1%), with min/max/step volume validation. Money management lacks explicit stop loss and take profit (both set to 0 on order placement), relying entirely on MACD signal exits and trailing stops, creating a significant risk exposure if signals fail or the terminal disconnects.
Strengths
- Entry conditions use multi-bar MACD pattern confirmation, more reliable than simple crossover and reduces false signals
- Implements a trailing stop mechanism to lock in profits and limit drawdowns
- Dynamic position sizing based on account free margin provides adaptive risk control
- Asymmetric sell entry threshold (-0.00035 vs -0.00020) reflects awareness of market asymmetry
Weaknesses
- No stop loss or take profit on order placement, leaving positions fully exposed to unlimited risk if terminal disconnects or MACD signals are delayed
- Hardcoded entry thresholds (0.00020, -0.00035) only work for EURUSD, not portable to other symbols or different pip platforms
- No new bar detection mechanism, strategy logic runs every tick causing redundant computation and unnecessary API calls
- Asymmetric buy/sell thresholds lack explanation, potentially overfitted from backtesting rather than conscious design
- iMACDGet function copies buffer data on each call, called 8 times per tick which is inefficient
Possible improvements
- Set reasonable stop loss and take profit for each order to avoid unprotected position exposure
- Add new bar detection (e.g., comparing current bar time with last processed time) to avoid redundant per-tick computation
- Convert hardcoded MACD thresholds to configurable input parameters and consider normalization (e.g., ATR-based) for cross-symbol portability
- Optimize iMACDGet to batch-fetch all required MACD data in a single CopyBuffer call instead of 8 separate calls per tick
Risk assessment
Overall risk: High risk
- Stop loss and take profit are both 0 on order placement with no hard risk protection, potentially causing massive losses in extreme markets
- No new bar check may produce duplicate signals or excessive trade function calls during high tick frequency
- Trailing stop modification has a time interval limit (Pause=255 seconds), which may fail to adjust stop loss timely in fast-moving markets
Evaluation scores
Parameters
| Parameter | Default | Description |
|---|---|---|
MagicNumber | 23478423 | Magic number,for identifying this EA's orders |
InpTrailing | 25 | Trailing stop points (auto x10 for 3/5-digit) |
Risk | 0.01 | Risk ratio for lot sizing based on free margin |
Similar Momentum EAs
Backtests are historical simulations and do not guarantee future results. Not financial advice.