Logo

    Installation

    Step 1: Download MetaSocket

    Step 2: Install in your MetaTrader5 terminal

    Open your Metatrader application and go to File → Open Data Folder.

    Open data folder

    Navigate to MQL5 → Experts.

    Navigate to MQL5-Experts

    Copy and paste the MetaSocket .EX5 file you downloaded to this folder.

    Copy and paste MetaSocket

    Restart MetaTrader5 terminal. Then double-click MetaSocket found under the Navigator tab of your terminal.

    Alternatively, you can also drag MetaSocket to your open window chart.

    Restart MetaTrader5 terminal

    Make sure that the Allow DLL imports is checked and the Algo Trading button in the menu bar is enabled.

    Allow DLL and Algo Trading

    MetaSocket uses port 8777 as its default command port, and port 8778 as the incoming data stream port.

    You may choose any port of your choice by entering desired values.

    MetaSocket port inputs
    Important

    You might have to allow the ports in your firewall to enable incoming traffic.

    Step 3: Verify if MetaSocket is running

    Finally, under the Experts tab of the terminal, verify if MetaSocket is running.

    Verify if MetaSocket is running

    Optional Step: Test using Telnet

    After installation, you can test using Telnet. You can download PuTTY and run it in Telnet mode.

    PuTTY running in telnet mode port 8777
    Tip

    You can also open another Telnet terminal to test the incoming data streams.

    PuTTY running in telnet mode port 8778

    Illustration below shows two (2) terminal window running a TRACK_OHLC command that receives incoming stream data in the second terminal.

    Two PuTTY terminal running in telnet mode port 8777 and 8778