Watch how to download trading robots for free
Find us on Telegram!
Join our fan page
Access the CodeBase from your MetaTrader 5 terminal
Couldn't find the right code? Order it in the Freelance section
How to Write an Expert Advisor or an Indicator

MQL5 Source Codes of Technical Indicators for MetaTrader 5

icon

MQL5 technical indicators analyze MetaTrader 5 price charts on Forex, as well as stock and commodity markets. Indicators define trend direction and power, overbought and oversold states, support and resistance levels. Underlying mathematical models provide objective assessment of the current market state allowing traders to accept or reject trading system's signals.

You can download and launch offered indicators in MetaTrader 5. The library of indicators is also available directly from MetaTrader 5 platform and MetaEditor development environment.

Submit your code

Non-repainting three-bar Fair Value Gap detector for MetaTrader 5. Closed-bar detection, the 50% Consequent Encroachment level, mitigation as an explicit state machine, incremental scanning, and a built-in self-audit that re-checks the stored gap levels against the closed-bar series on attach. Pure native MQL5, no DLLs, no external dependencies.

Session Range Breakout draws the high and low of up to three intraday sessions (Asia, London and New York by default) and extends each level to the right with optional H/L labels and a range rectangle. Session hours, names and colours are configurable in server time. Optional popup, sound and push alerts fire when a bar closes outside a session range. The levels are fixed once the session closes, so the drawing does not repaint. The indicator draws chart objects only and never opens trades.

ICT kill zones (Asian, London, New York, London Close) at the right New York hours on any broker, with US and EU summer time. High / low boxes, levels until price takes them, midnight open. Alerts and buffers for EAs.

Marks the order block behind each break of market structure (the last opposite candle before the move), tracks when it is used and turns failed blocks into breaker blocks. No repaint. Alerts and buffers for EAs.

Marks breakouts of the recent trading range and the breakouts that fail (price closes back inside within a few bars). Closed bars only, alerts, buffers for iCustom.

Spread Monitor — a simple information indicator for MetaTrader 5.

Market structure in the way of Smart Money Concepts: swing highs and lows with HH / HL / LH / LL labels, BOS (break of structure) and CHoCH (change of character) lines. Swings count only after their right candles close, so nothing repaints. Alerts and a trend buffer for EAs.

Draws the fair value gaps (three-candle imbalances) that price has not filled yet, follows how much of each gap is filled and ends the box when it is. Closed candles only, no repaint. Alerts and buffers for EAs.

GDS Renko Liquidity Sweep Lab is a free educational indicator for studying what happens after price crosses a confirmed Renko swing level.

Spread Monitor is a simple information indicator for MetaTrader 5. It displays the current spread in pips in the form of a compact graphical panel with colour-coded indicators and a level bar.

A compact MetaTrader 5 indicator that classifies five selected timeframes as Bullish, Bearish, Neutral, or N/A using price and EMA alignment, then summarizes whether the timeframes are aligned or mixed. This is a market-context indicator, not a standalone trading signal

Finds volatility compressions as they form, boxes each one as a channel with ATR edge bands and marks the bar that breaks out of it. Inside the live channels: buy and sell volume split from M1 bars, drawn as candles and text, plus a gauge of the current volume delta. Breakout arrows in buffers for EAs.

Several buys and sells open on one symbol? The indicator draws where all buys, all sells and the whole basket break even, and the price for a profit target. Planned entries can be added to see the break-even before you trade.

The indicator shows the average rank-based price velocity

Momentum VWAP Barrier Breakout is an MT5 indicator that identifies tested support and resistance zones and displays confirmed breakout arrows after the candle closes. It includes optional VWAP, SMA, SMMA, and no-filter modes, with VWAP selected by default. Designed primarily for XAUUSD M5, it can also be tested on M15 and M30 for fewer but potentially cleaner signals. Traders may consider entering at the next candle’s open, placing the stop beyond the breakout candle or broken zone, and targeting approximately 1.5R to 2R. Use the indicator together with market structure, higher-timeframe direction, news awareness, and proper risk management. Test it thoroughly on historical data and a demo account before using it with real money.

Point & Figure draws a classic P&F chart (X columns for rising prices, O columns for falling prices) in a separate indicator window, on any symbol and timeframe. It also adds a trading panel and support/resistance lines on the main chart.

Displays daily, weekly and monthly ATR, the current high–low range, the range as a percentage of ATR, and price movement from each period's open.

Displays today's floating PnL as % of balance plus how much of the daily-loss budget is consumed — the number that actually matters for prop firm rules (FTMO, Apex, TopStep). Color code: green under 50% of limit, orange under 80%, red above. Configurable reset hour. Free to use. Inputs: InpLimitPct (daily loss limit %), InpResetHour (day reset, server time), colors, font size. Attach to any chart — reads account equity live.

Draws the Asian, London and New York session ranges as colored boxes with their high and low, plus dotted extension lines for breakout trading. Same ranges on every timeframe up to H1.

A rolling, Katz-style fractal dimension of price that collapses toward 1.0 during directional moves and rises toward 2.0 during choppy, range-bound action, giving traders a single number for how "trendy" the current market is.

Position size calculator for MT5. Drag the SL and TP lines on the chart and the panel shows the lot size for your risk %, the real risk after rounding, the reward and R:R. Never trades.

A momentum oscillator that relaxes back toward zero at a speed set by the current ATR relative to its own moving average, so decay speed adapts automatically to whether the market is calm or volatile.

Clean and efficient Anchored VWAP (AVWAP) indicator for MetaTrader 5. Calculates volume-weighted average price from a user-defined anchor date with optional volatility standard deviation bands.

Smart Money Concepts market structure on pullback swings: trend, BoS, CHoCH, IDM and liquidity sweeps. A level counts as taken only on a close — a wick through it is marked as a sweep (x) and relocates the swing. Self-contained, closed bars only.

QCL Heikin Flow applies two-stage smoothing to Heikin Ashi candles, helping traders filter price noise and visualize trend direction. Features adjustable smoothing periods, four moving average methods, and customizable candle colors.

Support and resistance channels built from price pivots and ranked by strength: each pivot inside a channel and each bar that touched it adds to its score. The strongest channels run across the whole chart, colored by where price is, with break arrows, pivot marks, two averages and alerts.

Shows the range of every bar in points, its moving average (SMA or EMA) and a suggested stop distance (average x factor). A stop tighter than the typical bar range gets taken out by ordinary noise; the indicator makes that threshold visible in points, the same unit a stop loss is set in.

Asian, London and New York session high/low boxes with ICT killzone shading, breakout alerts and average-range statistics panel.

Overlay higher timeframe candles directly onto your lower timeframe charts with customizable body fills, independent borders, and precise wicks. Effortlessly spot macro bias, session openings, and liquidity ranges without switching screens. Ultra-lightweight engine featuring separated box bounds and rock-solid chart change auto-recovery.

Shows how much of the daily loss limit of a prop firm account is already used, and how much is left. Read-only indicator.

Regular and hidden divergences between price and ten oscillators calculated inside the indicator: MACD, MACD histogram, RSI, Stochastic, CCI, Momentum, OBV, VWMACD, Chaikin Money Flow and MFI. Lines on price, a box naming every oscillator that agrees, and alerts.

Session Levels draws the reference levels intraday traders watch most: Asian range, London and New York sessions, previous day and week high/low, daily VWAP, swing points and round numbers. Hover any level to read what it is and why it matters. Optional alerts when price breaks the Asian range or the previous day high/low.

Real-time multi-timeframe side panel mini-chart with smart color matching, independent price scale, and candle countdown timer.

Draws ICT structure on the chart (liquidity pools, sweeps, market structure shift, fair value gaps) from closed bars only, adds a trade plan for every confirmed setup and keeps an honest statistics panel of what those setups did on your symbol. Analysis only – it does not trade.

One panel for the rules of a prop firm challenge: daily loss, maximum loss (static or trailing), profit target, minimum trading days and the best-day (consistency) rule. For each one it shows how much is used and how much room is left, in money. "One more trade" tells you the largest lot size that still keeps a stop-out inside the room left today and in the max-loss room. Read-only: it never opens, changes or closes a trade. The presets hold typical values; firms change their rules, so check yours and use the Custom preset. Built on the ATS Risk Library (ATS_RiskLib.mqh, included).

The Trend BOSS Indicator identifies regimes such as trending, ranging or volatile using a Bag-of-SFA-Symbols (BOSS) classifier. Gate your strategies behind specific regimes or use the indicator to identify various market conditions.

Measures market activity from the waits between quotes. An ACD model with the daily rhythm removed gives one ratio per tick: 1 is normal, 2 twice as busy.

Extrapolator fits a sum of sinusoidal harmonics to the recent price history and extends the fitted curve to the right of the last bar as a forecast.The forecast is a mathematical extrapolation of past cyclical behaviour, not a guarantee of future price movement. The last part of the line is redrawn while the current model bar is forming, and the fitted curve changes with each refit.

A specified moment in time can be analyzed through multiple synced timeframes from 1 host chart for a symbol.

Shades the chart background by volatility regime (Compression, Normal, Expansion) based on the percentile rank of the current ATR. Shows the current regime on the chart, alerts on regime changes and exposes buffers for Expert Advisors.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148