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

MQL5 Source Code Library for MetaTrader 5 - 83

icon

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

The Expert Advisor searches for N identical candlesticks in a row. It buys on bullish candlesticks and sells on bearish ones. The account type is taken into account, i.e. whether it is netting or hedging.

The Boa_ZigZag zigzag, with values displayed as fractal labels.

The Boa_ZigZag indicator with price labels of the ZigZag peak values.

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

The Expert Advisor trades based on signals generated by Stochastic Oscillator. Averaging. A limited number of positions. Trailing.

A simple system based on the crossover of two MAs.

The Expert Advisor searches for N identical candlesticks in a row. It buys on bullish candlesticks and sells on bearish ones.

The indicator shows the statistics of the "Evening Star" pattern.

A redrawing channel with a colored background.

ZigZag with unusual properties

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

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

This is a trend indicator

The Exp_XROC2_VG_X2 trend-following trading system is based on the signals of two XROC2_VG indicators.

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

The Exp_XROC2_VG_Digit_Tm Expert Advisor trades based on signals generated by the XROC2_VG oscillator.

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

The EveningStar Expert Advisor trades the "Evening Star" pattern. Lot is calculated based on the risk value as a percentage of free margin.

The indicator shows the "Evening Star" pattern.

The class monitors the emergence of a candlestick

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

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

A moving average with the four-fold EMA averaging. It displays the most recent value as a price label with the possibility to round the indicator levels up to a required number of digits.

A moving average with the five-fold EMA averaging. It displays the most recent value as a price label with the possibility to round the indicator levels up to a required number of digits.

The EA trades based on the "Bullish and Bearish Engulfing" pattern.

The size of a candlestick. The size is calculated by the following formula: "minuend" minus "deduction".

The indicator displays Wingdings arrows when RSI crosses UP and DOWN levels.

A fractal based variation.

A fractal based indicator.

An indicator of ticks (Bid and Ask). Displays the last 300 ticks.

A moving average with the fourfold EMA averaging, with a real period and the possibility to shift the indicator horizontally or vertically.

A moving average with the five-fold EMA averaging, with a real period and the possibility to shift the indicator horizontally or vertically.

Plotting ROC indicators of two arbitrary same types (including Momentum) and periods in a single window.

The trading system is based on volatility compression

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

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

A trend strength indicator using two Bollinger channels.

The indicator draws a vertical line (OBJ_VLINE) and then moves it to the specified time (hours and minutes).

The trading system is based on the NRTR_ATR_STOP indicator signals.

The EA buys if the open price of the last position is higher than the current price.

1...767778798081828384858687888990...185