I have noticed that many Forex traders do not know that MetaTrader 4 trading terminal can’t run two Expert Advisors on the same chart. This limitation comes from MT4 terminal itself, which simply means you are not allowed to attach multiple EAs on the same chart window. So how do others run several EAs on the same MT4 terminal? Actually, it’s quite simple to run many Forex robots on the same MetaTrader 4 terminal. You just open new chart window for each EA you want to run.
This article will clear up any doubts about this subject and will make your Forex trading easier when using Expert Advisors.
MetaTrader 4 is designed so that only a single Forex robot (EA) or script can be attached to a single chart. However, MT4 allows to run up to 128 EAs on the same trading terminal. You just need to open multiple chart windows. This allows you to run many Expert Advisors by attaching each of them to a different chart.
You can have multiple charts of the same currency pair and time frame and run a robot on each of them. You can also have multiple charts of different currency pairs and time frames and even any other trading instrument your broker has to offer. Basically, any combination would work.
Below is the screen of my MT4 with multiple charts of different instruments and time frames.
Important to note that with indicators this is different. You can attach multiple indicators to any single chart.
Running the same EA on multiple charts
Let’s discuss an example. We want to run the same Expert Advisor on 4 different instruments. To do this we simply open 4 chart windows and attach EA to each of them. This is as easy as it sounds.
When you run the same EA on multiple charts they may conflict with each other, it all depends on the EA and how it’s programmed.
For example, if EA was not designed for multiple charts it may think that the trades on EURUSD belong to it while actually, EA is running on USDCHF or another pair. When EA on USDCHF gets a signal to close its trades you may be surprised that EA will close all of the trades you have running on an MT4 account, including manually opened trades and trades from other EAs.
If you see such discrepancies you should contact EA developer for help.
Remember, that well programmed EA should not interfere with the trades from other EAs or even the same EA running on another instrument.
Running two different EAs on the same instrument
Now what if you want to run two different EAs on the same instrument, for example, EURUSD?
To do this you simply need to open two chart windows for the EURUSD pair, and you will then be able to attach both MT4 robots. To be exact, the first Forex EA should be attached to the first EURUSD chart and the second EA should be attached to the second EURUSD chart.
However, keep in mind that EURUSD trades opened on the 1st EURUSD chart will also be visible on each other EURUSD chart on the same MT4 account. Even if those charts are of different time frames but have the same instrument, they will all display EURUSD trades.
This means that 1st EA will be able to access the trades generated by the 2nd EA and the 2nd EA will be able to access the trades generated by the 1st EA. So how do each EA know which trades belong to itself and which ones came from other EAs?
For each EA to be able to identify its trades a special ID is used, which is called Magic Number. Each trade has a Magic Number and it’s here for just one reason – to make it easy for each EA to detect its own trades.
So when you will be running multiple EAs on the same MT4 account you should always have different Magic Number for each EA instance. Even if it’s the same EA on two or more instruments, you should always have different Magic Number set for each EA instance.
There’s a way to use the same Magic Number if you’re running each EA instance on different instruments, but for this to work properly you should understand what you are doing. Basically, you need to be sure that your EA is designed in such a way that it can handle trading using the same Magic Number on different instruments.
For example, Stealth EA can run on a single chart of any pair and it will apply hidden stop loss and take profit on all of the trades running on the MT4 account. EA has special settings allowing you to set it to operate on a single pair while managing trades of any instrument. But I must say not all EAs are created that way and you should know how your EA operates before using it on your MT4 account.
It is important to know how each of your EAs work if there are multiple instances of the same EA or even multiple instances of other EAs. If EA is coded incorrectly it may conflict with the other instances of the same or other EAs. You should check if the EA uses Magic Number to detect the right trades and to avoid confusing them with the trades from other EA instances, 3rd party robots or manually opened trades.
Installing many EA on the same MT4 terminal
Installing many EAs is literally the same as installing a single EA. The Expert Advisor file (.ex4 or .mq4) should be copied into the \MQL4\Experts\ folder which is located in side “Data Folder” of your MT4 trading terminal.
“Data Folder” can be opened from your MT4 platform by going to “File -> Open Data Folder“.
You can have an unlimited number of EAs installed on any MT4, but note that only 128 EAs can be actively running on 128 chart windows in the same MT4 terminal.
And if you have many EAs running on the same account here’s a good article I wrote some time ago about how to analyze over 100 trading strategies on a single MT4 account.
The important thing to mention is that each EA you install into MT4 might need custom indicators to work properly. It’s not that each EA is designed to work with custom indicators, but you should always know what other files must be installed together with each of your EAs.
If you run EA that uses custom indicator and it does not exist on your MT4 terminal, the EA will fail to work properly. The tricky part is that EAs usually do not give you any alerts if required indicator files are missing, but you should find an error message generated in the EXPERTS tab at the bottom of MT4 window. However, it can take hours or even days before EA gets an entry signal and prints error message after it fails to load the required indicator.
Why run many Forex robots on the same MT4 terminal?
One of the reasons to run many Forex robots on the same MT4 is that this way you can test many automated strategies at the same time and without the need to run many MT4 terminals.
MT4 allows running 100 Expert Advisors. This means instead of running 100 MT4 terminals with just one Forex robot attached inside you can have one MT4 terminal with 100 robots.
We teach this technique in Forex Robot Academy and it’s the main reason why I found success in automated Forex trading.
Another good reason to run more than one Expert Advisor on MT4 is to copy its trades to other MT4 accounts. This can be done using the Local Trade Copier software. You simply run your EA on one chart and the Server EA from Local Trade Copier on another chart. The Server EA will detect any trading actions and send them to other MT4 accounts where LTC Client EA is running and repeat them accordingly. This way you can copy all trades from one MT4 to other MT4 accounts automatically non-stop.
SO now you know that you can have many EAs running on an MT4 terminal. But before you run multiple EAs on the same MT4 account I highly recommend you to read the instructional manual of each EA you are going to use. I would even say it’s mandatory to read instruction manual so that you learn about EA requirements and limitations.
If that doesn’t tell you anything you may want to contact EA developer and simply ask if this EA can work together with other Expert Advisors on the same MT4 account.
You should find out if the EA uses a Magic Number to identify its own trades and if EA checks to see if it is managing only the trades from the same instrument that it is attached to.
So tell me, how many EAs you are running on the same MT4 account?