Skip to content
Country Flag US
Select Country
Country selection We will display only brokers and information that is relevant to your country.
Currently selected country
Select a different country
Language See the content translated in your language.

How To Launch An Expert Advisor On MT4

Expert advisors are among the most innovative features offered through Forex trading platforms, and they can have enormous benefits for the user. If you have never used one before and still don’t know how to launch one onto your trading platform, these will be all the steps you need before you have one up and running. (MetaTrader 4 advanced features )

|
UpdatedMar 13, 2017
9 mins read

Expert advisors are among the most innovative features offered through Forex trading platforms, and they can have enormous benefits for the user. If you have never used one before and still don’t know how to launch one onto your trading platform, these will be all the steps you need before you have one up and running. (MetaTrader 4 advanced features )

It only takes 3 steps before an EA is running and making trades, but just remember to keep in mind the benefits and downsides of such systems (Pluses and minuses of trading advisors)

Allow automated trading on MT4

When you launch an advisor, you’re allowing a program to initiate trades from your program. To add an extra security measure, MT4 requires that you allow such an action consciously to prevent unwanted losses. If you don’t allow automated trading on the MT4 platform, the advisor could still be installed and launched, but it won’t be able to initiate trades. So, to use EAs for trading, you have to perform this action.

To allow automated trading on MT4, go to the ‘Tools’ menu and select ‘Options’. When the ‘Options’ window pops up, select the ‘Expert Advisors’ tab and select the first checkbox – ‘Allow automated trading’.

Another way to allow automated trading is by selecting the ‘AutoTrading’ button on the toolbar.

When the button has a green icon, that shows that automated trading is allowed and when it’s red, automated trading is not allowed. This button can be a quick shortcut for allowing the EA to initiate trades when you’re stepping away for a while, but it doesn’t offer control over other parameters.

In the ‘Expert Advisors’ tab, there are subsequent options that dictate other privileges you can grant to the EA, these are:

  • checkbox 2 – leaving this box unchecked will keep the EA running even after you have switched accounts on the ‘Navigator’ window. You may need to switch accounts from, say, a demo account to a real account, so you should choose whether you want the EA to run on all accounts
  • checkbox 3 – all the changes you make to your charts such as colors, timeframe, and even expert advisors are stored in a profile. This profile is then resumed every time you restart MT4. When you change, say, the template, this is like switching to another profile. You may need to change templates if you are using a new indicator, and you should also decide if you want to keep the EA running even when you do so
  • checkbox 4 – whenever you change the timeframe or drag another symbol onto the same chart, you can keep the EA running or disable it. By default, this option is left unchecked because the EA should not prevent you from going on with your analysis of the Forex charts online
  • checkbox 5 – some EAs require to use of DLLs (dynamic-links libraries) to perform added functions. This means sending and receiving information, which, as the MT4 platform warns, can be potentially dangerous. A malicious creator of an EA could perhaps use this function to acquire personal details about your trading account, so you should be careful about your source for the EA before enabling this function. To learn more about trading accounts, you can check our Alpari Trading accounts comparison.
  • checkbox 6 – if an EA depends on sending and receiving signals to and from certain websites, then you should specify the particular websites

After performing the steps above, MT4 is ready to start running an expert advisor, but you will still need to go through a few more steps.

Find an expert advisor

If you’ve come this far then you have already likely found an expert advisor, probably online. If you haven’t found a good source yet, the perfect source is the MQL5 website which contains plenty of resources for both the MT4 and MT5 platforms (Comparing MetaTrader 4 and 5: MT4 vs. MT5).

You will also find some more EAs in our Forex strategies category of articles that provide useful and effective trading strategies. Expert advisors will have a ‘*.mq4’ extension, which is the same language as the MQL4 language the MT4 platform itself is coded.

Download the EA file on your computer and then right-click>copy the file. Next, go back to your MT4 platform, select the ‘File’ menu, and click on ‘Open data folder’. This will open the window where all your MT4 platform files are saved on your computer. If you’re using different Forex brokers, their individual MT4 platforms will have separate data folders, even though the MT4 platform remains largely the same. Check out our Admiral Broker in-depth review for more brokers. 

Therefore, every broker’s MT4 platform will be slightly different to accommodate their specialized services and offerings. For example, some good CFD trading Forex brokers will include CFDs like futures into their MT4 platform, while some top-rated binary options brokers will also integrate their services onto their platform. To avoid any conflicts, all MT4 platforms get a separate data folder which will only affect that MT4 platform.

It is important to keep this in mind so that you don’t get frustrated that some of the MT4 platforms you have installed don’t show the expert advisor you just downloaded. This is why I’m showing you how to access the data folder of the particular MT4 platform where you would like to launch the EA – through the steps above.

Now, after the data folder is open and the EA file is still copied onto your computer’s clipboard, go to ‘MQL4’ then ‘Experts’ and right-click>paste into that folder. Go back to the MT4 platform and move the arrow to a blank area within the ‘Navigator’ window, then right-click>Refresh. This will reload all the indicators, EAs, scripts, etc. on the data folder and your EA should appear there after the loading is complete. The other option would be to close and restart the MT4 platform, but you don’t have to unless the process is taking too much time.

Activating the expert advisor

Expert advisors will be toward the bottom of the ‘Navigator’ window, in an expandable menu, and all the installed EAs will appear there. By default, MT4 will have 2 pre-installed EAs, the MACD sample, and the moving average, which we’ll be testing in this tutorial. To activate one of the EAs, double-click on it or click and drag it onto the trading window. This will lead to the EA’s setup window popping out, and the tabs will let you set your preferences.

This ‘Common’ tab is standard for all EAs, and it lets you determine the situations in which the particular EA will be active. The first drop-down menu is a simple choice, determining whether you would like the EA to initiate short positions, long positions, or both. This decision will depend on your trading strategy and whether you already have too many similar positions (How to choose a trading strategy?). For example, if you have too many long positions, you may want the EA to only trigger short positions so that you can hedge against risk.

Next, you decide whether you want an alert whenever the EA initializes a trade, and whether it should stop issuing the alert later. You also get to choose whether you want the EA to be active on live account trades, and whether to allow DLL imports. We already looked at how you could allow DLLs for EAs in the first step, but if you had left that option unchecked, selecting it here will allow DLL imports for the particular EA you’re configuring.

Then you can either allow or restrict the EA from using functions from other external experts and whether you would like the EA to subscribe to signals. Some EA developers will also have trading signals, which their EAs will often subscribe to by default, this option gives you control over that too. Nevertheless, you can still subscribe to your trading signal, but it would be your choice. (How to find reliable trading signals)

The following tab will vary from one EA to the next depending on the developer’s conditions, so it’s not possible to tell you what to do here. The best thing to do is to check with the developer. If you downloaded the EA from a legitimate developer, they will have provided information about their EA, which would help you decide on what to do here:

In the case of the above MACD Sample EA, you can select the lot sizes, take the profit level, and trailing stop level, and make changes to the EA’s parameters. Other EAs will have different inputs, but it’s always best to leave things the way they are by default unless you know what you are doing.

When you click ‘OK’, the EA should now be launched and attached to the chart. To confirm whether it’s active, there should be a ‘smiley face’ icon next to it at the top-right corner of the chart. To make further changes or remove it, right-click anywhere on the chart, move down to ‘Expert advisors’, and choose the option you want.

 For more top brokers, make sure to check out our Exness review and Admiral Markets review.

That’s it! You have now launched an expert advisor on MT4 and it’s ready to function. For more on EAs – how to test them and set parameters, here’s a quick video:

Table of contents