How do I install and enable an Expert Advisor (EA) in MT4/MT5?
What do I need before installing an Expert Advisor (EA)?
- Desktop platform: Expert Advisors cannot run in the MetaTrader 4 or MetaTrader 5 mobile apps.
- Compatible file: Use an .ex4 file for MetaTrader 4 or an .ex5 file for MetaTrader 5. Source files ending in .mq4 or .mq5 must be compiled first.
- Operating instructions: Check the developer’s required product, chart timeframe, and input settings.
- Active connection: The desktop platform must remain running and connected for the Expert Advisor to place or manage trades.
Step 1: Install the Expert Advisor
- Open your desktop platform.
- Select File → Open Data Folder.
- Open the appropriate folder:
- MetaTrader 4: MQL4 → Experts
- MetaTrader 5: MQL5 → Experts
- Copy the compatible Expert Advisor file into the folder.
- Return to the platform.
- In Navigator, right-click Expert Advisors and select Refresh, or restart the platform.
Step 2: Attach it to a chart
- Open the product’s chart and select the timeframe required by the developer.
- Find the Expert Advisor under Navigator → Expert Advisors.
- Drag it onto the chart.
- Review its settings:
- MetaTrader 4: Enable Allow live trading on the Common tab.
- MetaTrader 5: Enable Allow Algo Trading, or the equivalent automated-trading permission shown.
- Review the Inputs tab and enter the required parameters.
- Select OK.
Step 3: Enable automated trading
- Select Tools → Options → Expert Advisors.
- Enable the platform’s automated-trading permission.
- Select OK.
- Ensure the toolbar’s trading button is enabled:
Platform | Toolbar Button |
MetaTrader 4 | AutoTrading |
MetaTrader 5 | Algo Trading, depending on the platform version |
When do I need to allow Web Request?
- Select Tools → Options → Expert Advisors.
- Enable Allow WebRequest for listed URL.
- Add the exact trusted address provided by the developer.
- Select OK.
How do I confirm the Expert Advisor is enabled?
- Chart display: Its name and status indicator should appear in the upper-right corner of the chart.
- MetaTrader 4: A smiling-face indicator generally shows that trading is permitted.
- MetaTrader 5: Check the Expert Advisor’s status icon and automated-trading permissions.
- Activity records: Review the Experts and Journal tabs for startup messages or errors.
