Run MetaTrader as a Windows Service with AlwaysUp

How to Run MetaTrader 4 (MT4) as a Windows Service with AlwaysUp

Ensure that all your MetaTrader 4 instances start after a reboot and run 24/7!

MetaTrader 4 is a leading automated trading system developed by MetaQuotes Software Corp.

To set up MetaTrader 4 with AlwaysUp:

  1. Download and install AlwaysUp, if necessary.

  2. Download and install MT4, if necessary. Please make a note of your installation folder; it will be used in a later step.

  3. Start AlwaysUp.

  4. From the menu, select Application > Add to open the Add Application window:

    Add Application

  5. On the General tab:

    • In the Application field, enter the full path to the MetaTrader .exe file. If you installed MetaTrader in the default location, this is
      C:\Program Files\MetaTrader 4\terminal.exe.

    • In the Name field, enter the name that you will call this application in AlwaysUp. We suggest MetaTrader but you can specify almost anything you like.

    MetaTrader Windows Service: General Tab

  6. Move to the Logon tab and enter the user name and password of the Windows account in which you installed and use MetaTrader. AlwaysUp will run MetaTrader in this account so that it can find its settings.

    If you wish to hide MetaTrader's windows, check the When a user logs on, don't show the application's windows and tray icons (if any) box at the bottom.

    MetaTrader Windows Service: LogOn Tab

  7. Click over to the Restart tab and check the Whenever it "hangs" for longer than box and leave the default value at 1 minute. Unfortunately MetaTrader can occasionally hang and this will instruct AlwaysUp to restart it if that happens.

    MetaTrader Windows Service: Monitor Tab

  8. Move to the Startup tab and check the Ensure that the Windows Networking components have started box. This informs AlwaysUp that MetaTrader needs the TCP/IP networking stack to work.

    MetaTrader Windows Service: Startup Tab

  9. Click the Save button. In a couple of seconds, an application called MetaTrader will show up in the AlwaysUp window. It is not yet running though.

    MetaTrader Windows Service: Created

  10. To start MetaTrader, choose Application > Start "MetaTrader".

    MetaTrader is now running (on Session 0) but depending on the version of Windows you are using MT4 may or may not be visible to you. If it is not visible, you have a couple of options to see it:

    1. On Windows 7, Server 2008 or Vista, select Tools > Switch to Session 0 and AlwaysUp will take you to the desktop where MT4 is running. (More on this in the AlwaysUp FAQ.)

      MetaTrader Windows Service: Running in Session 0

    2. On Windows XP and 2003, you can RDP to Session 0 by running mstsc /admin.
    3. Choose Application > Restart "MetaTrader" in this Session. This will temporarily stop MetaTrader and restart it on your current desktop:

      MetaTrader Windows Service: Running

  11. That's it! Next time your computer boots, MT4 will start up immediately, before anyone logs on. We encourage you to edit your MetaTrader application in AlwaysUp and check out the other settings that may be appropriate for your environment. For example, you may want to restart MT4 in the wee hours, just to clear out any memory leaks...

    Repeat the process to set up as many Metatrader instances (each in its own directory) as you need... there is no limit with AlwaysUp!



MetaTrader 4 not working properly as a Windows Service?

  • From AlwaysUp, select Application > Report Activity > Today... to bring up a HTML report detailing the interaction between AlwaysUp and your application. The AlwaysUp Event Log Messages page explains the more obscure messages.
  • Now that AlwaysUp is managing MT4, please make sure to avoid running multiple instances of the same terminal. Don't start MT4 manually or place a shortcut in the Startup folder.
  • Consult the AlwaysUp FAQ for answers to commonly asked questions and troubleshooting tips.
  • Contact us and we will be happy to help!

Download & Try it Free!

Download AlwaysUp and Run as a Service Today! Version 14.5 New!

8.1 MB Installer
  • Unrestricted 30-day trial for new users; upgrade for existing users
  • For Windows 11/10 and Windows Server 2022/2019/2016/2012
  • How to Install
  • License (EULA)
Our 12,000+ customers include...
Compatible with Windows 11 Compatible with Windows Server 2022 Compatible with Windows 10 Windows Server 2012 Certified (32 & 64-bit)
Over 94,000 installations, and counting!
 
AlwaysUp is number 1! Run as a Service with AlwaysUp

Rock-solid for the past 18+ years!