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

MQL4 and MQL5 Source Code Library

You don't know where to start learning the MQL5 or MQL4 programming language? Various programs for your MetaTrader terminal are available here. Download and study published code examples, develop your own indicators and Expert Advisors. Publish your applications in the largest library of MQL5 and MQL4 codes, and they will be available in every MetaTrader terminal and MetaEditor.

Your code examples in MQL4 and MQL5 will be distributed worldwide, and thousands of traders will know about you!

The Repulse Multi Timeframe indicator measures and displays the bullish or bearish pressure associated with each price candlestick in the form of a curve.

In this indicator Jurik MA is sigmoidal (Softmax) normalized - made as oscillator that ranges in 0 to 1 range, and if you use hyperbolic normalization it will range from -1 to +1 range.

The Repulse indicator measures and displays the bullish or bearish pressure associated with each price candlestick in the form of a curve.

In this indicator T3 is sigmoidal (Softmax) normalized - made as oscillator that ranges in 0 to 1 range, and if you use hyperbolic normalization it will range from -1 to +1 range.

The five-week and 17-week RSI values are used for entry and exits while the 17-week RSI is used for trend direction as an entry filter in the retracement entries.

A trend-following trading system Exp_Sinewave2_X2 is based on the signals of two indicators Sinewave2

Indicator SilverTrend_x10 shows the color of the SilverTrend indicator candlesticks from ten different timeframes from the bar defined in the indicator input parameters.

Indicator MultiSilverTrend_x10 shows information on the current trends, using the colors of indicator SilverTrend from ten different timeframes.

Indicator Sine Wave with the timeframe selection option available in input parameters, in form of a colored cloud.

Two identical trading systems (for long and short positions) based on the signals of indicator SilverTrend, which can be configured in different ways within one Expert Advisor.

Indicator SilverTrend_Signal that generates alerts and sends e-mails and Push-messages when the indicator changes its color, implemented as candlesticks. Candlesticks with the trend are colored brightly, and those against the trend are colored darkly.

Indicator SilverTrend_NRTR with the timeframe selection option available in input parameters, alerting and sending e-mails and push-messages when the indicator changes its color.

A simple RSI with a channel and signal arrows

Smoothed Smart Money Pressure Oscillator

Semaphore signal indicator SilverTrend with the NRTR line of possible stop order locations.

Smart Money Pressure Oscillator

A slow stochastic with a histogram.

Weight Volume Move-Adjusted Moving Average.

Indicator Wiseman with the timeframe selection option in its input parameters.

An indicator of the volume / bar price range ratio with a signal line and with the option of identifying the maximum/minimum price change resistance.

Indicator of candlestick size / tick volume ratios and signal line.

Indicator of candlestick size / tick volume ratios.

A candlestick size indicator.

A colored tick-volume indicator.

Wiseman is an indicator basically aimed at showing the candlestick, on which the trend has changed its direction.

Indicator Kalman Filter. It allows efficiently smoothing the noise, extracting the main trend from it.

The oscillator shows standard deviation calculated on the difference between the High and the Low.

Two channels by the High and Low of MA.

Indicator of the difference between ADX and ADX as of N periods ago.

Oscillator ADMIR (Average Directional Movement Index Rating) shows the ratio of the ADX lines of two indicators Average Directional Movement Index with the calculation periods differing by the specified value.

Indicator CandleStop_Cloud with the timeframe selection option available in input parameters.

An indicator to pull trailing stops with the channel color background filling and showing the latest values as price labels.

The Exp_CandlesticksBW_Tm Expert Advisor is based on the color change of the CandlesticksBW candlesticks and allows strictly define the trading time interval.

Indicator CandlesticksBWx10 shows the color of the CandlesticksBW indicator candlesticks from ten different timeframes from the bar defined in the indicator input parameters.

Indicator MultiCandlesticksBW_x10 shows information on the current trends, using the colors of indicator CandlesticksBW from ten different timeframes.

An indicator with coloring candlesticks according to B. Williams and alerting on trend change, as well as sending e-mails and Push-messages in such situation.

Indicator OzFX_D1_IndAES_v1.0 with the timeframe selection option available in the input parameters.

Two indicators iMA (Moving Average, MA) and one iRSI (Relative Strength Index, RSI). Many settings and optimization of trade signals formula.

A trading system based on the signals of indicator SilverTrend_CrazyChart.

Trading based on indicator iStochastic (Stochastic Oscillator, Stochastic). Stop Loss, Take Profit, and Trailing of a position can be enabled/disabled.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125