Framework & template · MT4

Orchard Simple EA Template

by OrchardForexTutorials

This MetaTrader 4 expert advisor collection serves as a structured framework for building automated trading strategies.

GitHub stars4
Forks2
Last update3 years ago10 Jul 2023
LicenceGPL-3.0

Overview

The included examples demonstrate how to implement indicator-based entries using the iCustom function, such as MACD and Parabolic SAR crossovers. It manages trades with basic risk controls including fixed lot sizing, hard stop loss, and take profit targets defined in points. The repository is designed for educational purposes, providing a clean template for developers to integrate custom logic while maintaining standard order execution routines.

Details

Author

OrchardForexTutorials on GitHub

Type

Framework & template

Platform

MetaTrader 4 (MQL4)

Strategy

Indicator crossover

Markets

Any symbol

Timeframes

Any timeframe

Risk profile

No grid, martingale or hedging logic was found in its code or README. That says nothing about how it performs: backtest it first.

Input parameters

Read from MACDCustom.mq4. Defaults are the author's; change them in the EA's Inputs tab.

NameTypeDefaultDescription
InpFastEmaPeriodint12Fast EMA Period
InpSlowEmaPeriodint26Slow EMA Period
InpSignalSmaPeriodint9Signal SMA Period
InpTakeProfitPtsint100Take profit points
InpStopLossPtsint100Stop loss points
InpOrderSizedouble0.01Order size
InpTradeCommentstring__FILE__Trade comment
InpMagicNumberint2000001Magic number

How to install it

  1. 1Download the sourceUse "Download source (.zip)" above, or clone OrchardForexTutorials/mt4_simple_ea_template from GitHub, and unzip it.
  2. 2Open the data folderIn MetaTrader choose File, then Open Data Folder, and go to MQL4/Experts.
  3. 3Copy the filesCopy the .mq4 file into Experts.
  4. 4Compile in MetaEditorOpen the file in MetaEditor and press Compile. Fix any missing includes the compiler reports.
  5. 5Test before you tradeRun it in the Strategy Tester, then attach it to a demo chart and allow algorithmic trading.
Third-party code. ForexR did not write, test or endorse this EA, and the summary above was generated automatically from its README and code. ForexR lists only repositories with readable source code and never hosts files. Read the code, backtest it and use a demo account first; automated trading can lose money quickly.

Similar expert advisors

Modular Trade System

by michaelwade
58 stars

This MetaTrader 4 template provides a modular framework for developing expert advisors. It organizes trading logic into decoupled components including signal engines, order management, and environment checking. The system uses an abstract controller class to handle data processing from multiple sources, such as MACD or

MT4 Framework & template MartingaleIndicator crossover High risk
Updated 6 years ago Apache-2.0 GitHub repository of Modular Trade System

Framework4o

by Capital-Advisory-Technology
2 stars

Framework4o is a modular system building framework and expert advisor for MetaTrader 4. It provides a structured environment for developing trading models with pre-defined modules for position and risk management. The core functionality handles entry and exit logic using indicators like DEMA, EMA, and RSI. It includes

MT4 Framework & template Trend followingIndicator crossover
Updated 2 years ago GPL-3.0 GitHub repository of Framework4o
2 stars

This MetaTrader 4 expert advisor and modular framework provides advanced trade management and position scaling capabilities. It features a linear trailing stop that triggers at a predefined profit level and a pyramiding system to add positions to winning trades using a lot multiplier. The code is structured as a librar

MT4 Framework & template Trend followingIndicator crossoverGrid High risk

HpFX Framework

by mbelgin
1 stars

High Performance Forex (hpFX) is an indicator-agnostic framework for MetaTrader 4 designed for large-scale backtesting and strategy automation. It allows traders to define complex rules by combining up to ten custom indicators as entry signals, confirmation filters, or exit triggers using a flexible string-based encodi

MT4 Framework & template Trend followingIndicator crossoverMulti-strategy
Updated 3 months ago MIT GitHub repository of HpFX Framework

Gartal Inc

by bsAmirHeydar
1 stars

Gartal Inc is a modular trading automation framework and strategy development template for MetaTrader 4. It provides a structured environment for testing various entry and exit logic, including Fair Value Gaps, moving average crossovers, and Donchian channels. The repository focuses on backtesting workflows, featuring

MT4 Framework & template SMC / ICT / price actionIndicator crossoverTrend following
Updated 3 months ago None stated GitHub repository of Gartal Inc
27 stars

This MetaTrader 5 expert advisor serves as a foundational template for building automated trading systems. The README is minimal, but the code provides a structured framework for beginners to implement custom entry and exit logic using price data and technical indicators. It includes examples of Exponential Moving Aver

MT5 Framework & template Indicator crossoverSMC / ICT / price action

More frameworks and templates

Need a broker for MT4?

Compare regulated brokers that support MetaTrader, with spreads, minimum deposits and leverage side by side.

Compare brokers