Improve MT4 Trade Copier speed on multi-core CPU machines

Improve MT4 trade copier speed blog post title

In this blog post I’ll show you how to improve MT4 performance and how to make sure your Expert Advisors and indicators are not suffering from unnecessary delays.

This literally allows you to speed up MT4 software when it is used on multi-core processor VPS servers. In this example I will use one of my MT4 apps to demonstrate how to identify this problem and how to fix this, but you might experience the same problem with any other MT4 app in general.

Recently I have been receiving quite a lot of emails where people complaint that my Local Trade Copier software is working very slowly. Results have been quite different for most of those trade copier users, but on average they have experienced somewhere between 10 to 60 second delay when copying trades. That is huge and not tolerable and should be fixed.

However, what I’ve found out is that everything is okay with my software and the problem comes from the MT4 platform when it runs on a multi-core CPU Virtual Private Server (VPS).

Do not get confused. Even if your hosting provider says that your VPS server has 1x CPU (processor) which has 4x cores, you will still experience MT4 performance problems. Yes those CPU cores are virtual, they are not real, but that’s actually is the problem. If they were real MT4 would work fine. So it does not matter if your VPS has 1x CPU with multiple cores or multiple CPUs, you need to use special configuration to make your MT4 work efficiently.

So it is actually wise to chose VPS servers with just one single CPU and if you need more you can always rent additional VPS server. Or, you can rent a dedicated server which does not have these problems and you can usually run dozens of MT4 instances on multi-core CPU platforms.

Normally the trade copier software should synchronize trades every 400 milliseconds, which is basically 2 times every second, and you can adjust the sync rate to make it work even faster. I’ve had this “slow copier” problem as well in the past so I want to share with you how to solve this problem.

This “slow MT4” problem is quite well known to programmers and there are lots of discussions about MT4 and multi-core processors. However, I do not want to throw technical terms and explanation at you. I just want to show you how to solve the problem when your MT4 is running slowly.

And even if your MT4 does not seem to run slowly, by applying this trick you might even be able to run more MT4 client terminals on the same VPS server.

Technically, the problem is that MT4 is a 32-bit application and this gives trouble to work efficiently on multi-core processor VPS (like Dual-core, Quad-core, etc).

This problem appears when you are running multiple MT4 client terminals on the same VPS server and this server has multi-core CPU. Usually, the multi-core CPU on a VPS server is a “virtual CPU”, which means those CPU cores are not real physical CPU’s. They are virtual CPU cores. We just call it “virtualization”.

If you are running a single MT4 instance you should not face problems like this. This should not be a problem as well if you are running multiple MT4 instances on the VPS server that has only single CPU. If you are running some simple MT4 app like this Partial Close EA then you might not face these problems as well.

But if your VPS server has more than one CPU and you are running more than one MT4 platform you will definitely see delay in trade execution and other software operations.

How many CPU cores your VPS server has?

Here’s how to know how many CPU cores your VPS server has.

Click the right-mouse button somewhere on the task-bar at the bottom of your Windows screen and in the pop-up menu choose “Start Task Manager“.

You can start Task Manager in Windows VPS server from this pop-up menu.

You can start Task Manager in Windows VPS server from this pop-up menu.

When the “Task Manager” window loads up you need to switch to the “Performance” tab where you’ll see if you have multiple CPU cores or not.

Performance tab with 4x CPU cores in the Windows Task Manager.

Performance tab with 4x CPU cores in the Windows Task Manager.

In the picture above you can see this VPS server has 4x CPU cores.

The specifications of this VPS server are as follows:

  • AMD Opteron(tm) Processor 6136 (4 CPUs) ~2.4Ghz.
  • 8GB RAM Memory.
  • VPS system runs on a VMWare Virtual Platform.

If you switch to the “Processes” tab, you’ll find terminal.exe‘s in the process list. This is your MT4 processes and what you need to do is to set each of them to use the same CPU core.

By default each process use all CPU cores and in our case this creates a problem for MT4.

MT4 terminal.exe process list in the Windows Task Manager.

MT4 terminal.exe process list in the Windows Task Manager.

To make this process more simple I suggest to sort that “Process” list by name by clicking on the column that says “Image Name“.

In this Task Manager process list we see that there are 4x MT4 instances running. Each of those MT4 platforms run several MT4 Copier EA instances which makes a total of 9x EA’s running on this VPS.

CPU Usage in the picture above is shown as 19% but it is actually jumping between 19% and 36% all the time. At a first glance anyone might say that CPU load of 36% or even 60% is not a big deal and VPS should work fine, however this “CPU Usage” number seems to be incorrect in such case.

The whole VPS system is working very slowly and it is even difficult to switch between windows. If I try to switch to another MT4 platform window I have to wait about 20-60 seconds. Obviously trade copying on such server would take ages and you would experience huge delays and price differences. I even had the same problem with only 2x MT4 instances and only two copier EA’s (Server EA and Client EA).

Simple trick to make MT4 run faster on multi-core CPU servers

Now here’s a simple trick you need to apply to make MT4 client terminals (and of course all apps running inside these terminals) work faster. There are two options.

For some, option #1 helps speed up MT4, while others find only option #2 is actually helping.

Option #1: Set all terminal.exe processes to use the same CPU core.

To apply option #1 you need to set all terminal.exe processes to use the same CPU. It does not really matter which CPU core you’ll choose to use, what’s important is that all MT4 processes should use the same.

To make it simple I always set all terminal.exe‘s to use CPU0. This way MT4 will not need to split operations between multiple CPU’s and it will work faster.

It’s really easy to do and I will explain how it’s done a bit later, so keep reading.

IMPORTANT! If you leave one terminal.exe process using more than one CPU this trick will not work. It’s very important to have all terminal.exe‘s to use the same and only one CPU.

Option #2: Set each terminal.exe process to use different CPU core.

If option #1 does not help you should also try option #2. To apply option #2 you need to set each terminal.exe process to use different CPU core. Say your VPS has 4x CPU cores and you run 4x MT4 instances. Then all 4x MT4 instances should be set as follows:

  • MT4 instance #1 should use CPU0
  • MT4 instance #2 should use CPU1
  • MT4 instance #3 should use CPU2
  • MT4 instance #4 should use CPU3

If you have more MT4 platforms than you have CPU cores, you should close the rest of MT4 instances (at least for testing purposes) to see if this option #2 solution helps you at all.

How to set MT4 to use certain CPU core

Configuring MT4, or any other process from the list, to use only certain processor is quite easy. You need to switch to the “Processes” tab, choose the terminal.exe process from the list, click the right-mouse button on that item and choose “Set Affinity” from the pop-up menu.

In the “Processor Affinity” window you need to deselect all CPU cores and select only CPU0 like in the picture below.

Setting CPU affinity on MT4 terminal process in the Windows Task Manager.

Setting CPU affinity on MT4 terminal process in the Windows Task Manager. This makes the MT4 platform to work only using single CPU core for faster performance.

When I did this for all 4x MT4 instances I am running on my VPS all of them started to work efficiently. I can now switch between windows easily and CPU Usage dropped as well to 16% – 29% (even though I still think this number does not show correct values on VPS servers).

Obviously I can copy trades at the fastest speed possible. Trades are transferred between MT4 platform in under 1 second now.

MT4 Trade Copier speed is just one piece of the puzzle

I would mention that Local Trade Copier’s speed has little to do with how fast your trades are copied between MT4 platforms. In most cases delays come from the problems like slow MT4 (like in this example), poor internet connection or even execution delays from your broker. There were even cases when brokers delay trade execution on purpose for some economic news scalpers/traders.

To list all potential problems that affect trade copying speed I would list them in the following order (where 1st item is the most common problem and the last item is the least common problem):

  1. Slow MT4 performance because of the multi-core CPU VPS server.
  2. Too many MT4 client terminals running on the same VPS server.
  3. Slow MT4 performance because of too many 3rd party indicators or Expert Advisors running on the MT4 terminal.
  4. Slow VPS performance because of 3rd party software (anti-virus, firewall, Internet browsers and other apps).
  5. Poor internet connection. I know all VPS providers will say that their connection is high quality, but even world class services have issues from time to time. Keep this in mind. On the other hand, it’s not necessary your server provider is the one to blame for bad Internet connection. There can be several or even dozen of servers/gateways in between your VPS and your broker’s server.
  6. Your MT4 app problem.

I won’t deny that my MT4 apps or MT4 copier might have problems running on your MT4 or your VPS. This have happened in the past and I did a lot of work to fix this. However, based on the last few years and tens of solved “slow trade copying” cases I’ve noticed that it’s always MT4, VPS or Internet connection problem. When you finally fix the problem with the trade copying speed you can even try to copy your Forex trades at a better price.

How to know if your LTC copier is slow

So how to know if it’s the Local Trade Copier working slow and does not copy trades fast enough or is it that the problem lies in the slow execution from your broker?

That’s quite simple. Both, Server EA and Client EA has special counters in the blue dashboard that are growing on each synchronization cycle. Server EA has “Server send” counter and Client EA has “Server read” counter.

Server send counter in the blue dashboard of the LTC Server EA.

“Server send” counter in the blue dashboard of the LTC Server EA.

If counters on all LTC EA instances are growing steadily, consistently and rapidly (according to your SyncRate setting in the EA Inputs), then it looks like your copier is working fine. If you see one of those counters growing slow and randomly, you should apply option #1 and/or option #2 solutions explained earlier in this article.

If counters on all LTC EA’s are growing steadily and consistently, but trades are still copied slowly, then you should also check the execution time. After each copied trade Client EA will print information in the “Experts” tab at the bottom of MT4 client terminal about the trade execution speed, price deviation and slippage.

Local Trade Copier reports broker execution speed on copied trades.

Local Trade Copier reports broker execution speed on copied trades.

In the picture above you can see Client EA reported that it took 203ms to execute the trade. This obviously does not include the synchronization time (the time required for the copier to actually send the signal from master to the client account).

These 203ms is the time spent to deliver the “open trade” request to the broker’s server, actually get the trade executed and receive a confirmation answer from the broker’s server.

In other words, this is out of control for the trade copier software or any other MT4 app. This depends on how fast your Internet connection is and how fast your broker’s execution speed is.

Under normal conditions you should get execution delay somewhere between 50-300 ms. If you want to get this close to 1ms, or something like that, you should rent a VPS server which is on the same network as your broker’s server. You can contact your broker to find out such information.

For example, there’s only about 35ms latency between one of HotForex Data Centers and network. And if you want even better latency you can rent a VPS server located in Netherlands. This company have a network there too.

Local Trade Copier reports price deviation and slippage on copied trades.

Local Trade Copier reports price deviation and slippage on copied trades.

In the picture above we also see that the copier reported actual price deviation on the copied trade comparing it to the original trade’s open price.

In this case there was a price difference of 0.6 pips which is considered very low under such circumstances.

This report also included slippage which was zero in this case. Slippage is something you cannot avoid, but first thing what you need to find out is whether the slippage you get is the result of a bad Internet connection or it’s your VPS server running slowly.

Trade copier speed troubleshooting checklist

  1. After each trade is copied there will be a message logged in the “Experts” tab which gives the exact slippage and delay in ms. This way you can know if delay is coming from the broker/internet connection. If you get execution delay between 50ms and 300ms then your Internet connection and broker is working fine.
  2. Check if “Server read” and “Server send” counters are growing steadily or randomly. If one of these counters grow randomly, with delays, then it means your computer is slowing down the trade copier software.
  3. Check if your VPS server has multiple CPU or just a single CPU. If you have a single CPU then try closing 3rd party applications and remove other EAs and indicators from your MT4 to make it work faster. If this does not help then maybe you are running too many MT4 instances and/or simply need to get a better and more powerful computer.
  4. If your VPS server has multiple CPU cores then you might suffer from the well known MT4 issue that it cannot work efficiently on multiple CPU core machines. In that case you would have to set all terminal.exe’s to use the same CPU. This can be done from the “Processes” tab in the “Task Manager” window. You need to select each terminal.exe and choose “Set Affinity“. Then in the CPU list window you need to select which CPU’s each process should use. Idea here is to try two operational modes: 1) Set all terminal.exe’s to use the same CPU0; 2) Set each terminal.exe to use different CPU.

If you have tried all that above and still have slow trade copying speed you should contact me.


If your MT4 is running slowly and your VPS server provider tells you that everything is okay on their side, you should check if your VPS is a multi-core CPU machine. MT4 cannot work efficiently on multi-core CPU VPS servers and requires some additional configuration.

I hope that this article have helped you find the cause of your slow MT4 problem and possibly fix it.

So, have you suffered from this problem before? Or maybe you are still struggling to find a solution to this? If you tried all that, did it helped? Please post your comments below.

About Rimantas Petrauskas

I am the creator of the Local Trade Copier program and a professional developer of Forex trading signal delivery software for MetaTrader 4 client terminal. Also I am into 100% automated currency trading that generates profits while I enjoy the time with my family, our life and traveling.


  • Torsten Kroeger says:

    Hi Rimantas,
    thank’s a lot for your email!
    Eventually I have just solved my main headache with the VPS, after I read your above text. Your explanations were very easy to understand and to follow the executions. To tell you this, I run 13 Terminals on one VPS with 3-4 LTC’s (clients) on each of 4 terminals and on the other 9 terminals there are 9 Server EA’s. Man, to change/save something or even to switch from one terminal to the next it is so slow. Now I have followed your recommendation 1 and switched all terminals on one CPU. This system has just 2 CPU’s. If you go on the VPS website You notice the performance of my Server i selected.

    Anyway, what i haven’t figured is to shift all apps on to my computer to upgrade to Windows Server 2008. I am (VPS) still running on Windows 2003. The support has told me that this upgrade is not a problem at all. I have to be aware that all my datas get lost when they would do this job. I don’t know how to do this shift.

    Okay, may be in a quiet moment you can tell me if this upgrade is necessary or if this VPS service doesn’t seem to be trustworthy for you. The price is quite reasonable.

    Best regards,

    • Dear Torsten, first of all thank you for your comment. I am really glad my suggestion have helped you solve the problem.
      Your VPS price looks quite reasonable. I do not have experience with this company, but if it works great for you then obviously I suggest you keep staying with them.
      As about the upgrade from 2003 to 2008, personally I would go for it. I am happy I made the same decision on my VPS servers last year.
      I would just suggest you to save all MT4 Profiles into file and also save all passwords into file. You should backup that data, because after re-installation that might get lost so you will have to restore it.

      Hope this helps.

      Rimantas Petrauskas

      • raj says:


        I am getting error saying “cannot open file” followed by the path pointing to the indicator that i have attached with few EAs.

        I am able to attach this indicator to the chart separately and it is working fine.

        This problem just started 2 days back until then it was working fine and there was no error message.
        I have compiled the indicator few times but still the problem persist.

        another problem is that another message shows “no data available” for another indicator which I have attached to few EA as well. I am using VPS for running MT4.

        Kindly reply.


    • Stephen says:

      Hi Rimantas,

      We have signed up with MyForexVPS VPS XPERT and are trying to run 10 terminals but things have started to slow down, even with CPU affinity setting in place.

      What are we doing wrong?


      • Hi,

        I would recommend to take 1-CPU VPS servers and if you need take multiple of them rather than take one VPS with multiple CPU cores. MT4 does not work well with multiple CPU core VPS servers.
        On the other hand, if you can rent a dedicated server, then it can have multiple CPU cores and that will work fine, because it’s dedicated server.

        1-CPU core VPS server normally can run about 5x MT4 platforms max (depends on sever specifications), but if it had multiple cores it just makes everything slow.

  • Torsten Kroeger says:

    I have forgot to mention which VPS: it’s the XPERT version I use. It’s up to 25 terminals.


  • Conway says:

    Fantastic find Rimantas!

    Thanks for sharing your findings and knowledge on this.

    I am just about to load a second platform to one of my NY VPS and was considering upgrading to another core, I may still have to but your suggestions are well received.

  • Michael says:

    Hi,Do you develop copier programme from Mt4 client to fxinside?

  • anjum says:

    I daily read u r mail.Its good & very helpful knowledge to me & other new investor.
    keep on doing.
    thank sir

  • syed anjum jafri says:

    i closely read all the details.thanks for this knowledge.its really strange no one bothered to tell all these things before. i will do the needful and revert back to you for any help if any problem arises.
    thanks rimantas.

  • Jilles says:

    Hi, I had a lot of troubles with my VPS. First I used 2 Cores. When I tried working with 7 Terminals I got problems so I was thinking 2 more Cores will do better! The opposite was true, unbelievable slow, much and much slower than it was before. Lots of discussions with people from the VPS company. Finally I removed the 2 extra Cores and it was like before, not bad but I want to have it a little bit better. I switched all my 4 Terminals to CPU0 as you told me to do and the speed, especially when I switch from Terminal to Terminal with the charts increases a lot! I am going to install a few more Terminals now.

    Thank you very much my friend!

    Regards from Holland,

  • Muhammad Farrukh says:


    I have been a victim of this issue since last 5 year and I have checked all the available solutions on google which are around clearing the history and download this and that. This is the most effective solution to speed up your meta trader 4.

    Thanks for sharing the solution and I really appreciate that.



  • n says:


    Thank you for the article.
    I tried the first option on on my local computer i7 6700k with 8 MT4 terminals and the CPU process reduced to half but then each of the MT4 runs slow.The second option didn’t change anything..
    If the affinity is set to all,each MT4 uses 10-20% CPU when aggressive time.Which is too much and if over 80% it starts to jump.

  • Graham says:

    hey Rimantas I have a problem to solve when I run 2 metatraders I get constant disconnections on 1 or the other and I have very good internet connection

Leave a Reply