Download MetaTrader 5

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

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.

latest|best

The indicator which fixes Pin Bars in the chart

Smoother Commodity Chanel Index.

The Moving Average which uses quite a simple procedure on decreasing temporal lag based on the increase of the Moving Average period.

The indicator which displays the beginning and the end of the trend

The indicator for pair trading. The simplified variant of the "ind_2_linep1.mq5" indicator

The RSI indicator drawn on the basis of the smoothed price series with the added signal line.

The Renko Line Break indicator determines itself a synthesis of renko charts and three linear breakthrough

This indicator is created to determine the trend and its direction.

The indicator of the first price change derivative or simply trend speed and sign.

The indicator to define the global trend.

These scripts are designed to sell with fixed values of Stop Loss and Take Profit in points from the current price

These scripts are designed to buy with fixed values of Stop Loss and Take Profit in points from the current price

The indicator of the minimum sum of price changes which forms signals after flat movements and before potential breakthrough in this or that side

Trade functions library designed for use in the code of scripts and Expert Advisors depending on a broker

The indicator of reversal points drawn on the week candlesticks

The trend indicator with three states.

An updated version of the CBitPic class with the ability to control drawing transparency

This indicator is calculated on the basis of currency pair volatility displaying the nearest support and resistance level depending on the trend direction.

The indicator displays the number of false breakthroughs for the specified period

The indicator that calculates the volume per second (or over period) and the corresponding Moving Average.

The narrowest range indicator defines the moments when the market is in the "compressed" state that says of the future breakthrough in this or that side

Signals of entries and exits on the system "Friday effect"

The class to play music using the MIDI device

Calculation of 32 digit string MD5-hash from transmitted byte array

The Moving Average drawn on the basis of the EMA algorithm. A linear interpolation of two different period EMA is used

An interesting trend indicator drawn on the basis of the simple Moving Average

ElliottWaveMaker 3.0 is Tool for Semi-Automatic Analysis of Elliott Waves and Andrew's Pitchforks, a logical extension of version 2.0 known as AutoElliottWaveMaker. In version 3.0 minor errors are corrected, the ability to draw Andrew's Pitchforks and a few additional functions are added.

An Expert Advisor based on the difference of two moving averages.

The fractal adaptive Moving Average by John Ehlers. Version 1.1 7/17/2006

The simplest semaphore signal indicator based on different period Moving Averages

The Expert Advisor to perform global Take Profit for all open positions.

The Expert Advisor to perform global Stop Loss on all open positions

Show minutes and seconds left before new candle is appeared.

The OpenSellPosition_X script is created to sell at fixed values of Stop Loss and Take Profit in points from the current price. Position volume is determined on the basis of the level of losses.

The OpenBuyPosition_X script is designed to buy at fixed values of Stop Loss and Take Profit in points from the current price. Position volume is determined on the basis of the level of losses.

Library to work with Skype.

The ergodic CCI.

The trend indicator drawn on the basis of a comparison of six levels of simple Moving Averages with High and Low of the current candlestick

Calculate Average Speed of price.

The Moving Average drawn on the basis of Gauss algorithm

1...656667686970717273747576777879...104