Native Websocket

5

An easy to use, fast, asynchronous WebSocket library for MQL5.

It supports:

  • ws:// and wss:// (Secure "TLS" WebSocket)
  • text and binary data

It handles:

  • fragmented message automatically (large data transfer)
  • ping-pong frames automatically (keep-alive handshake)

Benefits:

  • No DLL required.
  • No OpenSSL installation required.
  • Up to 128 Web Socket Connections from a single program.
  • Various Log Levels for error tracing
  • Can be synchronized to MQL5 Virtual Hosting.
  • Completely native to MQL5.

Click here to Download the latest WSMQL.mqh
Please ensure the MetaTrader downloaded library is downloaded/named as Native Websocket.ex5 as required by WSMQL.mqh

You can always contact me for custom pricing/requests/support/questions

Whatsapp

Sample code below:

//include WSMQL.mqh - a file that has all the declarations required to interact with the library
#include <WSMQL.mqh>
// Methods below
// class CWebSocketClient {
// public:
//    bool Initialized(void); // Checks if the WebSocket client is initialized.
//    ENUM_WEBSOCKET_STATE State(void); // Returns the current state of the WebSocket connection.
//    void SetMaxSendSize(int max_send_size); // Sets the maximum send size for WebSocket messages.

//    bool SetOnMessageHandler(OnWebsocketMessage callback); // Sets the callback function for handling incoming text messages.
//    bool SetOnPingHandler(OnWebsocketMessage callback); // Sets the callback function for handling incoming ping messages.
//    bool SetOnPongHandler(OnWebsocketMessage callback); // Sets the callback function for handling incoming pong messages.
//    bool SetOnCloseHandler(OnWebsocketMessage callback); // Sets the callback function for handling WebSocket connection closures.
//    bool SetOnBinaryMessageHandler(OnWebsocketBinaryMessage callback); // Sets the callback function for handling incoming binary messages.

//    bool Connect(const string url, const uint port = 443, const uint timeout = 5000, bool use_tls = true, ENUM_LOG_LEVEL log_level = LOG_LEVEL_NONE); // Connects to a WebSocket server.
//    bool ConnectUnsecured(const string url, const uint port = 80, const uint timeout = 5000, ENUM_LOG_LEVEL log_level = LOG_LEVEL_NONE); // Connects to a WebSocket server using an unsecured connection.
//    bool ConnectSecured(const string url, const uint port = 443, const uint timeout = 5000, ENUM_LOG_LEVEL log_level = LOG_LEVEL_NONE); // Connects to a WebSocket server using a secured connection.

//    bool Disconnect(ENUM_CLOSE_CODE close_code = NORMAL_CLOSE, const string msg = ""); // Disconnects from the WebSocket server.
//    int  SendString(const string message); // Sends a string message to the WebSocket server.
//    int  SendData(uchar& message_buffer[]); // Sends binary data to the WebSocket server.
//    int  SendPong(const string msg = ""); // Sends a pong message to the WebSocket server.
//    int  SendPing(const string msg); // Sends a ping message to the WebSocket server.
//    uint ReadString(string& out); // Reads a string message from the WebSocket server.
//    uint ReadStrings(string& out[]); // Reads multiple string messages from the WebSocket server.
//    uint OnReceiveString(); // Receives and processes incoming string messages.
//    uint OnReceiveBinary(); // Receives and processes incoming binary messages.
//    uint OnMessage(); // Receives and processes incoming WebSocket messages.
// };
// Create an instance of the Client
CWebSocketClient client;//I declared this globally because of OnPingMessage requiring it
//+------------------------------------------------------------------+
//| Script program start function                                    |
//+------------------------------------------------------------------+
void OnStart() {
   // Check if the client is initialized
   if (!client.Initialized()) {
      ZeroHandle();//Cleanup all clients
      return;
   }

   // Set OnMessage handler to receive text messages
   client.SetOnMessageHandler(OnMessage);// use SetOnBinaryMessageHandler for binary messages

   // Set OnPing handler to receive ping messages, 
   // Pong will be automatically sent if this handler is not set
   client.SetOnPingHandler(OnPingMessage);// use SetOnPongHandler for pong messages

   // URL and msg declaration
   string url = "stream.binance.com/ws";//Or wss://stream.binance.com/ws
   string msg = "{\"params\":[\"btcusdt@bookTicker\"],\"method\":\"SUBSCRIBE\",\"id\":27175}";
   //ALERT: Make sure stream.binance.com has been added to WebRequest list in Options -> Expert Advisors tab

   /*

    Connect to the WebSocket server through either of the below-listed functions as required

   */

   // Fully Configurable
   // if (!client.Connect(url/* , 80 || 443, 5000, false || true, LOG_LEVEL_INFO */)) { 

   // For Non-TLS(unsecured) connection - without SSL required
   // if (!client.ConnectUnsecured(url/* , 80, 5000, LOG_LEVEL_INFO */)) {

   // For TLS(secured) connection - with SSL required
   if (!client.ConnectSecured(url/* , 443, 5000, LOG_LEVEL_INFO */)) {
      ZeroHandle();//Cleanup all clients
      return;
   }

   // Send a string message
   client.SendString(msg);

   // Process messages until the script is stopped
   while (true) {
      if (IsStopped())
         break;

      if (client.State() == CLOSED) {
         Print("Socket connection closed");
         //Reconnect?
         //client.ConnectSecured(url/* , 443, 5000, LOG_LEVEL_INFO */)
         //Or break the loop?
         break;
      }

      /*
         NB: You only need one of these functions
      */

      // Receive all messages and process them using their respective On{Message | BinaryMessage | Ping | Pong | Close} callback(handler)
      uint frames = client.OnMessages();

      // Receive messages and process only TEXT frames using the OnMessage callback
      // uint frames = client.OnStringMessages();

      // Receive messages and process only BINARY frames using the OnBinaryMessage callback
      // uint frames = client.OnBinaryMessages();

      if (frames > 0)
         Print("Frames Processed : ", frames);
   }

   // Disconnect from the WebSocket server
   Print("Disconnecting...");

   if (client.Disconnect()) {
      Print("Disconnected!");
   }
   else {
      Print("Failed to disconnect!");
   }

   //Cleanup all clients
   ZeroHandle();
}
//+------------------------------------------------------------------+
void OnMessage(string message) {
   Print(message);
}
//+------------------------------------------------------------------+
void OnPingMessage(string message) {
   Print("ping received:", message);
   if (client.SendPong() > 0) {
      Print("Pong sent successfully.");
   }
   else {
      Print("Failed to send pong.");
   }
}
//Sample Outputs:
//{"result":null,"id":27175}
//Frames Processed : 1
//---
//{"u":35893555769,"s":"BTCUSDT","b":"27812.78000000","B":"7.14299000","a":"27812.79000000","A":"0.81665000"}
//{"u":35893555770,"s":"BTCUSDT","b":"27812.78000000","B":"7.14299000","a":"27812.79000000","A":"0.82309000"}
//{"u":35893555771,"s":"BTCUSDT","b":"27812.78000000","B":"7.14964000","a":"27812.79000000","A":"0.82309000"}
//Frames Processed : 3
//---
//Frames Processed : 1
//ping received: ping
//Pong sent successfully.

Feel free to contact me for support and questions before/after purchase.

评分 7
Ricardo N
33
Ricardo N 2025.08.17 09:38 
 

This library is amazing. I had some issues because the library was not in the right folder but after fixing that, everything worked. Good job. PS: It seems that LOG_LEVEL_NONE is not working, I get debug level with that or maybe I'm not using it right, anyway, I put LOG_LEVEL_ERROR to not be spammed by logs

thomasb892
19
thomasb892 2024.10.23 14:25 
 

This, Native WebSocket library by Racheal Samson is fast, handles secure wss:// connections effortlessly, and can manage large data transfers with ease.

I love that it's fully native to MQL5, with no extra installations required.

What really stood out was the author's quick response and genuine willingness to help, making the experience even smoother. Highly recommend both the library and the excellent support behind it!

Franck
21
Franck 2024.08.13 13:58 
 

Awesome support from Racheal, thanks for your help setting up the library, keep up the great work ;)

推荐产品
近段时间买家运行良好,但同时也有朋友担心: 1、EA测试回测数据的真实性; 2、回测效果好不代表实测效果好,而免费演示版的可测试时间太短,无法判断EA的实用性。 针对以上问题,现推出一个完美的解决方案,直接给到限定时间的测试版本,需要的可以私信留言,或者聊天窗口找我,看到后会发送测试版本过来。 此外,为了方便部分已购买源代码的客户熟悉了解代码,进一步优化和提升空间,并且让更多的有意向的客户了解这个EA的编辑逻辑,特将代码拆解,不定期的讲解基本思路,跟着走即便是小白也可以快速上手,以便后续购买源代码后快速上手优化! 知乎专栏: Day01:初始MQL5量化系统 - quanter的文章 - 知乎 https://zhuanlan.zhihu.com/p/1969031679428530490 Wordpress个人网站: https://quanter001.wordpress.com/ 如有任何问题,欢迎邮件沟通:quanter001@163.com ****************************************************************
MT4/5通用交易库(  一份代码通用4和5 ) #ifdef __MQL5__      #define KOD_TICKET ulong      #define KOD_MAGIC   long #else        #define KOD_TICKET long      #define KOD_MAGIC   int #endif class ODLIST; #import "K Trade Lib Pro 5.ex5"       //祝有个美好开始,运行首行加入    void StartGood() ;    //简单开单    long OrderOpen( int type, double volume, int magic, string symbol= "" , string comment= "" , double opprice= 0 , double sl= 0 , double tp= 0 , int expiration= 0 , bool slsetmode= false , bool tpsetmode= false );    //复杂开单
Scan a fixed list of assets (Ibovespa) in the chosen timeframe (TimeFrame). For each pair and for various periods. Calculate a regression model between the two assets (and, if desired, using the bova11 index as a normalizer). Generate the spread of this relationship, its mean, standard deviation, speculative deviation, and betas (B1 and B2). Apply an ADF test without exclusion (cointegration/stationarity). Calculate the Z-score of the current exclusion (how many standard deviations are away from
FREE
Introducing "TG Trade Service Manager" — your all-in-one solution for seamless trade management in both MQL4 and MQL5 environments. With a focus on speed, reliability, and convenience, this powerful library simplifies the complexities of trade execution and management, empowering developers with a single interface for enhanced efficiency. Metatrader4 Version   |   All Products   |   Contact   Key Features: Unified Interface : TG Trade Service Manager" provides a unified interface for   MQL4   an
ShreeFx Trade Manager
Dhiraj Shivprabhu Pattewar
️ 1. Interactive User Interface (UI) Dual-Tab System: Cleanly separates execution tools (TRADE) from configuration (️ SETTINGS) to keep the chart clutter-free. Dark/Light Mode: Instantly switch between themes using the ️/ emoji button to match your chart background. Live P&L Dashboard: Real-time display of Account Balance, Equity, Floating Profit/Loss (in USD and %), Total Positions (Buys/Sells), Total Lot Exposure, and current Spread. On-Chart Direct Editing: Change any setting (Lot Size,
Margin Call Shield – Defend Your Margin on Your Terms Margin Call Shield is a tool for MetaTrader 5 traders who want to decide for themselves which open positions are closed during margin call situations before the platform does so automatically based on its internal rules. By default, the broker or platform decides which positions to close, often using undisclosed algorithms. Margin Call Shield lets you set this order according to your own strategy. Why Was Margin Call Shield Created? In a mar
Key Features: 200+ Fully Implemented Patterns   across all categories Advanced Market Structure Analysis Smart Money Integration   (Wyckoff, Order Blocks, Liquidity) Professional Risk Management Multi-Timeframe Analysis AI-Powered Confidence Scoring Advanced Visualization Real-time Alerts Pattern Categories: Single Candle Patterns (Hammer, Doji, Marubozu, etc.) Multi-Candle Patterns (Engulfing, Stars, Harami, etc.) Chart Patterns (Head & Shoulders, Cup & Handle, Triangles, etc.) Harmonic Pattern
FREE
Bastion is a monitor-and-close-only risk manager for prop-firm traders. It watches your account against your firm's daily-loss and maximum-drawdown limits in real time and force-closes your open positions BEFORE you cross a line. It never opens a trade of its own, so it stays fully within the tools allowed by FTMO, FundedNext, The5ers, FTUK and FXIFY. Why traders fail challenges A large share of failed evaluations end on a single daily-loss breach: a moment of inattention, a news spike, one tra
ProTradeLib
Noel Anjao Alube
ProTradeLib - Professional MQL5 Trading Library Complete Developer Toolkit for MetaTrader 5 ProTradeLib is a production-ready, single-file MQL5 include library designed for professional developers building Expert Advisors and trading systems. With seven integrated modules, it provides all the essential building blocks needed to create robust, feature-rich trading applications. Key Features 1. Risk Manager Calculate lot sizes based on account balance percentage, fixed USD risk, or fixed lots Enfo
1. 这是什么 MT5系统自带的优化结果非常少,有时候我们需要研究更多的结果,这个库可以让你在回测优化时可以输出更多的结果。也支持在单次回测时打印更多的策略结果。 2. 产品特色 优化的输出的结果非常多。 可以自定义CustomMax。 输出结果在Common文件夹。 根据EA名称自动命名,且同一个EA多次回测会自动更新名称,不会覆盖上一次的结果。 函数非常简单,你一眼就可以看懂。 #import "More BackTest Results.ex5" // Libraries Folder, Download from the market. //---Set CustomMax void iSetCustomMax( string mode); //---Display multiple strategy results when backtesting alone (not opt). void iOnDeinit(); //--- void iOnTesterInit(); double iOnTester(); void iOnTesterPass( string lang
OrderBook History Library
Stanislav Korotky
3 (2)
Order Book, known also as Market Book, market depth, Level 2, - is a dynamically updated table with current volumes of orders to buy and to sell specific financial instument at price levels near Bid and Ask. MetaTrader 5 provides the means for receiving market book from your broker, but in real time only, without access to its history. The library OrderBook History Library reads market book state in the past from archive files, created by OrderBook Recorder . The library can be embedded into you
RRtoolBox
David Ruiz Moreno
RRtoolbox - Professional Tools: Risk:Reward Trading Tool (SL/TP Horizontals + Pending orders + Diagonals), Alerts set on trend lines (for alerts on diagonal levels), SelfManagement (BE, partials...), close/cancelling by time, Statistics, Info and trading on chart. One-Click Trading with Visual Risk:Reward Management RRtoolbox is a comprehensive trading panel that combines one-click order execution,  statistics and  powerful visual Risk:Reward tools, alerts set with trendlines, on chart butt
Exclusive Imperium MT5 — 自动化交易系统 Exclusive Imperium MT5 是一款用于 MetaTrader 5 的智能交易顾问(EA),基于市场分析算法和风险管理。该顾问完全自动运行,几乎不需要交易者的干预。 注意!购买后请立即联系我 ,以获取安装和设置说明! 重要提示: 所有示例、截图和测试仅用于演示目的。如果某个货币对在某个经纪商处表现良好,并不意味着在其他经纪商处也会如此。每个经纪商都有自己的报价、点差和交易条件。因此, 每个货币对必须由用户自行优化 ,并且在真实账户上 只能以单一货币模式运行 —— 每个货币对单独运行。多货币模式的截图仅供参考。建议至少 每年优化一次 ,因为市场条件会发生变化。 重要信息: 顾问的演示版本仅供试用。未经优化的测试结果不能反映算法的真实表现。完整使用需要针对经纪商、资金和所选工具进行个性化优化。无论如何,优化必须由用户自行完成,并且至少 每年重复一次 。 请记住:最终结果直接取决于您的经验以及您在优化后设置的参数。 主要特点 分析算法: 指标与过滤器的组合,用于寻找交易机会。 灵活性: 可适应不断变化的市场条件
Best Tested Pairs :-  Step Index (Also can use on other pairs which spread is lowest) How does the Magic Storm work The Magic Storm will commence only if the Initial Trade becomes a losing trade. In case the initial trade is a profitable one, or has been closed by the trader there is no need for the Magic Stormto be initiated. Let’s assume that the initial trade was a 1 lot buy trade with Recovery Zone Range Pips is 50 and Recovery Zone Exit Pips is 150 pips. The take profit for this tr
MT5 To Telegram Copier
Levi Dane Benjamin
3 (2)
将完全可定制的信号从 MT5 发送到 Telegram,并成为信号提供商! 该产品采用易于使用且具有视觉吸引力的图形界面。 自定义您的设置并在几分钟内开始使用该产品! 用户指南 + 演示  | MT4版本 | 不和谐版本 如果您想尝试演示,请参阅用户指南。 MT5 电报发送器在策略测试器中不起作用。 MT5 转 Telegram 功能 通过大量选项根据您的喜好完全定制信号 在信号之前或之后添加您自己的自定义消息。 这可以是标签、链接、频道或其他任何内容 在信号中添加、删除、自定义表情符号。 或者您可以将它们全部删除。 按交易品种或幻数过滤要发送的交易 排除发送特定符号 排除发送特定幻数 自定义与信号一起发送的交易详细信息 发送带有信号的屏幕截图 自定义要发送的信号类型 发送信号性能的每日、每周、每月和自定义时间报告 我总是愿意改进产品,所以如果您有想要看到的功能,请发表评论或给我留言。
Kaseki
Ben Mati Mulatya
The Hybrid Metaheuristic Algorithm (HMA) is a cutting-edge optimization approach that combines the strengths of genetic algorithms with the best features of population-based algorithms. Its high-speed computation ensures unparalleled accuracy and efficient search capabilities, significantly reducing the total time required for optimization while identifying optimal solutions in fewer iterations. HMA outperforms all known population optimization algorithms in both speed and accuracy. Use Cases AO
Exp5 Duplicator
Vladislav Andruschenko
4.78 (9)
Duplicator for MetaTrader 5 —— 单终端内的专业持仓复制系统 这是一款面向专业交易者的可靠 Expert Advisor,用于在 MetaTrader 5 中自动复制已经打开的持仓、放大总仓位、应用自定义手数规则,并按照明确的逻辑管理复制出来的持仓。 它非常适合手动交易者、自动化系统使用者,以及希望在同一个终端内更灵活地管理已有持仓的用户。 Duplicator for MT5 并不会依靠自己的交易策略主动开仓。它的职责是监控 MetaTrader 5 账户中已经存在的持仓,并根据你的设置创建对应副本,包括复制次数、手数、Stop Loss、Take Profit、注释以及额外的管理条件。 如果你需要的是 同一个 MetaTrader 5 终端内部 的持仓复制工具,而不是不同平台或不同终端之间的复制系统,那么 MT5 版 Duplicator 正是为这种需求而设计。 MT4 版本 详细描述 + DEMO + PDF 如何购买 如何安装 如何获取日志文件 如何测试和优化 Expforex 的所有产品 链接 如果你需要 MetaTrader 终端之间 的交易复
Trade Manager Pro A complete discretionary trade-management cockpit for MetaTrader 5 — direction-aware position planning, prop-firm rule enforcement, a live correlation heat map, a pre-trade checklist gate, and one-click execution, all in a single on-chart panel. Overview Trade Manager Pro is not a signal-generating "black box" EA. It does not predict market direction and makes no profitability promises. Instead, it is a risk and execution management tool built for discretionary traders — partic
Chart Pro Classic Dark v1.00 Chart Pro Classic Dark is a professional MT5 chart styling and customization tool designed to give your charts a clean, modern, and professional dark appearance. Key Features Dark Black Background — Applies a clean black background to the chart. ️ Candlestick Chart — Automatically configures the chart to use candlesticks. Bullish Candles — Green/Lime bullish candles. Bearish Candles — White bearish candles. Grid Removal — Hides the chart grid for a clean
Inverted_Chart_EA Utility Expert Advisor Inverted_Chart_EA creates and maintains a mirror-inverted chart of any symbol and timeframe. It automatically generates a custom instrument (e.g. US30_INV ) and keeps its price history updated in real time, with bars mirrored around a chosen pivot. This utility gives traders a new way to analyze the market from a different perspective by flipping the chart upside down. Why use an inverted chart? Highlight hidden patterns – price formations that look ordin
Noize Absorption Index
Ekaterina Saltykova
Noize Absorption Index - is the manual trading system that measures the difference of pressure between bears forces and bulls forces. Green line - is a noize free index that showing curent situation. Zero value of index shows totally choppy/flat market.Values above zero level shows how powerfull bullish wave is and values below zero measures bearish forces.Up arrow appears on bearish market when it's ready to reverse, dn arrow appears on weak bullish market, as a result of reverse expectation.
RSI Currency Strength Meter is a powerful and elegant multi-currency indicator that measures the real-time relative strength of the 8 major currencies using RSI logic. By calculating the smoothed performance of each currency across its major pairs and applying the RSI formula, it delivers clean and responsive strength lines that make it easy to spot which currencies are truly strong or weak at any moment. This indicator is particularly useful for visualizing currency correlations and divergence
Trade Copier Professional — 本地复制解决方案   Trade Copier Professional 是一款可靠的本地交易复制系统,适用于 MetaTrader 4/5。它允许交易者在同一台电脑上的多个账户之间即时复制仓位,内置安全控制,并配备专业级仪表盘。   概览   该 EA 可在单一文件中同时运行 Master 和 Slave 模式,并可无缝切换。交易可在 MT4 与 MT5 终端之间复制,无需依赖互联网,采用本地文件通信以实现最高速度与稳定性。实时仪表盘显示连接状态、复制统计以及每日表现。   手数与风险管理   提供四种手数模式:固定手数、倍数、风险百分比和余额百分比。止损与止盈可按比例调整或缩放,必要时可反向复制信号。安全功能包括每日亏损与交易限制、最小/最大手数控制、断线保护以及错误跟踪与自动关闭。   过滤与可靠性   交易可按品种或 magic number 进行过滤,配置灵活。系统通过错误检测、重试逻辑、安全关闭和全面日志确保可靠性。优化后的执行速度几乎即时,且资源占用极低。   使用方法   将 EA 附加到图表,设置
King Trade Copier
Mohammed Maher Al-sayed Mohammed Ahmed Saleh
KingCopier – Lightning-Fast Local Trade Copier for MetaTrader (Master + Slave) KingCopier is a professional local trade copier that mirrors every trading action from one Master account to unlimited Slave accounts on the same PC or VPS — with an internal copy latency of just a few milliseconds. It was built by a real trader for daily real-money use, with one goal: whatever happens on the Master must happen on the Slave, instantly and without exceptions. Watch the demo video to see the real cop
User Manual Buy Trading Utility, Get 2 indicators FREE ! After purchase contact me for your " TWO indicators GIFT (Any one you want) ", adding you in group. Trading Utility MT5 The manual trader's cockpit. Size every trade by risk, place it from the chart, and manage it without ever opening the order dialog. Eight tabs, seven trailing engines, and every stop and target draggable with one click. One panel between you and the order window. Risk-sized entries, draggable stops, seven trailing modes
Welcome to ENTRY IN THE ZONE WITH SMC MULTI TIMEFRAME Entry In The Zone and SMC Multi Timeframe is a real-time market analysis tool based on Smart Money Concepts (SMC), designed to analyze market structure, price direction, and key trading zones. It supports both Single-Timeframe Analysis and Multi-Timeframe Analysis, providing a clearer view of the overall market structure across multiple timeframes, with real-time BUY / SELL signals that do not repaint. It is designed to help filter trading op
Mt5TradeCopier
Mcblastus Gicharu Ndiba
Forex Trade copier MT5.  It copies forex trades, positions, orders from any accounts to any other account,  MT5 even multiple accounts. The unique copying algorithm exactly copies all trades from the master account to your client account. It is also noted for its high operation speed and Tough error handling. It also can copy from demo account to live account too. It is one of the best free trade copiers that can do ,  MT5 or to multiple accounts  MT5 to multiple accounts  Features of Trade Copi
Simo Professional
Maryna Shulzhenko
Description of   Simo : an innovative robot with a unique trading system Simo is a revolutionary trading robot that changes the rules of the game with its unique trading system. Using sentiment analysis and machine learning, Simo takes trading to a new level. This robot can work on any time frame, with any currency pair, and on the server of any broker. Simo uses its own algorithm to make trading decisions. Various approaches to analyzing input data allow the robot to make more informed decis
该产品的买家也购买
WalkForwardOptimizer MT5
Stanislav Korotky
3.78 (9)
WalkForwardOptimizer library allows you to perform rolling and cluster walk-forward optimization of expert advisers (EA) in MetaTrader 5. To use the library include its header file WalkForwardOptimizer.mqh into your EA source code, add call provided functions as appropriate. Once the library is embedded into EA, you may start optimization according to the procedure described in the User guide . When it's finished, intermediate results are saved into a CSV file and some special global variables.
ModernUI Library
Levi Dane Benjamin
适用于 MetaTrader 5 的 ModernUI 库 ModernUI 是一个用于 MetaTrader 5 的图表内用户界面库。它可以帮助 MQL5 开发者在 MT5 图表环境中构建更清晰的 EA 面板、仪表盘、设置窗口、表单、表格、对话框、抽屉式面板以及紧凑型交易风格界面。 它适合希望获得比零散图表对象更专业的界面层,同时仍然完全掌控自己 EA、指标或工具逻辑的开发者。 Modern UI - 用户指南   | EA 示例演示 你可以构建什么 ModernUI 并不局限于某一种面板类型。它为你提供了一个可复用的界面层,几乎可以用于任何你想在 MetaTrader 5 图表中构建的工具。 你可以用它创建简单的设置界面、紧凑型交易面板、完整仪表盘、数据视图、控制面板、账户工具、流程界面、监控界面、实用工具窗口、商业 EA 前端界面等等。 随附的演示展示了几个实用示例,但它们只是起点。如果你的 MQL5 项目需要按钮、输入框、表格、对话框、标签页、抽屉面板、图表、状态区域,或需要一种更清晰的方式在图表上展示信息,ModernUI 都可以为你提供构建模块。 主要功能 适用于 Me
Binance Library MetaTrader 5 connects your Expert Advisors, indicators, and scripts to Binance.com and Binance.US directly from MetaTrader 5. It is a developer library for building custom Binance integrations inside MT5, not a standalone trading robot or copier. The library helps you add Binance instruments to Market Watch, read symbol specifications, load current and historical market data, check wallet balances, manage orders, and track open positions. It supports Spot, USD-M futures, and COI
The library is dedicated to help manage your trades, calculate lot, trailing, partial close and other functions. Lot Calculation Mode 0: Fixed Lot. Mode 1: Martingale Lot (1,3,5,8,13) you can use it in different way calculate when loss=1 ,when profit=0. Mode 2: Multiplier Lot (1,2,4,8,16) you can use it in different way calculate when loss=1 ,when profit=0. Mode 3: Plus Lot (1,2,3,4,5) you can use it in different way calculate when loss=1 ,when profit=0. Mode 4: SL/Risk Lot calculate based on s
Friends, join us! Ask questions and connect with like-minded traders: MetaCOT Public Group MetaCOT Information Channel: news, CFTC reports, and signals: MetaCOT Channel Here’s to successful trading and new profitable signals for us all! Attention! Recently, certain countries have been blocking access to the cftc.gov website. As a result, users in these countries are giving the product low ratings. MetaCOT has always adhered to the highest quality standards and is in no way associated with th
This is a simplified and effective version of the library for walk forward analysis of trading experts. It collects data about the expert's trade during the optimization process in the MetaTrader tester and stores them in intermediate files in the "MQL5\Files" directory. Then it uses these files to automatically build a cluster walk forward report and rolling walk forward reports that refine it (all of them in one HTML file). Using the WalkForwardBuilder MT5 auxiliary script allows building othe
BitMEX Trading API
Romeu Bertho
5 (1)
Cryptocurrency analysis has never been easier with Crypto Charts for MetaTrader 5. Now, trading on BitMEX has never been easier with BitMEX Trading API for MetaTrader 5. BitMEX Trading API library was built to be as easy to use as possible. Just include the library into your Expert Advisor or Script, call the corresponding methods and start trading! Features Trade on BitMEX and BitMEX Testnet. Build and automate your strategies. Concern more with the trading strategy logic and less with the co
Goliath Mt5
Nicolokondwani Biscaldi
Goliath MT5 - scalper fully automated Expert Advisor for medium-volatile forex markets P roperties: The Library trades 10 currency pairs (USDCHF, EURCHF, EURGBP, AUDUSD, USDCAD, GBPUSD, EURUSD, NZDUSD, CADCHF, EURAUD, EURCAD, AUDJPY) The Library does not use martingale The Library sets a fixed stop loss and take profit for all orders The Library only trades a user input volume The Library can be installed on any currency pair and any timeframe Recommendations: Before using on a real account, t
Binance Library
Hadil Mutaqin SE
5 (1)
The library is used to develop automatic trading on Binance Spot Market from MT5 platform. Support all order types: Limit, Market, StopLimit and StopMarket Support Testnet mode Automatically display the chart on the screen Usage: 1. Open MQL5 demo account 2. Download Header   file and EA sample   https://drive.google.com/uc?export=download&id=1kjUX7Hyy02EiwTLgVi8qdaCNvNzazjln Copy Binance.mqh to folder \MQL5\Include Copy  BinanceEA-Sample.mq5 to folder \MQL5\Experts 3. Allow WebRequest from MT5
Gold plucking machine   Gold plucking machine   is an Expert Advisor designed specifically for trading gold. The operation is based on opening orders using the Fast and Slow lines indicator, thus the EA works according to the "Trend Follow" strategy, which means following the trend. Use grid strategy to place orders without stop loss operation, so please make sure the account has sufficient funds. magic number        -  is a special number that the EA assigns to its orders. Lot Multiplier     
The library is used to develop automatic trading on Binance Futures Market from MT5 platform. Support Binance Futures USD-M and COIN-M Support Testnet mode Support all order types: Limit, Market, StopLimit, StopMarket, StopLoss and TakeProfit Automatically display the chart on the screen Usage: 1. Open MQL5 demo account 2. Download Header file and EA sample https://drive.google.com/uc?export=download&id=17fWrZFeMZoSvH9-2iv4WDJhcyxG2eW17 Copy BinanceFutures.mqh to folder \MQL5\Include Copy  Bina
AO Core
Andrey Dik
3.67 (3)
AO Core is the core of the optimization algorithm, it is a library built on the author's HMA (hybrid metaheuristic algorithm) algorithm. Pay attention to the MT5 Optimization Booster product , which makes it very easy to manage the regular MT5 optimizer . An example of using AO Core is described in the article: https://www.mql5.com/ru/articles/14183 https://www.mql5.com/en/blogs/post/756510 This hybrid algorithm is based on a genetic algorithm and contains the best qualities and properties of p
EA Toolkit
Esteban Thevenon
EA Toolkit   is a library that allows any developer to quickly and easily program Advisor experts. It includes many functions and enumerations such as trailing stop, lot, stop loss management, market trading authorisations, price table updates, trading conditions and many more. Installation + Documentation : You will find all the information to install this library and the documentation of its functions on this GitHub : https://github.com/Venon282/Expert-Advisor-Toolkit WARNING : The installat
Hello everyone! I am a professional MQL programmer , Making EAs, Indicators and Trading Tools for my clients all over the world. I build 3-7 programs every week but I seldomly sell any ready-made Robots. Because I am fastidious and good strategy is so few...  this EA is the only one so far I think its good enough to be published here.  As we all know, the Ichimoku indicator has become world popular for decades, but still, only few people knows the right way of using it, and if we check the clo
Applying these methods, I managed to arrive at a nuanced conclusion that is crucial to understanding the importance of unique strategies in contemporary trading. Although the neural network advisor showed impressive efficiency in the initial stages, it proved to be highly unstable in the long run. Various factors such as market fluctuations, trend changes, external events, etc. cause its operation to be chaotic and eventually lead to instability. With these experiences, I accepted the challenge
Introducing "TG Risk Service Manager" — your comprehensive toolkit for swift and precise risk management and lot size calculations in the dynamic world of trading. Designed to streamline development processes and enhance trading strategies, this indispensable library equips developers with essential tools for optimizing risk assessment and trade profitability. Metatrader4 Version |  All Products  |  Contact   Key Features: Efficient Lot Size Calculation : Harness the power of precise lot size c
OpenAI Library MT5
VitalDefender Inc.
该库旨在提供一种尽可能简单的方法,直接在MetaTrader上使用OpenAI的API。 要深入了解库的潜力,请阅读以下文章: https://www.mql5.com/en/blogs/post/756098 The files needed to use the library can be found here: Manual 重要提示:要使用EA,需要添加以下URL以允许访问OpenAI API  如附图所示 要使用该库,需要包含以下Header,您可以在以下链接找到:  https://www.mql5.com/en/blogs/post/756108 #import "StormWaveOpenAI.ex5" COpenAI *iOpenAI(string); CMessages *iMessages(void); CTools *iTools(void); #import 这就是您需要的所有信息,以便轻松使用该库。 以下是如何轻松使用该库并与OpenAI的API交互的示例 #include <StormWaveOpenAI.mqh>       //--- 包含用于AP
这是一个可以定时自动交易的EA。根据你设定的时间,精确到秒,可以设置最多下几单。下单buy或者Sell.可以设置值止盈止损点。并且可以设定在下单后多久平仓。一般都是用来做事件。祝你好运。 请看图片自己根据设定来使用。每一次使用请重新加载EA。不用的时候记得关闭EA按钮。 我来举个例子。比如英国央行利率决议。你在最后两秒下单(设置的是你本机的时间)。因为可能瞬间点差扩大,你可能不敢直接下最大手数,所以你可以选择小手分批从最后5秒开始进场。我相信做过的人知道我说的意思。因为我专业做这个已经十年。最近才做出了这个自动化EA。并且这里面有个检测就是你点击开始之后如果超过了你设定的时间十秒他就不会执行了。保证你的安全。你自己用DEMO账户测试几次你就知道我这个有多好用了!
Molo kumalo
James Ngunyi Githemo
Trading Forex with our platform offers several key advantages and features: Real-time Data : Stay updated with live market data to make informed decisions. User-Friendly Interface : Easy-to-navigate design for both beginners and experienced traders. Advanced Charting Tools : Visualize trends with interactive charts and technical indicators. Risk Management : Set stop-loss and take-profit levels to manage your risk. Multiple Currency Pairs : Access a wide range of forex pairs to diversify your tr
该产品已经开发了 3 年,它是 MQL5 编程语言中最先进的人工智能和机器学习代码库。它已被用于创建多个基于 AI 的交易机器人和指标,适用于 MetaTrader 5。 这是一个高级版,基于免费开源的 MQL5 机器学习项目,链接如下:  https://github.com/MegaJoctan/MALE5 。免费版本功能较少,文档较少,维护不足,仅适用于小型 AI 模型。 该高级版包含您编写 AI 交易机器人的所有必需工具。 为什么要购买此库? 非常易于使用,代码语法友好,类似于 Python 的流行 AI 库,如 Scikit-learn、TensorFlow 和 Keras。 文档齐全,提供丰富的视频、示例和文档,帮助您快速上手。 计算优化,性能优越,运行方式类似普通 EA。  无需额外依赖,无需 DLL 文件,所有内容可编译为单一 .EX5 文件,便于测试和分发。 全天候技术支持,我将提供帮助,确保您正确使用,并在问题出现时协助修复。  谁适合使用此库? 具有基本机器学习和 AI 知识的用户。 机器学习爱好者,特别是来自 Python ML 社区的开发者。 MQL5 中级
Shawrie
Kevin Kipkoech
This Pine Script implements a Gaussian Channel + Stochastic RSI Strategy for TradingView . It calculates a Gaussian Weighted Moving Average (GWMA) and its standard deviation to form an upper and lower channel. A Stochastic RSI is also computed to determine momentum. A long position is entered when the price closes above the upper Gaussian band and the Stoch RSI K-line crosses above D-line . The position is exited when the price falls back below the upper band. The script includes commission, cap
Bookeepr
Marvellous Peace Kiragu
Bookeepr is an advanced MQL5 trading bookkeeping software that automates trade logging, tracks real-time P&L, and integrates a ledger-style financial system for deposits, withdrawals, and expenses. It supports multi-currency assets , generates detailed performance reports , and provides risk management tools to help traders optimize their strategies. With secure cloud storage, exportable reports, and seamless MetaTrader 5 integration , Bookeepr ensures accurate, transparent, and hassle-free fina
Ai Prediction MT5
Mochamad Alwy Fauzi
A free indicator for those who purchase the full version This indicator is created by this Ai, with your desired settings Artificial Intelligence at your service Have a complete artificial intelligence and use it in your codes This artificial intelligence is trained to tell you on each candle whether the market is moving up or down. In general, artificial intelligence can be used in all markets, all timeframes and all symbols However, due to the increasing complexity and decreasing accuracy of
快速关仓,无需任何操作。 当前版本的一键关仓主要针对的是来不及手动关仓的情况,目前是不分交易标的类别,是对所有的持仓进行关仓。 未来可能升级的方向: 1、分类别、分标的关仓。 适用场景:开了多个标的的仓位,并且波动不一,快速频繁的波动影响了整体的判断。 2、增加只关闭盈利仓位、只关闭亏损仓位。 适用场景:持仓较多,趋势发生变化。 个人建议:一般建议选择一键全部关仓,因为如果行情与持仓方向一致,只关闭盈利仓位无形就是扩大了亏损。如果行情方向与持仓方向相反,只关闭亏损仓位,当前已盈利的后面又会变为亏损,盈利无法变现。 3、按照仓位顺序由大到小关仓、按照仓位顺序由小到大关仓。 适用 场景:行情发生波动,对于未来行情判断把握不确定的,可根据自己需求选择仓位关仓顺序,由大到小关仓的话,可以避免亏损的进一步扩大。 4、减小仓位量,保持绝对的安全距离。 适用 场景:对未来趋势相对确定,不想错过当前行情,但是认为当前持仓体量又有点大,想降低仓位。
BlitzGeist Telegram Notifier – Stay Connected to Your Trades Anywhere! BlitzGeist Telegram Notifier is a powerful tool that instantly connects your MetaTrader 5 account with Telegram . No matter where you are – you will always receive real-time notifications about your trading activity directly on your phone, PC, or any device with Telegram installed. Perfect for traders who want professional trade reporting, transparency, and risk management monitoring . ️ Key Features Easy Configuratio
Close All Trades - MT5 UI Tool Features - Trading Executions Simplified! One-Click Buy/Sell Buttons : Instantly place buy or sell orders for trades with a single click, streamlining order execution from the desktop. Customizable Lot Size & Parameters : Enter desired lot size, stop-loss (in decimal places e.g. 7 SL Units for 0.7 below or above for buy or sell), take-profit ( in decimal places ), and the number of trades before submitting (1,2,3,4,5 etc.), allowing precise control over each trade
TupoT3
Li Guo Yin
突破交易策略:智能风控系统升级版‌ 当价格突破关键阻力位时,往往意味着趋势的质变时刻。我们的突破交易策略通过三重智能系统——‌动态阈值识别‌、‌量能验证机制‌和‌自适应止损算法‌,帮助交易者精准捕捉这些跃迁机会。 ‌核心优势‌: ‌智能预警‌:实时监测200+技术指标,自动标记潜在突破位 ‌风险对冲‌:突破失败时自动触发0.5秒内止损,保护本金安全 ‌多周期验证‌:结合日线/4小时/1小时数据过滤假信号 ‌实战案例‌: 2025年第二季度,该策略在现货黄金市场实现连续23次有效突破,平均持仓周期缩短至4.7小时,收益率达传统趋势策略的3.2倍。 ‌智能风控系统‌: ‌动态止盈‌:根据ATR指标自动调整止盈位,锁定利润的同时保留上行空间 ‌分级止损‌:首次突破失败后自动切换至1:1盈亏比保护模式,二次突破确认后恢复原策略 本EA依下图设置做黄金1小时图线,经长时期实盘验证年利润达到30多倍,修改参数可以用作比特币和纳斯达克指数都有很好的收益。
【黄金智能交易EA|风控稳守,盈利突围】 专为黄金波动特性定制的智能交易EA,以硬核交易系统为核心,每笔下单均源自量化模型对行情趋势、支撑压力的精准研判,杜绝主观干扰,让交易决策更客观高效。 搭载多维风控体系,动态止损止盈+仓位智能调控双保险,严格锁定单笔风险阈值,即便面对黄金跳空、黑天鹅行情,也能有效规避大幅回撤,守护本金安全。 更具备浮盈加仓智能算法,趋势明朗时自动放大盈利头寸,让利润在顺势中滚动增长,既不浪费单边行情红利,又通过阶梯式加仓策略平衡风险与收益,实现“风控打底,盈利上不封顶”的交易闭环! 本款EA历经38次修改与测试,每一次升级都境加了EA的稳定盈利能力,才最终确定此为终极版本发布。 本款EA目前只针对现货黄金 交易的长期回测和实盘验证,按照下图设置实现长期的稳定 盈利。如果需要交易期它品种,请根据实际情况更改设置。 本EA为阶梯定价,每卖出10份价格增加10%
Turn your manual trades into fully automated profit machines! This powerful MT5 EA takes over the moment you open a position — no delays, no stress. It instantly places Stop Loss and Take Profit, activates customizable trailing, and locks in profits while protecting your capital Perfect for scalpers: Every trade is immediately secured, giving you the freedom to focus on sniping the best entries while the EA handles all the management work in the background. Auto SL/TP Full trailin
SniperkickEA
Mohamed Maguini
Questo Expert Advisor (EA) è stato progettato per offrire un'esperienza di trading automatizzata di alto livello, adatta sia ai trader principianti che a quelli esperti. Utilizzando algoritmi avanzati e tecniche di analisi del mercato, l'EA è in grado di identificare opportunità di trading redditizie con precisione e velocità. L'EA è configurabile per operare su vari strumenti finanziari, tra cui forex, indici e materie prime, garantendo una flessibilità senza pari. Le caratteristiche princip
筛选:
GiovaGonzalez87
19
GiovaGonzalez87 2025.11.10 15:05 
 

用户没有留下任何评级信息

Racheal Samson
1616
来自开发人员的回复 Racheal Samson 2025.11.10 16:15
You could have asked in comments or dm, I responded in message anyways. Do you have any problems using the library? If none, please update your ratings to help others make informed decisions.
Ricardo N
33
Ricardo N 2025.08.17 09:38 
 

This library is amazing. I had some issues because the library was not in the right folder but after fixing that, everything worked. Good job. PS: It seems that LOG_LEVEL_NONE is not working, I get debug level with that or maybe I'm not using it right, anyway, I put LOG_LEVEL_ERROR to not be spammed by logs

Racheal Samson
1616
来自开发人员的回复 Racheal Samson 2025.08.17 09:44
The review and rating is also surprisingly amazing to me, it helps me improve and shows people are using the library to solve their WS problems. About LOG_LEVEL, None is the lowest, ERROR is the highest and everything not higher than or equal to ERROR won't be shown. I think I need to push an update to reflect your proposed understanding clearly. Thanks for the feedback
thomasb892
19
thomasb892 2024.10.23 14:25 
 

This, Native WebSocket library by Racheal Samson is fast, handles secure wss:// connections effortlessly, and can manage large data transfers with ease.

I love that it's fully native to MQL5, with no extra installations required.

What really stood out was the author's quick response and genuine willingness to help, making the experience even smoother. Highly recommend both the library and the excellent support behind it!

Racheal Samson
1616
来自开发人员的回复 Racheal Samson 2024.10.23 15:17
Thanks for the rating, highly appreciated.
Franck
21
Franck 2024.08.13 13:58 
 

Awesome support from Racheal, thanks for your help setting up the library, keep up the great work ;)

Racheal Samson
1616
来自开发人员的回复 Racheal Samson 2024.08.13 13:59
I'm glad to be of help, it's what you paid for. I'm always here to help.
David Moffitt
30
David Moffitt 2024.05.28 21:33 
 

Needed some help to work out some kinks with the library and my code. Racheal was quick and attentive to support!

Racheal Samson
1616
来自开发人员的回复 Racheal Samson 2024.05.29 00:58
Thanks for the rating, the words are premium and highly appreciated.
Erik Stabij
58
Erik Stabij 2024.01.24 22:08 
 

The library works well and Racheal was very helpfull!

Racheal Samson
1616
来自开发人员的回复 Racheal Samson 2024.01.24 22:10
I'm always happy to help. Will be here for you anytime. Thanks for the rating :D
helk3rn
248
helk3rn 2024.01.16 15:23 
 

works good, thx

Racheal Samson
1616
来自开发人员的回复 Racheal Samson 2024.01.16 16:59
Thanks for the rating, I'm always here to help.
回复评论