Watch how to download trading robots for free
Find us on Telegram!
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

Top MQL4 and MQL5 source codes based on user ratings - 29

Submit your code

Two histograms in one window, showing the maximum average price deviation in points from the initial value.

The Expert Advisor trades based on iMA and iRSI signals. Values of iMA on four bars are compared. Indices of these bars can be optimized.

Woodies CCI is a momentum indicator that was developed by Ken Woods. It's based on a 14 period Commodity Channel Index (CCI).

This version is a sort of normalized version - since it shows Volume as a percent compared to the Average Volume over a chosen period.

The script draws horizontal lines representing BUY (blue) and SELL (red) orders.

Indicator of volumes accumulated.

Handy functions for comparison, rounding, formatting and debugging of doubles (prices, lots and money).

Panel indicator with the date on closed positions.

Working with pending Buy Limit and Sell Limit orders. Grid of pending orders.

The EA based on iCCI (Commodity Channel Index, CCI) indicator plus managing position volumes using martingale.

Working with pending Buy Stop and Sell Stop orders.

The EA based on iMACD (Moving Average Convergence/Divergence, MACD) and iStochastic (Stochastic Oscillator).

SuperTrend indicator

Step average - standard deviation based

VZO

Indicator VZO

Ergodic TSI (True Strength Index) as described by William Blau

Indicator RSI Overlay

Advance Parabolic Time/Price System

Correlation market state

Strategy based on the standard indicator iCHO (Chaikin Oscillator, CHO) and custom indicator 'CCIDualOnMA'

Custom Hammer and Inverted Hammer

This function performs the main logic of opening a trade. It calculates the opening price, take profit levels and stop loss based on the symbol information and parameters provided by the user. Prepare a trade request (MqlTradeRequest) with the necessary information such as symbol, volume, order type, slippage, comment, magic number, etc. Call the OrderSend function to send the trade request and get the result. SetTypeFillingBySymbol function: determines the order fulfilment type (Fill or Cancel, Immediate or Cancel or Return) according to the symbol's fulfilment policy. GetMinTradeLevel function: calculates the minimum trade level based on the freeze level and stop level of the symbol. Adjusts the minimum level to ensure that it is within certain limits and returns the result.

Rsi Ea using RSI signals with ATR volatility-based stops, automatic position sizing, scale-out feature, and trading session filter

A short format for storing ticks.

The Bollinger Bands ® Indicator (BB) is similar to Envelopes. The only difference is that the bands of Envelopes are plotted a fixed distance (%) away from the moving average, while the Bollinger Bands are plotted a certain number of standard deviations away from it.

An indicator lets you specify the number of bars separately before and after the current High / Low (fractal) can.

This indicator fits a trigonometric model to prices and extrapolates it in the future.

The Panel Designed for "Best Graphic Panel in MQL5" Contest. This graphic panel allows to automate manual trading. It has many functions, including the visual construction of trading strategies.

The ZigzagColor_Channel plots a channel by connecting the ZigZag peaks and ZigZag bottoms.

Trade signals based on reversal candlestick patterns is considered. The code of the Expert Advisor based on this strategy can be generated automatically using the MQL5 Wizard.

Trade signals based on "Morning Star/Evening Star" candlestick pattern, confirmed by Stochastic indicator is considered. The code of the Expert Advisor based on this strategy can be generated automatically using the MQL5 Wizard.

The script downloads historical data (for the current symbol), available at trade server.

Trade signals based on "Bullish/Bearish Meeting Lines" candlestick pattern, confirmed by Market Facilitation Index (MFI) indicator is considered. The code of the Expert Advisor based on this strategy can be generated automatically using the MQL5 Wizard.

BrainTrend2Sig is an indicator of the market trends that assigns colors to candlesticks according to the trend direction.

Multi-currency Expert Advisor functional module for organization of an access to any historical data with a request result processing.

Set of Keltner Channels based on the universal smoothing.

This indicator determines trend power and direction.

New CCalendarInputBox control element of the IncGUI library has been designed for date and/or time input.

Ergonomic Parabolic SAR. The indicator itself is a two-color one and it also adds large colored dots that appear during each trend reversal.

The indicator transfers the price data to the new coordinates system associated with X2MA indicator values.

1...222324252627282930313233343536...200