FX5 Divergence v2.1 Indicator for MT5 — Detect Hidden and Classic Divergences Automatically

The FX5 Divergence v2.1 Indicator is a refined MetaTrader 5 (MT5) tool that helps traders identify hidden and classic divergences between price and the OSMA (Moving Average of Oscillator). This version is optimized for accuracy, clean visuals, and ease of use, making it one of the most efficient divergence detection indicators for both forex and synthetic indices.

What is the FX5 Divergence v2.1 Indicator?

The FX5 Divergence v2.1 plots divergences directly on your chart using colored histogram bars and arrows. It automatically analyzes price and oscillator movement to highlight when momentum is weakening or reversing — key turning points that often precede strong market moves.

By comparing OSMA peaks and troughs against price highs and lows, the indicator identifies both classical divergences (momentum confirming reversal) and reverse divergences (momentum confirming continuation).

Key Features

  • Automatic Divergence Detection — Spots both bullish and bearish divergences on the OSMA without manual analysis.
  • Dual Modes — Recognizes classical and reverse divergence structures.
  • Visual Alerts — Draws colored lines between divergent points and places arrows for confirmation.
  • Customizable OSMA Settings — Choose fast, slow, and signal EMA periods for fine-tuned sensitivity.
  • Non-repainting Structure — Divergences remain fixed once confirmed.
  • Alert System — Optional pop-up alerts to notify when new divergences appear.
  • Compatible With All Assets — Works seamlessly on Forex, Synthetic Indices, Crypto, and Commodities

Download this Indicator for MT5

You can download both the ready-to-use EX5 file and the editable MQ5 source code for free below.

How It Works

The indicator uses the OSMA (Moving Average of Oscillator) formula to track momentum differences between two EMAs and the MACD signal line. When price forms a new high but the OSMA fails to confirm, a bearish divergence appears. When price forms a lower low while OSMA moves higher, it signals a bullish divergence.

FX5 Divergence v2.1 automatically draws connecting lines between these points and places directional arrows to make each signal visually clear. Solid lines represent classical divergences, while dotted lines indicate reverse ones.

Bullish Divergence

Occurs when:

  • Price makes a lower low
  • OSMA makes a higher low
    This suggests that sellers are losing strength and a possible upward reversal is near.

Bearish Divergence

Occurs when:

  • Price makes a higher high
  • OSMA makes a lower high
    This warns of a potential downward reversal as buying momentum weakens.

Reverse Divergences

Reverse divergences serve as continuation signals rather than reversals.

  • Reverse Bullish Divergence: price forms a higher low while OSMA forms a lower low.
  • Reverse Bearish Divergence: price forms a lower high while OSMA forms a higher high.

These setups often indicate momentum alignment with the main trend and confirm pullbacks instead of reversals.


Display and Visualization

The indicator plots a separate OSMA window below your main chart:

  • Green Histogram Bars: positive OSMA values showing bullish momentum.
  • Red Histogram Bars: negative OSMA values showing bearish momentum.
  • Green Arrows: bullish divergence confirmation.
  • Red Arrows: bearish divergence confirmation.
  • Lines: connect price and OSMA points showing where divergence occurred.

You can enable or disable line drawings for a cleaner layout depending on your preference.

Parameters and Customization

The indicator offers complete flexibility with several input settings:

OSMA Settings

  • Fast EMA: defines the short-term momentum period (default 12).
  • Slow EMA: defines the long-term trend filter (default 26).
  • Signal: sets the smoothing period for confirmation (default 9).
  • Applied Price: choose which price source the calculation uses (close, open, high, low, etc.).

Indicator Settings

  • Draw Divergence Lines: toggle whether connecting lines are displayed.
  • Display Alert: receive an instant alert when a new divergence forms.

How to Use It in Trading

  1. Attach the indicator to your desired chart and timeframe.
  2. Wait for divergence arrows or lines to appear.
  3. Use divergence signals to anticipate potential reversals or confirm existing trends.
  4. Combine with support/resistance, trendlines, or volume for stronger confirmation.
  5. Apply multi-timeframe analysis — for example, catch divergence on H1 to trade entries on M15.

Best Timeframes

The indicator works on all timeframes, but higher intervals such as H1, H4, and D1 provide more reliable divergence structures. Scalpers can use M5 or M15 with tighter OSMA parameters for quicker entries.


Advantages of FX5 Divergence v2.1

  • Detects momentum shifts before price reverses.
  • Helps filter false breakouts and trend exhaustion zones.
  • Improves risk-reward ratios by signaling early entries.
  • Compatible with Expert Advisors and custom scripts for automation.
  • Lightweight and optimized for low CPU use on MT5.

Practical Tips

  • Always confirm divergences with price action (candlestick patterns or key levels).
  • Avoid trading against strong trend structures without higher-timeframe confirmation.
  • Adjust EMA values to match volatility; smaller periods increase sensitivity but may produce more signals.
  • Use alerts to catch opportunities without staying glued to charts.

Installation Guide

  1. Open MetaTrader 5.
  2. Click File → Open Data Folder → MQL5 → Indicators.
  3. Copy the file FX5_Divergence_V2.1.mq5 into the Indicators folder.
  4. Restart MT5 or refresh the Navigator.
  5. Drag FX5_Divergence_v2.1 onto your chart.
  6. Customize your settings under “Inputs.”
FX5 Divergence v2.1 Indicator

Compatible Markets

  • Forex Majors & Minors (EURUSD, GBPUSD, USDJPY, etc.)
  • Synthetic Indices (Boom/Crash, Volatility 75, Pain and Flip X, etc.)
  • Commodities (Gold, Oil, Silver)
  • Cryptocurrencies (BTCUSD, ETHUSD, etc.)

Why Traders Prefer FX5 Divergence v2.1

Traders use it for clear reversal alerts, visual simplicity, and adaptability. Unlike most divergence indicators that repaint or clutter charts, this version keeps signals fixed once confirmed and gives a balanced view of both market structure and momentum dynamics.

It’s ideal for traders who want to combine momentum analysis with price structure recognition without needing multiple indicators.

Trading Strategy Example

A common strategy is to combine FX5 Divergence with a moving average trend filter or support/resistance levels:

  • Look for bullish divergence at strong support.
  • Wait for a bullish candlestick close above the moving average.
  • Enter buy, place stop loss below the divergence low, and target recent resistance.
    The same logic applies inversely for bearish setups.

Conclusion

The FX5 Divergence v2.1 for MT5 is an advanced yet user-friendly indicator that simplifies the art of divergence trading. It detects both hidden and classical divergences automatically, helps traders read momentum changes earlier, and visually connects price and oscillator data in an intuitive format.

Whether you’re trading forex, synthetic indices, or cryptocurrencies, this indicator delivers reliable divergence insights that can significantly enhance your timing and accuracy.

Download this Indicator for MT5

You can download both the ready-to-use EX5 file and the editable MQ5 source code for free below.

Share your love
0 0 votes
Article Rating
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments