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 - 30

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

Triangular Moving Average.

An indicator of StopLoss levels.

An indicator of current support/resistance levels.

The tend indicator: Rahul Mohindar Oscillator

Regularized EMA by Cris Satchwell.

Smoothed Positive Volume Index

Universal trailing of positions and pending orders.

An indicator of StopLoss levels.

Least Square Moving Average - a moving average calculated by the least squares method.

Instantaneous Trendline by J. Ehlers.

Alan Hull's Moving Average is a non-lagging moving average.

Polynomial interpolation.

Crossover of two iMAs (Moving Averages), one more iMA (Moving Average) is used as the filter. Lot: manual or risk percent of balance. Stop, Market or Limit orders. The EA also sets Stop Loss, Take Profit, Trailing Stop.

Pending Buy Stop and Sell Stop orders. The EA trades in the specified time period. Determines the highest and lowest prices in the specified range of bars. Position trailing.

The Volatility Band 2 indicator is similar to the standard Bollinger Bands, and is a modification of Volatility_Band with the following difference: instead of a separate 'Low band adjustment', this parameter affects both the lower and the upper bands of the indicator.

Volatility Bands

A split moving average of volumes

A split Moving Average

The Smart_Money_Index indicator

Positive Volume Index

An indicator of the prevailing trend.

Period Range

Pearson product-moment correlation coefficient

An indicator of volumes relative to the positive/negative price increment

A moving average by Tim Tillson

An information indicator showing maximum and minimum volumes.

A signal indicator based on the Moving Average

Signals are generated by the iBands, Bollinger Bands indicator. When a signal is received, opposite positions are closed.

ChannelEA1 - an Expert Advisor working in a channel, using pending limit orders

An indicator of levels

The oscillator indicator based on Lyapunov stability theory, with the Hodrick-Prescott filter

Sine-Weighted Moving Average

An indicator of bands with a signal line

A trend indicator 'Magic Trend'

Larry Large Trade Index

Larry Commerical Proxy Index

Elastic Volume Weighted MA

The indicator of candlestick direction ratio

Dynamic Moving Average

The ratio of bullish to bearish candlesticks over the selected period

1...232425262728293031323334353637...147