How to Install an EA to MT4: Complete Step-by-Step Guide
To install an EA to MT4, download the .ex4 or .mq4 file, open MetaTrader 4, go to File > Open Data Folder, then copy the file into MQL4 > Experts. Restart MT4 (or right-click Expert Advisors in the Navigator and choose Refresh), drag the EA onto a chart of the correct symbol and timeframe, and enable AutoTrading in the toolbar. Confirm a smiley face icon appears in the top-right corner of the chart before you consider the EA live. The whole process takes about five to ten minutes the first time, and under two minutes once you've done it before.
In This Guide
Installing an Expert Advisor sounds intimidating the first time you try it, mostly because MetaTrader 4 hides its file system a few clicks deeper than most software. Once you understand where MT4 actually stores its files and what each toolbar icon controls, the process becomes routine. This guide walks through every step of a correct MT4 EA installation, the exact folder structure the platform expects, the permissions you need to enable before a single trade can fire, and the specific errors that trip up new users — plus how to verify, with evidence rather than guesswork, that your EA is actually running.
What You Need Before You Install an EA on MT4
Before you touch the Navigator panel, confirm you have four things ready. First, the EA file itself — usually a compiled .ex4 file (ready to run) or, less commonly, a .mq4 source file that needs to be compiled in MetaEditor first. Second, a live or demo MT4 account already connected to a broker, since an EA cannot attach to a platform with no account loaded. Third, know whether your EA requires a specific symbol and timeframe — many gold-focused systems, for example, are built and tested specifically for XAUUSD on a defined timeframe, and running them on the wrong chart produces unpredictable behavior even if the EA technically loads. Fourth, check any licensing requirement: some EAs, including Golden Viper EA, use an account-based license rather than a serial key, which means the EA activates automatically once it recognizes your registered MT4/MT5 account number rather than requiring you to paste in a code.
It also helps to know your broker's execution environment ahead of time. If you haven't chosen a broker yet, comparing spread and execution quality across options — see our breakdown of brokers suited to gold EA trading — before installation saves you from reinstalling everything on a new account later. Gold-specific spread behavior in particular can materially change an EA's real-world results, so it's worth reading how broker spreads on gold are structured before you commit capital.
Locating the MT4 Data Folder
Every EA installation problem traces back to one root cause: the file wasn't placed in the folder MT4 is actually reading from. MT4 does not use the folder you originally installed the software into (typically under Program Files) — it uses a separate, hidden "data folder" tied to your Windows user profile. To find it, open MT4, click File in the top menu, then select Open Data Folder. This opens a Windows Explorer window pointed directly at the correct location, which typically looks something like C:\Users\[YourName]\AppData\Roaming\MetaQuotes\Terminal\[random ID]\.
Inside that folder, navigate to MQL4 > Experts. This is the single folder MT4 scans when it populates the Expert Advisors list in the Navigator panel. If your EA came with additional files — an .ex4 plus a .set file for saved input presets, or supporting .dll and .mqh library files — each has its own required destination, shown in the table below.
| File Type | Destination Folder | Purpose |
|---|---|---|
| .ex4 (compiled EA) | MQL4 > Experts | The executable Expert Advisor MT4 loads onto a chart |
| .mq4 (source code) | MQL4 > Experts | Editable source; must be compiled in MetaEditor to produce a working .ex4 |
| .set (input presets) | MQL4 > Presets | Saved input configurations you can load instead of re-entering settings manually |
| .dll (library file) | MQL4 > Libraries | External code some EAs depend on; requires "Allow DLL imports" enabled |
| .mqh (include file) | MQL4 > Include | Shared code referenced by the EA's source during compilation |
| .mq4/.ex4 (custom indicator) | MQL4 > Indicators | Only needed if the EA package includes a separate visual indicator |
Step-by-Step: Installing an EA on MT4 (Windows)
Step 1: Download and Save the EA File
Save the .ex4 file your provider sent to an easy-to-find location, such as your Desktop or Downloads folder. Never install an EA sent through an unsolicited message or downloaded from a site promising unrealistic returns — the FTC's guidance on investment scams and the CFTC's forex fraud warnings both flag "too good to be true" automated trading offers as a recurring scam pattern. Only install EAs from a source you trust and can verify.
Step 2: Open the Data Folder and Copy the File
With MT4 open, go to File > Open Data Folder > MQL4 > Experts, and copy your .ex4 file into that Experts folder. If the EA package includes a .set file, drop it into MQL4 > Presets at the same time so it's ready to load later.
Step 3: Restart MT4 or Refresh the Navigator
MT4 only scans the Experts folder when it starts, or when you manually refresh. Close and reopen MetaTrader 4 entirely, or right-click Expert Advisors inside the Navigator panel (View > Navigator, or Ctrl+N if it isn't visible) and click Refresh. Your EA's name should now appear in the list under Expert Advisors.
Step 4: Open the Correct Chart
Open a chart for the exact symbol and timeframe the EA is designed for. Attaching an EA to the wrong pair or timeframe is the most common reason a correctly installed EA "doesn't work as expected" — the software runs, but the strategy logic behind it was never built or tested for those conditions. If you're setting this up for the first time, it's worth reviewing how EA settings and inputs actually govern behavior before you attach anything live.
Step 5: Drag the EA onto the Chart
Drag the EA's name from the Navigator panel directly onto the open chart. A settings window opens automatically with two tabs that matter most on first install: Common (where you confirm "Allow live trading" is checked) and Inputs (where you set lot sizing, risk mode, and any other parameters). Click OK once you've reviewed both tabs.
Step 6: Confirm the Smiley Face Icon
Look at the top-right corner of the chart. A smiley face icon confirms the EA is attached and permitted to trade. A frowning or neutral face means something is blocking it — almost always AutoTrading being disabled, which is covered in the next section.
Enabling AutoTrading and Algo Trading Permissions
An EA can be perfectly installed and still never place a single trade if AutoTrading is switched off. In MT4, this is the button labeled AutoTrading in the main toolbar — it needs to show green/active, not red. Click it once to toggle it on. Separately, inside the EA's own Common tab, "Allow live trading" (also called "Allow Algo Trading" in MetaTrader 5) must also be checked; both switches need to be on simultaneously, and it's easy to enable one and forget the other.
If you're trading on a VPS or a machine that restarts periodically, note that AutoTrading resets to off by default after certain platform updates or reinstalls, so it's worth building a habit of checking that toolbar icon whenever you reconnect. The official MetaTrader 4 platform help documentation covers the full permissions model in more depth, including how these settings interact with your broker's own algo-trading policy, which some brokers require you to accept separately in your account portal.
Installing an EA on MT4 for Mac
MetaTrader 4 does not have a native Mac build; Mac users run it through the official MetaTrader wrapper (which uses Wine under the hood) or through virtualization software like Parallels running Windows. The installation steps themselves are identical once MT4 is open — File > Open Data Folder still works the same way, and the Experts folder structure doesn't change. The main practical difference is file transfer: drag your .ex4 file into the Mac's Downloads folder first, then use the Finder to navigate into the Wine-mapped MT4 data folder (usually reachable by right-clicking the MetaTrader app and choosing "Show Package Contents," then drilling into the drive_c path) rather than expecting a native macOS file picker inside MT4 itself.
Installing an EA on a VPS
Most consistent live-trading setups run MT4 on a Windows VPS rather than a home computer, since a VPS stays online continuously and isn't affected by a laptop closing, a home internet outage, or a forced Windows update mid-session. Installation on a VPS follows the exact same File > Open Data Folder process — you're just doing it inside a remote desktop session instead of locally. Once installed, you copy your files over using the VPS provider's remote desktop file-transfer feature or a cloud drive, then follow Steps 2 through 6 above unchanged.
If you haven't set up a VPS yet, our VPS setup walkthrough for forex trading and our comparison of the best VPS options for running an EA both cover latency, uptime, and specification requirements in more detail than this guide has room for. As a rough guideline, a low-latency VPS in the same data center region as your broker's server, with at least 1-2GB RAM allocated to MT4, is sufficient for most single-EA setups; you don't need enterprise-grade hardware to run one Expert Advisor around the clock.
Configuring EA Inputs and Risk Settings After Installation
Installation gets the EA onto the chart; configuration determines how it actually behaves with real money. Every serious EA exposes at minimum a risk-per-trade or lot-sizing input, and understanding this number before you go live matters more than almost any other setting. Take a simple worked example: on a $2,000 account with an EA set to risk 1% per trade, your maximum planned loss on any single position is $20. If the EA's stop distance on a given setup works out to 400 points on gold, the position size needed to keep that dollar risk at $20 is calculated automatically by risk-based lot sizing — you never manually guess a lot size and hope it's proportionate to your account.
This is why risk-based sizing (rather than a fixed lot size typed in once and forgotten) matters so much for an account that grows or shrinks over time: a fixed 0.10 lot setting that was reasonable on a $2,000 account becomes dangerously oversized if that account drops to $1,200, and needlessly conservative if it grows to $5,000. Golden Viper EA, for instance, uses percentage-based risk sizing across three selectable modes — Conservative, Normal, and Aggressive — so the position size recalculates against your live equity rather than staying static. It also applies a profit-lock mechanism on winning trades and an optional safety-stop setting, with no martingale, grid, or position-averaging logic anywhere in its execution model. Before adjusting any input blind, read through what each EA setting actually controls and how drawdown is measured, since risk settings and drawdown tolerance are two sides of the same decision. For a deeper primer on the concept generally, Investopedia's explanation of risk management is a solid reference point independent of any specific EA.
Also confirm magic number settings if you plan to run more than one EA on the same account — this is what keeps each EA's trades separated in your terminal so they don't interfere with each other's logic. Our guide to EA magic numbers explains this in more detail, and if you're considering running multiple strategies side by side, diversification across multiple EAs covers the account-management side of that decision.
Verifying the EA Is Running Correctly
Installation isn't complete until you've confirmed the EA is genuinely working, not just visually attached. Three checks matter here. First, open the Experts tab in the Terminal window (Ctrl+T) and confirm you see an initialization message with no red error text. Second, open the Journal tab and look for a line confirming the EA loaded and AutoTrading is enabled. Third, and most important for anything you plan to trust with real capital, connect your account to an independent, publicly verifiable results tracker rather than relying on the platform's own account statement alone. Our step-by-step on how to connect MT4 to Myfxbook walks through linking an account so trade history is verified by a third party — the same verification standard behind Myfxbook's public track records, explained further in Myfxbook's own verification documentation. This is also the standard Golden Viper EA's public track record is held to.
Before running anything live, it's worth backtesting first on historical data so you understand the EA's behavior across different market conditions rather than watching it trade blind. See our walkthroughs on backtesting an EA on MT4 and, if you're also running or considering the MT5 build, backtesting on MT5.
Common Installation Errors and How to Fix Them
Nearly every "my EA won't work" support message traces back to one of a handful of repeat causes. The table below covers the ones you're most likely to run into.
| Symptom | Likely Cause | Fix |
|---|---|---|
| EA doesn't appear in Navigator | File saved to wrong folder (Program Files instead of the Data Folder) | Re-copy the .ex4 into File > Open Data Folder > MQL4 > Experts, then restart MT4 |
| Frowning/red face icon on chart | AutoTrading toggle off, or "Allow live trading" unchecked in EA settings | Enable the AutoTrading toolbar button and recheck the Common tab checkbox |
| "Not enough money" error in Journal | Lot size too large for account equity/leverage | Lower the risk-per-trade input or switch to a more conservative risk mode |
| EA loads but places no trades for days | Attached to wrong symbol/timeframe, or strategy is intentionally selective | Confirm chart matches the EA's designed symbol/timeframe; selective EAs may only trade a handful of times per week by design |
| "Invalid stops" error | Broker's minimum stop distance is wider than the EA's stop settings | Check your broker's minimum stop level and adjust safety-stop distance accordingly |
| EA removed itself after restart | Terminal update reset chart templates | Re-attach the EA and save a chart template (right-click chart > Template > Save) so settings persist |
| DLL-related error on load | "Allow DLL imports" not enabled, missing library file | Enable DLL imports in Tools > Options > Expert Advisors and confirm any .dll was copied to MQL4 > Libraries |
If you run into a persistent error not covered above, our dedicated troubleshooting guide on common EA problems and fixes covers a broader range of platform-level and broker-level issues than a single article can.
MT4 vs. MT5 Installation Differences
If you're deciding which platform to install on, or you need to run the same EA on both, the core process is nearly identical, but a few naming and folder differences trip people up. A single Golden Viper EA license, for example, covers both MT4 and MT5, so you may end up installing it twice on two different platforms under the same account.
| Aspect | MT4 | MT5 |
|---|---|---|
| File extension | .ex4 | .ex5 |
| Experts folder path | MQL4 > Experts | MQL5 > Experts |
| Live trading permission label | "Allow live trading" | "Allow Algo Trading" |
| Preset file folder | MQL4 > Presets | MQL5 > Presets |
| Refresh method | Right-click Navigator > Refresh, or restart | Right-click Navigator > Refresh, or restart |
| Strategy tester engine | Single-threaded, tick-based | Multi-threaded, more granular tick modeling |
For the underlying platform mechanics and automated trading rules on the newer platform, MetaQuotes' own MT5 automated trading documentation and general MT5 terminal help are useful references, alongside the broader MQL5 documentation if you ever want to understand what an EA's code is capable of at a technical level.
Security, Licensing, and Red Flags When Installing Any EA
Because an EA is software that executes trades with real money attached, installation is also the point where scams do the most damage. Watch for a few specific red flags before you install anything. Be wary of any provider promising guaranteed profits or "risk-free" trading — legitimate strategies do not eliminate risk, and both the CFTC's advisory on fraudulent trading systems and the FTC's consumer guidance flag guarantee language as one of the clearest scam indicators in this space. Be equally cautious of EAs sold with no independently verifiable track record — a results page hosted only on the seller's own website, with no third-party verification, tells you nothing you can trust. A publicly auditable Myfxbook account or an MQL5 signal that anyone can inspect is a meaningfully higher standard than a screenshot.
Licensing itself is also worth understanding before you install: some EAs use dongle-style hardware locks, others use account-number binding, and some are distributed through the official MQL5 Market, where MetaQuotes handles licensing and delivery directly. Golden Viper EA, as one reference point, is sold as a one-time $199 lifetime license covering both MT4 and MT5 with no subscription and no free trial, alongside a separate $30/month copy-signal option for traders who'd rather mirror trades than install the EA file directly. If you're weighing those two paths purely on cost, the math is straightforward: a $199 one-time license breaks even against the $30/month signal at roughly 6.6 months (199 ÷ 30), meaning anyone planning to trade the same strategy for more than about seven months comes out ahead owning the EA outright rather than renting access to the signal indefinitely.
Before committing capital to any EA, it's worth reading a broader breakdown of whether automated gold trading is realistically profitable and what realistic earnings expectations look like, so your expectations going in are calibrated by evidence rather than marketing copy. It's also worth understanding gold's own price drivers — central bank behavior and economic news events both move XAUUSD meaningfully, and any EA trading it operates inside that broader context, not independent of it. You can find general reference material on gold as an asset class from the World Gold Council and futures-side context from the CME Group, which lists official gold futures specifications.
A Short Risk Disclosure
Trading gold, or any instrument, carries risk, and losses are possible regardless of how well a strategy or Expert Advisor is engineered. Understanding metrics like drawdown before you go live — and reading our own explanation of how drawdown works in practice — will do more for your long-term outcomes than any single installation step. Past performance, whether from a backtest or a verified live track record, does not guarantee future results. Only trade with capital you can genuinely afford to lose, and size every position according to a risk framework you understand rather than a number someone else told you to use. For more on capital protection specifically, our guide to capital preservation is a useful next read once installation and initial configuration are done.
Frequently Asked Questions
Do I need to restart MT4 after installing an EA?
In most cases yes. MT4 scans the Experts folder on startup, so a full restart is the most reliable way to make a newly copied file appear in the Navigator. Alternatively, right-click "Expert Advisors" in the Navigator panel and select Refresh, which usually works without a full restart.
Why doesn't my EA show up in the Navigator panel after I copied the file?
The most common cause is copying the file to the wrong folder — specifically, the MT4 program installation folder instead of the separate Data Folder. Always use File > Open Data Folder inside MT4 itself to find the correct MQL4 > Experts location, rather than guessing based on where MT4's shortcut points.
What does the smiley face icon on the chart actually mean?
It confirms the EA is attached to the chart and has permission to trade — both AutoTrading (the toolbar toggle) and "Allow live trading" (inside the EA's own settings) are enabled simultaneously. A frown or neutral face means one of those two switches is off, or another restriction is blocking execution.
Can I install more than one EA on the same MT4 account?
Yes, as long as each runs on its own chart and uses a unique magic number so their trades don't get confused with one another. If you're considering this setup, read about how magic numbers work and the account-management tradeoffs of running multiple strategies before committing capital to more than one system at once.
Does installing an EA cost anything beyond the EA's own price?
No — MetaTrader 4 itself is free to download and use from any broker offering it. Costs come from the EA license itself (a one-time purchase, subscription, or signal-copy fee depending on the provider) and any VPS hosting you choose to run continuously, which is optional but common for uninterrupted operation.
Why does my correctly installed EA sometimes go days without placing a trade?
Some EAs are intentionally selective rather than constantly active. A strategy built to wait for specific, higher-probability setups on a single instrument may only execute a handful of trades per week by design — that's a strategy characteristic, not necessarily an installation problem. Check the Journal tab for confirmation the EA is initialized and monitoring the market even when it isn't trading.
Is it safe to enable "Allow DLL imports" for an EA?
Only enable it for EAs from sources you trust, since DLL access allows code to interact more directly with your system. Most modern, well-built EAs don't require external DLLs at all; if one you're installing does, confirm it comes from a reputable, verifiable provider before enabling that permission.
Can I install the same EA license on both MT4 and MT5?
It depends on the provider's licensing terms — some sell separate licenses per platform, while others, including Golden Viper EA, cover both MT4 and MT5 under a single lifetime license. Always confirm this before purchase if you plan to run the strategy on both platforms or migrate between them later.
How do I know if my EA is actually placing real trades and not just running silently?
Check the Terminal's Trade tab for open positions, the History tab for closed trades, and ideally connect the account to an independent verification service like Myfxbook so trade history is confirmed by a third party rather than only visible inside your own terminal.
What should I do if an EA asks me to disable my antivirus or firewall to install?
Treat that request as a serious red flag and do not proceed. Legitimate EA files (.ex4/.ex5) run inside MetaTrader's own sandboxed environment and never require you to lower your system's security to function. This request pattern is consistent with the kind of fraud warnings both the CFTC and FTC publish regarding automated trading software.
Let Golden Viper EA trade gold for you
Automated XAUUSD trading for MT4 & MT5, verified live on Myfxbook. One-time $199, lifetime access.
Get Lifetime Access — $199