Watch how to download trading robots for free
Find us on Twitter!
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

MQL4 Source Codes of Technical Indicators for MetaTrader 4 - 2

icon

The library of technical indicators for MetaTrader 4 developed in MQL4. Regardless of the market (forex, securities or commodity market), indicators help to represent quotes in an accessible form for easy perception.

This section contains thousands of applications that analyze financial markets using different algorithms. Conventionally, they can be divided into a few categories: trend indicators, oscillators, volume indicators and so on. In addition, there are sets of indicators based on algorithms by famous financiers. For example, Bill Williams' indicators and likes of it. All of them are characterized by different parameters of reliability, efficiency, lagging and others. There are more than 2000 indicators for technical analysis: trend indicators, reversal indicators, indicators of levels, predictors, scalping indicators and many others.

Submit your code

Negative Volume Index (NVI) is a free technical indicator for advanced chart analysis in MT4, MT5 platforms. It is based on tick volume (can be substituted with real volume in MT5) and has two useful features added:

Candle Range MetaTrader indicator — is a very simple and lightweight indicator that displays the candle's range in pips on mouseover. In addition, to the High/Low range, it can optionally display the body size (Open/Close) for candles. Multiple display parameters are available to control how the indicator looks. This indicator is available for both MT4 and MT5 versions of the trading platform.

The indicator shows the names of the days of the week as text labels on the chart.

Moving average with calculated period based on timeframe

ZigZag with automatic step size detection for changing wave direction.

Another version of ZigZag, where the step size for changing the direction of the segment is set in price points.

Double ZigZag draws virtual Buy and Sell levels on the price chart.

The indicator draws the nearest levels of the specified price range.

The same PNB from Yousufkhodja Sultonov.

The indicator displays the actual range of the hourly candle in percent and the calculated range based on average statistics.

The indicator searches for candles on the price chart that are larger than the size specified in the settings and marks them on the chart.

change of MA curve to horizontal line and DPO curve shall represent the distance from close price to zero level (or MA curve)

Linear Regression Value (metatrader 4 version)

a very convenient way to filter out unnecessary signals of crossing levels

improved version of the standard Simple moving average indicator with a lower delay based on: https://www.mql5.com/en/code/30844 (author: https://www.mql5.com/en/users/mladen)

standart RSI with dynamic levels

Changing the size of the chart window is important in my EA, but it may serve as inspiration for others.

Simple banner showing Symbol Spread Equity Profit Banner

AVA adapts its analysis based on current market dynamics. This adaptability makes it invaluable for predicting shifts towards higher volatility or calmer periods.

Displays the gains and losses for all candles where the given threshold is surpassed. The values are calculated in points and percentage.

mt4 version of original indicator

SSH is popular indicator as it uses simply two moving averages. This version is a mylti-TF of SSH with TF change ability from screen.

A simpler way to display Heikin Ashi

The purpose of this indicator is to demonstrate newbie friendly way a structure of a multi time frame indicator based on recursion.

Few improvements from standart fractal: 1. You can chouse size of fractal. Standart version use 2 as constant 2. It does not draw fractals against the trend, which makes your chart much more informative

Show MACD directly on chart

Donchian Channel with mid line and moving average of mid line. Updated Dec 6, 2023 Minor code update

The Oscillator Indicator for MetaTrader 4 is a powerful tool that accurately identifies the perfect signal on the completion of trends.

A combination of data analysis from the Awesome Oscillator and the resulting direction of the candles relative to the previous range

This is an indicator with a rainbow-like display, both for trend or pullback prediction.

Indicator shows histogram of ratio of sum of lower time frame ranges to current timeframe bar range

Trend indicator based on the intersection of adaptive HMA and its smoothed line. I recommend using it together with the flat indicator to determine the beginning of a trend early

This indicator calculates the percentage of the probability of a price reversal from a given size of the maximum rollback based on the history of the chart movement

New level of trend prediction!

A trend or cycle indicator with very low lag.

123456789...63