Watch how to download trading robots for free

Find us on Facebook!
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 - 6

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.

To post a new code, please log in or register
latest|best

Indicator Dynamic Zone RSI

Advance Parabolic Time/Price System

Indicator Multi timeframe Gann Hi Lo Activator

Indicator Non lag MACD

Indicator Non lag average

Indicator Spread Oscillator

Indicator Micro Pivots

Indicator Multi timeframes Bill Williams Accelerator Oscillator

Indicator Market Session

Indicator Two Stochastics with MA Smoothing and Convergence Divergence line

Protecting a position (hedging)

Comparing OHLC on timeframe M5

Three timeframes. One iMA (Moving Average, MA) and one iStochastic (Stochastic Oscillator) on each timeframe

Indicator XXDPO represented as candles

An EA based on indicators iMA (Moving Average, MA) and iStdDev (Standard Deviation, StdDev)

A trading system based on several indicators from several timeframes.

The indicator displays the information on the current trends, using the ColorPEMA_Digit indicator colors from ten different timeframes

Indicator ColorPEMA_Digit_Trend_x10 displays the directions of the ColorPEMA_Digit indicator signals from ten different timeframes from the bar specified in the indicator inputs

An Expert Advisor based on two indicators: iFractals (Fractals) and iAlligator (Alligator).

Indicator Murrey_Math_Lv_Arr limiting the computer resources used in calculating and displaying the indicator on the chart

A panel to close positions based on class CDialog. Buttons based on class СButton.

An Expert Advisor for placing Stop Loss and Take Profit.

Indicator Murrey_Math_Lv with the levels shown as labels that can be changed in its input parameters

Working with pending Stop orders

Two identical trading systems (for long and short deals) based on the ColorPEMA indicator signals that can be configured in different ways within a single EA with an ability to change the volume of a forthcoming trade depending on the results of the previous trades for this trading system

A trading system based on the signals of indicator ColorPEMA_Digit with the possibility to set a fixed position holding time

Indicator ColorPEMA_Digit_r with the timeframe selection option in its input parameters, limiting the computer resources used in its calculations within the entire chart and on the current bar

Indicator ColorPEMA_Digit with the timeframe selection option in its input parameters

A trading system based on two indicators iMA (Moving Average) and one indicator iStdDev (Standard Deviation, StdDev)

Indicator Three timeframes MFI with Average

Indicator Double-deviation Bollinger Band with cloud

Three indicators from different timeframes: iMACD (Moving Average Convergence/Divergence, MACD), iAlligator (Alligator), and iRSI (Relative Strength Index, RSI)

Indicator Stochastic Overlay

Indicator RSI Overlay

A moving ColorPEMA_Digit with the limitation of the computer resources used for its calculations on the entire chart and on the current bar

Indicator MACD Overlay

A five-fold exponential moving average that displays the most recent value as a price label with the possibility to round the indicator levels to the required number of orders

Indicator Advanced Fractal Envelopes

Indicator Advanced Fractal Overlay

A trading system based on breaking through iFractals

12345678910111213...168