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 Code Library for MetaTrader 5 - 102


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.

Submit your code

Parabolic SAR that avoids some of the problems of existing PSAR-indicators and calculates the values correctly.

This is an auto-correlation version of Spearman rank indicator.

Keltner channel with some additional options

This is the Leader of the MACD as described by Giorgos E. Siligardos.

There are some additions in this indicator compared with MetaTrader 4-version.

A version that adds some averages not supported by built in standard types to the collection of averages in one single file.

It is a DT oscillator as described by Robert Miner with some additional features.

The upgraded version of Stochastic without repainting.

Indicator is already multi time frame version with alerts included.

Three T3s calculated: of high (upper line), close (middle line) and low (lower line).

MACD variation that uses Nonlag MA.

A simple indicator that shows the high and the low of desired time frame on a current chart.

A stochastic indicator with a twist: it is calculating a stochastic, and then a stochastic of that stochastic.

It is made more up-to-date and multi time frame option added.

A variation on the T3 theme that was made as a sort of envelopes using T3 for basic value.

Pivot Point indicator with an addition of 4 ways of calculating pivot points.

This version has 6 sub-types it is actually calculating.

The version of well known Woodies CCI with correct implementation of trend changing rules

BB MACD is a MACD indicator variation with an addition of Bollinger bands

T3 floating levels made as an oscillator

T3 with floating levels

Super pass-band filter as described by John Ehlers

Composite RSI

"Classical" MA with a twist: colors change depending on the angle of the slope.

MetaTrader 5 version of NonLag MA.

This is an improved Jurik Filter with the option to be applied to any indicator not only to prices.

The idea of this one is simple: it should "imitate" as much other moving averages as it can.

This version is showing the channel that needs to be broken if the trend is going to be changed.

The indicator displays in chart window the important data on current symbol.

Simple volume indicator that has two coloring mode options.

Indicator includes Spearman rank correlation and Pearson correlation.

An oscillator to help you confirm your Elliott waves counting (doesn't count the waves automatically)

Indicator to display existent and emerging harmonic chart patterns.

The Range Action Verification Index indicator implemented as a histogram of strength and direction of the current trend.

The Exp_CandlesticksBW Expert Advisor based on signals of the CandlesticksBW indicator.

The RAVI indicator with the timeframe selection option available in input parameters.

The indicator is an example of smoothing a time series of the OsMA indicator by filtering harmonics of higher order.

The indicator is an example of smoothing a time series of the RVI indicator by filtering harmonics of higher order.

The indicator is an example of smoothing a time series of the ADX indicator by filtering harmonics of higher order.

The i-CAi indicator that fills the chart space with a colored background and displays the most recent value as a price label with the possibility to round the channel levels up to a required number of digits, as well as displays a price grid with those rounded values.