This is the largest free source code library for MetaTrader 5 platform programs. Here you can find ready-made Expert Advisors, technical indicators, scripts and libraries. Use the code library when learning MQL5 language and develop your own automated trading applications based on the provided codes.
You can freely download and test published codes, as well as launch them in MetaTrader 5. The library is also available directly from MetaTrader 5 platform and MetaEditor development environment.
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
Enable two-factor authentication ContinueA quantitative physics engine that applies differential calculus to price action, extracting true Market Velocity (1st Derivative) and Market Acceleration (2nd Derivative) to predict trend exhaustion before it happens.
A candlestick chart which colors OHLC candles based on directional price momentum and news impact
Automatically detect Inside Bar patterns, draw projection rectangles, and receive real‑time alerts – all in one powerful indicator. Swing And Full Margin trader
MACD Institutional is an advanced indicator designed for traders looking to trade in line with the "smart money". Unlike the standard MACD, which processes every tick or candlestick close indiscriminately, this indicator reconstructs the price structure using a dynamic volume filter before calculating its moving averages.
An aerospace-grade state estimation algorithm that dynamically filters out market noise and manipulation wicks to reveal the true underlying execution price with zero static phase-lag.
Symbol Summary is a service for MT5 that opens a separate viewer window and shows a detailed report on a trading symbol. It supports Russian and English language, window resizing, scrolling, automatic report update when changing symbol or timeframe of the chart without restarting the service.
A quantitative Information Theory engine that calculates the Shannon Entropy of price distribution to mathematically measure market randomness and algorithmic predictability.
The Weekend Gap Statistics & Distribution Analyzer is a purely analytical MQL5 indicator designed to evaluate the historical behavior of weekend price gaps. It scans chart data to calculate gap closure rates and measures the adverse excursion (drawdown) experienced before a gap successfully closes. By providing statistical distributions—including the 70th and 90th percentiles of adverse heat—this tool enables traders to make data-driven decisions. It moves beyond simple averages, allowing traders to properly assess risk, filter out low-probability instruments, and optimize stop-loss placement when fading weekend gaps.
Chart Water Mark Transform your MetaTrader 5 charts to look as elegant and professional as TradingView.
Swap Monitor Panel is a lightweight, fully customizable indicator that overlays a live swap rate dashboard directly on your MT5 chart. It scans every symbol in your MarketWatch window and presents long swap, short swap, estimated daily cost, and weekly cost side by side — all in one clean, readable panel.
Interactive Correlation Heatmap using high-performance MQL5 matrix functions. > Features a draggable, minimizable dashboard with instant multi-timeframe switching and a vivid 5-band color scale for real-time currency relationship analysis.
Prime Quantum AI is an MT5 Expert Advisor combining a classical pre-filter (ADX + Alligator) with AI vision-based chart confirmation from major AI providers (Anthropic Claude, OpenAI GPT, Google Gemini, DeepSeek, xAI Grok). When the pre-filter detects a trend setup, the EA captures three adaptive- timeframe chart screenshots and sends them to the configured AI provider, which returns direction, confidence, stop-loss and take-profit. A trade is opened only when the AI confirms the pre-filter signal with sufficient confidence. Features: dual Standard Broker / Prop Firm risk modes, configurable lot sizing, optional martingale, multiple SL/TP modes, trailing stop, partial close, news/time/day/spread filters, draggable on-chart info panel, and fully exposed indicator parameters. Requires MetaTrader 5, WebRequest enabled for your provider's URL, and a valid API key. Provider auto-detected from key format.
A digital signal processing (DSP) engine that applies the Discrete Fourier Transform (DFT) to market data, isolating the dominant cyclical frequency to project turning points and eliminate phase-lag.
The Supertrend indicator plots an ATR-based dynamic trend line on the MetaTrader 5 chart, switching between a green uptrend and red downtrend line with optional buy/sell arrow signals at every trend reversal.
ASQ Order Executor — Institutional order execution wrapper for MQL5 EAs ASQ Order Executor provides institutional-grade order execution with automatic retry logic, slippage monitoring, partial fill handling, requote management, and comprehensive execution statistics. Drop it into any EA for production-ready trade execution.
Utility script that exports your MetaTrader 5 trading history to a CSV file. It automatically calculates Maximum Favorable Excursion (MFE), Maximum Adverse Excursion (MAE), and Forward Returns (Time-Based Excursions) in whole points for deep quantitative analysis in Excel. It will allow you to understand whether you close your trades too early and can help optimize overall trading execution.
A chart-cleanup + quick-trading layer for MT5
Keltner style reversal EA for Gold (XAUUSD) with dual EMA filter and optional recovery basket. Basket take profit and hard stop in money, session and spread filters, trailing stop. Updated October 2026 (v1.2). Open source code.
Self-Aware Trend System (SATS) is an advanced MQL5 indicator that combines an adaptive SuperTrend engine with a Trend Quality Index (TQI) dashboard, offering dynamic signal detection, risk management levels, and self-learning calibration for smarter, more reliable trade entries.
Daily Risk Monitor Lite is a lightweight MetaTrader 5 indicator that displays daily realized P/L, floating P/L, daily total, current drawdown, and color-based risk status directly on the chart. It is a read-only monitoring tool and does not close trades or block trading.
The script shows the usage of L1 Trend Filter methods in MQL5 for float and double vectors on random walk simulated data.
This EA implements a range breakout trading strategy. It calculates a price range between start and end times defined by the user, draws a visual rectangle on the chart to mark the high and low of that range, and then monitors price action after the range closes. If the market breaks above the range high, it opens a buy trade; if it breaks below the range low, it opens a sell trade.
A machine-learning inspired approach towards trending regimes. Providing accurate signals and backtest confidence built-in
Adaptive moving average crossover indicator for MT5. A range aware fast line and an efficiency aware slow line, color coded bias and arrows on each cross. Gold, forex and indices. Updated October 2026 (v1.2). Open source code.
Candle countdown HUD with trading sessions (UTC), live spread and anomaly detection, daily range vs ADR, and market-closed state with reason (holiday / weekend / session). Holidays calendar included for seven major markets.
A predictive quantitative engine that replaces lagging retail ATR, it utilizes the Nobel-prize-winning GARCH(1,1) econometric model to mathematically forecast future market volatility and variance.
Precision Sniper is a multi-confluence MT5 indicator inspired by TradingView's top signal tools, grading every buy/sell signal (A+, A, B, C) based on EMA structure, RSI, MACD, ADX, VWAP, and volume alignment, with 8 presets, HTF bias confirmation, auto TP/SL levels, trailing stop, and a built-in backtest dashboard.
A quantitative multi-asset oscillator designed for Statistical Arbitrage (Pairs Trading), it calculates the logarithmic spread between two correlated assets and measures its Z-Score to identify risk-neutral mean-reverting opportunities.
RSI momentum candle indicator for MT5. Colors every candle by momentum state in four bias levels plus neutral, no separate oscillator window. Three modes. Gold, forex and indices. Updated October 2026 (v1.3). Open source code.
Using arrow to open a position and the middle line to exit from the position that is currently open.
This EA implements a range breakout trading strategy. It calculates a price range between start and end times defined by the user, draws a visual rectangle on the chart to mark the high and low of that range, and then monitors price action after the range closes. If the market breaks above the range high, it opens a buy trade; if it breaks below the range low, it opens a sell trade.
QuantumAlgo Trade Panel is a professional-grade trading utility for MetaTrader 5, designed to bridge the gap between complex institutional strategies and seamless execution. Whether you are a Scalper, Swing Trader, or follow Smart Money Concepts, this panel automates your risk management and technical analysis, allowing you to focus purely on the setup.
Institutional-grade forex session detection and analysis library for MetaTrader 5.
Bidirectional grid EA for Gold (XAUUSD). Candle direction filter, lot doubling up to a cap, basket exit by average take profit or partial close. Daily target and drawdown pause. Updated November 2026 (v1.2), entry guard against fast loops. Open source code.
BEC Trade Manager helps you manage active positions on the current symbol using one-click controls for breakeven, trailing logic, partial close, stop-loss removal, profit-side closing, loss-side closing, and fast scalp entries. It also displays key account and symbol information on the chart, including equity, floating profit, daily profit, stop-loss labels, and basket breakeven preview.
One click trade panel for MT5 and MT4. Buy and sell with lot by fixed size or balance percent, SL and TP by price or distance, breakeven, close all, partial close, pending orders set on the chart. Updated October 2026 (v1.1). Open source code.
This mini custom-built MetaTrader 5 dashboard is a robust, comprehensive risk management and performance based monitoring tool and utility created to give both Prop firm and personal funded traders full visibility and control over their trading activity in real time.
RSI Grid Overlap Pro is a professional MT5 Expert Advisor combining RSI-based market entries with an adaptive grid recovery system. It features intelligent overlap order management to reduce drawdown, plus virtual trailing stop, breakeven, and three lot sizing modes — fixed, balance-proportional, and risk-based — making it suitable for both conservative and aggressive trading styles.
Economic calendar trading guard library for MetaTrader 5 with live MQL5 Calendar API integration.