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

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

Another version of Bollinger Bands using as the middle line the average of the High and Low over a selected period.

We open a new position opposite to the previous one. Inputs only contain Stop loss, Take Profit and the minimum lot.

The OzFx system. It uses Accelerator Oscillator and Stochastic Oscillator.

The Price Channel trading system.

The indicator implements a breakout system using the Mikahekin indicator channel.

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

A trading system based on the ForceTrend indicator signals.

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

The indicator displays trend power and direction based on four moving averages.

Measuring the net performance of MetaTrader 4/5 strategy testers.

The script saves current chart settings to a template with the specified name.

The MetaTrader 4/5 library allows generating reports based on the trading history.

An Expert Advisor without a single indicator. Uses lot and step increase.

A channel based on peaks and troughs of AlexSTAL_ZigZagProf.

It is a simple trend indicator with the color indication of active trend direction.

The vertical version of the BarTimer indicator implemented using the classes of libraries that were described in detail in the article "Custom indicators and infographics in CCanvas", with the possibility to set a fixed timeframe, data from which the indicator displays in input parameters, and producing a sound alert when the bar changes.

The vertical version of the BarTimer indicator implemented using the classes of libraries that were described in detail in the article "Custom indicators and infographics in CCanvas", using current timeframe data and producing a sound alert when the bar changes.

A trading system based on the ColorFisher_m11 indicator signals.

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

A trading system based on the AFStar indicator signals.

The iMA (Moving Average) indicator based on iCCI (Commodity Channel Index). It is an analogue of Previous Indicator's Data in the terminal.

Oscillator using inverse Fisher Transform.

If a trade is closed by Stop loss, the volume is doubled; if by Take profit the minimum volume is used. OnTradeTransaction is used to determine whether a trade was performed after the activation of Stop loss or Take profit.

A semaphore signal indicator.

A channel based on peaks and troughs of ZigZagOnParabolic.

Buy a security (open BUY positions) at a lower price, sell (open SELL positions) at a higher price.

The Paramon indicator with a color filling of the channel.

A trading system based on the Omni_Trend indicator signals.

A breakout trading system based on the signals of the Color_PEMA_Envelopes_Digit_System indicator.

A breakout trading system based on the signals of the Color_QEMA_Envelopes_Digit_System indicator.

Buy a security (open BUY positions) at a lower price, sell (open SELL positions) at a higher price.

The BarTimer indicator implemented using the classes of libraries that were described in detail in the article "Custom indicators and infographics in CCanvas", with the possibility to set a fixed timeframe, data from which the indicator displays in input parameters.

The BarTimer indicator implemented using the classes of libraries that were described in detail in the article "Custom indicators and infographics in CCanvas", using current timeframe data.

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

A trend indicator of NRTR type using an MA and ATR.

This utility program records tick quotes in the CSV and BIN format. A flexible set of symbols is available for writing.

Standard VWAP (Volume Weighted Average Price) calculation, but with configurable start position.

Returns the profit of a position in points, as well as commission, swaps and profit in money based on the trading history.

Trades on PERIOD_M1 (M1). Calculates bullish and bearish candlesticks.

Closing all open positions with the specified profit percent.

1...404142434445464748495051525354...150