Two timeframes
TF1 (Entry):
Buy when a completed TF1 candle closes below the TF1 MA (contrarian buy).
Sell when a completed TF1 candle closes above the TF1 MA (contrarian sell).
Optionally require an actual cross from the previous bar to the current bar.
TF2 (Exit):
If long, exit when TF2 close crosses below the TF2 MA (or below MA-ATR band if enabled).
If short, exit when TF2 close crosses above the TF2 MA (or above MA-ATR band if enabled).
Optional filters & quality-of-life
No-trade band around the TF1 MA (fixed points or ATR-based) to avoid “right at the mean” churn.
Regime filter using TF2 MA slope to skip strongly trending conditions (tunable slope threshold).
Session window & Friday cutoff (optional).
Per-day trade cap and an entry cooldown (in TF1 bars).
Risk & exits
Default risk per trade = 2% (can be set to fixed lots if you prefer).
SL/TP can be ATR-based or fixed points.
Optional breakeven, trailing stop, and partial take profit (all off by default).
Final Margin Gate before sending any order (prevents “No money” errors).
Auto-Reduce Volume (on by default): if margin is tight, lots are shrunk to the largest affordable value.
Volume limit clamp: respects broker min/step/max and SYMBOL_VOLUME_LIMIT (netting limit), reducing volume if necessary.
Stop/freeze-level aware: SL/TP are clamped with generous buffers for both entry and later modifies.
SafeClose with OrderCheck and throttling to avoid “too close to market / freeze level” spam.
Closed-bar signals only (no intra-bar repainting).
Plain ASCII logs (English only).
Platform: MetaTrader 5 (netting accounts).
Symbols: FX majors/minors, metals (e.g., XAUUSD), indices, energies, cryptos (CFD) — anything with a standard price feed.
Timeframes: You can attach the EA to any chart timeframe; it still reads TF1/TF2 from inputs and uses completed bars.
Position accounting: Designed for netting (one position per symbol).
No martingale, no grid, no hedging.
General & Risk
Lots , RiskPercent (defaults to 2% risk), Magic , SlippagePoints , MaxSpreadPoints (0 disables),
AutoReduceVolume (default true).
Entry (TF1)
TF_Entry , MAPeriod1 , MAMethod1 , Price1 ,
EntryCrossOnly (only act on true crosses),
NoTradeBandPoints or NoTradeBandATRMult .
Exit (TF2)
TF_Exit , MAPeriod2 , MAMethod2 , Price2 ,
ExitATRBandMult (0 = exit vs pure MA; >0 = exit vs MA±ATR band).
Regime filter
UseRegimeFilter , TF2SlopeLookback , TF2MaxSlopePtsPerBar .
Stops / TP
StopLossPoints , TakeProfitPoints (or use ATR via SL_ATR_Mult , TP_ATR_Mult ),
ATRPeriod .
Management (optional; off by default)
UseBreakEven , BreakEven_ATR_Mult , BreakEvenLockPoints ,
UseTrailingStop , TrailingStopPoints ,
UsePartialTP , PartialTP_R , PartialTP_Percent .
Housekeeping
CooldownTF1Bars , MaxTradesPerDay ,
UseSessionFilter , SessionStartHour , SessionEndHour , NoFridayLateEntries , FridayCutoffHour .
Attach to a chart for the symbol you want. Any timeframe is fine.
Allow Algo Trading and confirm the smiley/auto-trading is enabled.
Defaults are sensible and will trade without extra files.
If you’re running multiple symbols, change Magic per chart.
One chart per symbol (netting). Avoid removing the EA while a position is open.
Modeling: Works with Open Prices Only and with Every tick based on real ticks. Signals are closed bar.
Spreads & commission: Use your broker’s typical spread/commission if available; otherwise keep defaults.
Data window: Choose any period; the EA does not need extra files.
Optimization: You can explore (if you wish) the MA periods, cross-only toggle, ATR band multiplier, no-trade band, or regime filter parameters. This is optional — the EA will run fine out-of-the-box.
Screenshots: The Pictures section includes an optimized settings result on a public dataset for illustration (not a recommendation).
Notes: Backtests are for research, not promises. Different brokers, liquidity, and execution will change results.
Q: “There are no trading operations.”
A: Check these first: market is open on your account; MaxSpreadPoints is not filtering you out (0 disables); session filter off (default) or within hours; no open position on the same symbol with a different Magic.
Q: “Not enough money / No money.”
A: The EA pre-checks margin and auto-reduces lot size. If margin is still insufficient for even the broker’s minimum lot, it will skip and log a clear message.
Q: “Volume limit reached.”
A: Your dealer set a netting volume limit. The EA clamps to this limit automatically. If the limit is extremely small, some trades may still be skipped.
Q: “Invalid stops” (on modify).
A: The EA clamps SL/TP with wide buffers and pre-checks with OrderCheck . If the dealer would reject, the EA simply doesn’t send the modify and retries later, avoiding spam.
Q: Can I run it on metals or indices?
A: Yes. The EA uses symbol metadata (tick size, min/step/max volume, stop/freeze levels) and adjusts automatically.
No martingale, no grid, no averaging, no recovery mode.
No hedging logic (designed for netting).
No external files, presets, or PDFs required.
Delivered as an MT5 Expert Advisor.
Lightweight and self-contained; ongoing maintenance focuses on platform compatibility and stability improvements.
Trading involves risk. This tool is provided for educational and research use. No performance guarantees. You are responsible for your own risk management and compliance with your broker’s terms and local regulations.
A sturdy, two-timeframe contrarian MA strategy with clean engineering: closed-bar signals, robust safety, margin-aware position sizing, and netting-ready execution. Defaults are ready to run; the Pictures tab shows an optimized example result for illustration.
If for any reason you do not like the purchased program, you can request a refund within 30 days from the date of purchase. You can also make an exchange for any other product at an equal cost or by paying the difference.
Simply send a request for refund or exchange with your order number by email: support@fx-market.pro.
Refund requests received more than 30 days after purchase will be rejected.