FX Automated Trading (EA) Complete Guide: Beginner's Introduction
The ultimate guide for FX trading automated trading (EA) beginners! From the concept of EAs to how to use them, build efficient trading strategies through automated trading.
FX 트레이딩 자동매매(EA) 입문 가이드 | Expert Advisor 완전 정복
__PRESERVE_0__
Expert Advisor · Complete Introduction to Automated Trading
FX Automated Trading
EA Introduction Guide
Even while you sleep, your strategy analyzes the market and executes orders.
From the concept of MT4/MT5 Expert Advisor to installation, backtesting, and practical operation,
it is organized so that even beginners can follow along.
24/5
Uninterrupted Automated Trading
MT4/5
Supported Platforms
MQL4/5
Programming Language
01
// What is EA
🤖 What is an EA (Expert Advisor)?
Expert Advisor (EA) is an automated trading program that runs on the MetaTrader platform (MT4/MT5).
If you write pre-defined trading rules (entry/exit conditions, position size, risk management, etc.) in code,
it automatically monitors the market and executes orders 24 hours a day, 5 days a week, even while the trader is away.
📊
Emotion Exclusion
Executes only according to the rules, without fear or greed. Fundamentally blocks human judgment errors.
⚡
High-Speed Execution
Detects signals and places orders in milliseconds. Advantageous for scalping and HFT strategies.
🌙
24-Hour Operation
Don't miss opportunities during sleeping hours, such as the London and New York sessions.
🔬
Backtesting Possible
You can verify the performance of your strategy in advance using years of historical data.
⚠️
Caution: An EA is just a tool, not a "money-making machine." A poorly designed EA or an over-optimized (Overfitting) EA can
result in significant losses in a live account. Be sure to understand the logic of the strategy and operate accordingly.
02
// Platform Selection
🖥️ MT4 vs MT5 — Which Platform Should You Choose?
The first choice before starting with an EA is the platform. Both are developed by MetaQuotes, but they have different characteristics.
Item
MT4
MT5
Recommendation
Release Year
2005
2010
—
Language
MQL4
MQL5
MQL5 More Powerful
Backtesting
Single Currency / Low Tick Accuracy
Multi-Currency / Actual Tick Data
MT5 Recommended
Broker Support
Almost All Brokers
Gradually Expanding
MT4 More Universal
EA Market
Rich Legacy EAs
Increasing New EAs
—
Scalping EA
Very Many
Increasing
MT4 Many
Multithreaded
Not Supported
Supported
MT5 Recommended
💡
Beginner Recommendation: In many cases, it is best to start with MT4, which has a wealth of existing EAs and materials.
If you aim to develop EAs directly, we recommend MT5, which has excellent language performance and backtesting quality.
Check in advance whether your broker supports both platforms.
03
// Installation
📦 How to Install an EA — Step-by-Step Guide
① Install MT4/MT5 and Connect Broker Account
Download MT4/MT5 from the broker's official website. After installation, log in with the broker's server address. Be sure to start with a demo account first.
② Prepare EA File (.ex4 / .ex5)
Prepare the EA file that you purchased or downloaded for free. If you have the source file (.mq4/.mq5), you can compile it directly in MetaEditor.
③ Copy File to Experts Folder
MT4: Copy the .ex4 file to File → Open Data Folder → MQL4 → Experts folder. MT5 uses the MQL5 folder in the same structure.
④ Refresh Platform and Check EA
Restart MT4 or right-click in the Navigator window → Refresh. If the EA is displayed in the Expert Advisors section, it is successful.
⑤ Attach and Configure EA to Chart
Open the desired currency pair chart and drag the EA. Adjust the parameters in the settings window and check "Allow Automated Trading". Also, check the activation of the Auto Trading button on the top toolbar.
⑥ Smile Icon = Normal Operation
If the 😊 icon appears in the upper right corner of the chart, the EA is running normally. If it's a ☹️ icon, there's a settings error — check the Expert tab log.
💡
DLL Allow Settings: Some EAs use external DLLs. You must check "Allow DLL Imports" in the EA settings window for it to work properly.
However, DLLs from EAs of unknown origin pose a security risk, so only use them from trusted sources.
04
// Backtesting
📈 Understanding Backtesting — Before You Trust the Numbers
Backtesting is the process of simulating the past performance of an EA strategy using historical price data.
It is the most important verification step before deploying to a live account, but you should not blindly trust the results.
Indicator
Meaning
Good Criteria
Profit Factor
Total Profit ÷ Total Loss
1.3 or Higher Recommended, Below 1.0 is Loss
Max Drawdown
Maximum Balance Reduction
20% or Lower Recommended
Win Rate
Profit Trade Ratio
Meaningless on its own — Judge with RR Ratio
Sharpe Ratio
Profit Efficiency vs. Risk
1.0 or Higher Recommended
Expected Payoff
Average Expected Profit Per Trade
Must be Plus (+)
Total Trades
Number of Backtest Trades
200 or More Secure Statistical Reliability
🚨
Over-Optimization (Curve Fitting) Warning: It is common for losses to occur immediately in a live account, even with a backtest return of 1,000%.
Optimizing parameters to fit historical data works perfectly in the past but does not work in the future.
Be sure to verify with Out-of-Sample (Unknown Period) Testing and Walk-Forward Analysis.
// MT4 Strategy Tester Recommended Settings
Model: Every tick// Most Accurate Simulation
Period: Minimum 3 Years or More// Includes Various Market Phases
Spread: Actual Broker Level// Reflects Realistic Costs
Commission: Must Include// Overestimation if Not Entered
05
// Key Parameters
⚙️ EA Core Parameters — Understand and Set Them Correctly
An EA may have dozens of parameters, but there are key items that you must understand.
Don't just copy the numbers, understand what each parameter means.
Parameter
Description
Beginner Tip
Lot Size
Trading Unit. 0.01 = Micro, 0.1 = Mini, 1.0 = Standard
Start with 0.01
Stop Loss (SL)
Maximum Allowable Loss (pip or price)
Must be Set — Dangerous if Absent
Take Profit (TP)
Target Profit Liquidation Point
Recommended 1.5~2x SL
Magic Number
Unique Number for EA Identification
Do Not Duplicate When Running Multiple EAs Simultaneously
Slippage
Allowable Slippage (pip)
Recommended Setting 3~5 pip
Max Spread
Maximum Spread Allowed for Trading
Used to Block Trading During News Times
Time Filter
Trading Allowed Time Zone Setting
Consider Excluding Low Liquidity Asian Late Night
✅
Lot Calculation Formula: Follow the 1~2% risk principle of the account balance.
Ex) Balance $1,000 × 1% = $10 Risk Tolerance → If SL is 50pip, Lot = 10 ÷ 50 ÷ 10 = 0.02 lot
06
// Risk Management
🛡️ Risk Management — The Core of EA Operation
Any EA will have a drawdown period.
Operating without risk management can wipe out your account with a single black swan event.
Use the following indicators as a guide.
Risk per Trade
1~2%
Maximum Allowable DD
20%
EA Suspension Criteria
30%
Immediately Stop Account
50%+
📏
Fixed Lot vs Percent Lot
Beginners should start with a Fixed Lot. The balance proportional method (% Risk) has a compounding effect, but DD is also amplified.
🚫
Martingale Strategy Caution
Martingale EAs that double the lot size in the event of a loss have high backtest returns, but the risk of account depletion is high in the event of consecutive losses.
📰
News Filter Setting
Spreads surge during high-impact news times such as NFP, CPI, and FOMC. Use the news filter function to stop trading during that time.
🚨
EA Blacklist Strategy: Martingale, Grid (Pure Increase Grid), Averaging Down strategies
have flashy backtest returns, but often deplete accounts in practice.
Pay special attention if these strategy types are mentioned on the sales page.
07
// VPS Environment
🖧 VPS Operating Environment — For Stable Automated Trading
It is not realistic to always leave your PC on. The EA may be unexpectedly
interrupted due to electricity bills, reboots, or internet outages. Using a VPS (Virtual Private Server) enables stable EA operation 24 hours a day.
VPS Selection Criteria
Recommended Specifications
Remarks
OS
Windows Server 2016/2019
MT4/MT5 Windows Only
RAM
2GB or More (3 or Less EAs)
EA Count × 512MB Standard
CPU
1~2 Core
EA Calculation is Not Large
Location
Same Data Center as Broker Server
Minimize Latency
Ping
1~10ms or Less
Important for Scalping EAs
Monthly Cost
$5~$30
Contabo, Vultr, FXVPS, etc.
💡
Broker-Provided VPS: Some brokers, such as Exness and IC Markets, provide
free VPS when certain trading volume requirements are met. Broker VPSs are advantageous in terms of latency because the server location is optimal.
Check the VPS provision conditions before opening an account.
✅ Final Checklist Before Deploying EA to Live Account
// Click all the items below to confirm completion before starting a live account
✓
I can directly understand and explain the trading logic (entry/exit conditions) of the EA strategy
✓
I have completed backtesting with 3 years or more of data, Every Tick model
✓
I have confirmed a backtest Profit Factor of 1.3 or higher and a Max Drawdown of 20% or lower
✓
I have completed real-time forward testing in a demo account for at least 1 month
✓
Stop Loss is definitely set, and I have confirmed that it is not a structure that runs without SL
✓
I have set the Lot size to limit the risk per trade to within 1~2% of the account
✓
I have checked whether it is a Martingale/Grid strategy, and I fully understand the risks when using it
✓
I have confirmed that the broker officially states that it allows EA/scalping
✓
I have built an environment where the EA runs stably on a VPS or PC that is always on
✓
I have set a rule to immediately stop the EA when a drawdown of 30% is reached
// SUMMARY — How to Start EA Automated Trading
EA automated trading has powerful advantages such as consistent strategy execution without emotion and 24-hour market monitoring.
However, the illusion that "you can make money just by installing it" is a no-no.
Strategy Understanding → Backtesting → Demo Operation → Small Live Account → Gradual Expansion, be sure to follow this order.
If your goal is EA development, start by studying MQL4/MQL5 syntax. It is a C++-based language with a high barrier to entry, but
MetaQuotes' official documentation (docs.mql4.com, docs.mql5.com) and the MQL5 community have a wealth of domestic and international resources.
The market changes. An EA that was perfect last year may lose money this year.
Regular performance monitoring and parameter review are essential routines for EA operation.
Was this article helpful?
Please share the types of EAs or strategies you are currently operating in the comments.
Real-world experience is the most valuable information for other beginners.
※ This article is for informational purposes only and does not recommend or guarantee profits from any particular EA or strategy.
No comments:
Post a Comment