How to Set a Trailing Stop-Loss on MT5?

By Ritika Tiwari

MetaTrader 5 logo next to a hand stopping a row of wooden blocks from toppling over,

Setting a trailing stop-loss on MT5 allows traders to manage risk by automatically adjusting the stop-loss level. As the trade moves in the trader's favor, the stop-loss locks in gains while minimizing potential losses. A trailing stop-loss allows traders to remove emotional biases, capture trends, and stick to their trading plan without constant monitoring. 

Let’s take a look at how to set a trailing stop loss in MT5.


Stepwise guide to set trailing stop-loss on MT5

Log into the MT5 platform 

Launch the MetaTrader 5 (MT5) platform on the computer or mobile device and enter login credentials to access the trading account.

image source

Access desired instrument's chart 

Navigate to the chart of the financial instrument for which the trader wants to set a trailing stop-loss. Traders can do this by searching for the instrument in the Market Watch window or selecting it from their favorite instruments.

image source

Right-click to open context menu

Once the trader has located the desired instrument's chart, right-click anywhere on the chart to open the context menu. The context menu appears when one right-clicks on the platform. It provides options for trading, chart customization, and technical analysis tools.

image source

Select ‘trading’ from menu 

In the context menu, hover over or click the ‘trading’ option to reveal additional trading-related actions such as placing new orders, modifying existing orders, and accessing trading-related tools and functions.

image source

Choose ‘new order’ 

Select the ‘new order’ option from the' trading' submenu. It will open a new order window where traders can enter the details of their trade.

image source

Enter trade details

In the new order window, specify the trade volume (lot size) and select the order type (market or pending order) according to the trading strategy.

image source

Specify stop loss level

In the new order window, locate the ‘stop loss’ field and enter the desired stop-loss level. This is the price at which the trader wants their trade to be automatically closed if the market moves against them.

image source

Activate trailing stop option

Below the Stop Loss field, the trader will find an option to enable the trailing stop feature. To activate this feature, check the box next to ‘trailing stop’.

image source

Set trailing stop distance

Once the trader has enabled the trailing stop option, specify the distance (in pips) at which they want the trailing stop to trail the market price. This distance determines how far the trailing stop will be from the current market price.

image source

Confirm settings

Review the trade details, including the trailing stop-loss parameters, to ensure they are correct.

image source

Execute trade

Once the trader is satisfied with the trade details and trailing stop-loss settings, click the ‘Buy’ or ‘Sell’ button (depending on the trade direction) to execute the trade and set the trailing stop-loss.

image source


Top 4 tips to set trailing stop loss on MT5

Custom trailing stop indicators

With MT5, traders can create and install custom indicators, including those for trailing stops. By utilizing or developing custom trailing stop indicators aligned with their trading strategies, users can access real-time feedback on optimal trailing stop levels. These indicators consider market conditions, technical analysis, and specific trading rules, enabling traders to set effective trailing stop-loss levels.

Use ATR indicator

Average True Range (ATR) as an indicator is a reliable measure of market volatility, offering insights into the current market conditions. By incorporating the ATR indicator into trailing stop strategies, traders can set trailing stop distances proportional to the prevailing level of volatility. For instance, traders may set the trailing stop distance as a multiple of the ATR value, facilitating adjustment to changing volatility levels and enhancing risk management practices.

Employ Breakout confirmation

Breakout confirmation is a trigger for trailing stop adjustments because it validates the strength of the prevailing trend. Traders may wait for a breakout above significant resistance levels before tightening trailing stops on long positions. This strategic approach validates the trend's strength, mitigating the risk of premature stop-outs during periods of heightened price volatility and uncertainty.

Implement partial trailing stops

Partial trailing stops are recommended to manage risk and incrementally secure gains. Rather than adjusting the stop-loss level, traders can modify only a portion of the position's stop-loss level as the trade progresses favorably. This tactic allows traders to lock in gains gradually while providing the remaining portion of the position with the opportunity to capture additional gains.


How to create a custom trailing stop-loss indicator on MT5?

1-   Open MetaEditor, the integrated development environment (IDE) in MT5.

2-    In MetaEditor, navigate to File > New > Indicator to create a new custom indicator file. 

3-   Define indicator properties such as calculation method and display settings.

4-    Implement trailing stop logic from tracking price highs/lows and calculating stop distances based on user-defined parameters such as ATR or a fixed percentage.

5-    Include code to handle indicator initialization, such as initializing variables and setting up buffers for storing indicator values. 

6-    Draw trailing stop levels on the price chart using graphical objects.

7-    Compile the indicator in MetaEditor to check for errors and generate the .ex5 file.

8-    Test the indicator on historical price data to ensure accuracy.

9-   Deploy the indicator by copying the .ex5 file to the ‘Indicators’ folder in the MT5 directory.

10- Apply the custom indicator to price charts in MT5 via the ‘Navigator’ panel for usage.


Navigating the forex markets with trailing stop losses

Integrating trailing stop-loss settings into MT5 orders enables traders to adapt to market movements, minimize emotional biases, and maximize trading discipline. By capitalizing on opportunities while effectively managing risk, traders can enhance their trading efficiency with trailing stops. 


Disclaimer:

All material published on our website is intended for informational purposes only and should not be considered personal advice or recommendation. As margin FX/CFDs are highly leveraged products, your gains and losses are magnified, and you could lose substantially more than your initial deposit. Investing in margin FX/CFDs does not give you any entitlements or rights to the underlying assets (e.g. the right to receive dividend payments). CFDs carry a high risk of investment loss.

Picture of Ritika Tiwari

About the author

Ritika Tiwari

Ritika Tiwari is a freelance content writer and strategist at Blueberry Markets, specializing in forex, CFDs, stock markets, and cryptocurrencies. She has over 10 years of experience building content for FinTech and SaaS B2B brands. Outside of work, you’ll likely find her somewhere near the ocean.