
Confirmed, no-repaint multi-timeframe divergence signals.
Download the Indicator
Deep MTF Divergence No-Repaint Pro runs a MACD/OsMA momentum histogram on a higher timeframe of your choice and cross-checks it against ZigZag/fractal price extremes to catch regular bullish and bearish divergence. Its core mechanic: on every closed candle of your current chart timeframe, the indicator recalculates and displays exactly what the higher-timeframe histogram looks like at that precise moment — not just once per higher-timeframe bar, but bar by bar on your own chart. Each divergence signal then unfolds through three clearly separated stages — grey warning, gold "get ready", and a final red/green confirmed arrow — so you can watch a setup build in real time and only act once it is fully confirmed.
The signature feature of this indicator: instead of waiting for the higher timeframe bar to close, the histogram value is rebuilt from scratch on every closed bar of your current chart, using that bar's own close price as the projected close of the still-forming higher-timeframe candle.
Pick any timeframe in TimeFrame_Select — from the current chart up to MN — and the indicator maps every current-chart bar to the higher-timeframe bar it belongs to automatically.
Every divergence setup is shown as it develops: a grey warning arrow, then a gold "get ready" arrow, and finally a red (sell) or green (buy) confirmed, no-repaint arrow once the higher-timeframe bar actually closes.
A ZigZag built from a rolling high/low search window is cross-checked against 5-bar fractals, so only extremes confirmed by both methods become valid divergence anchor points.
UsePrevHighFilter requires the current histogram extreme to actually be weaker than the previous, already-closed higher-timeframe bar's extreme before a confirmed arrow is drawn.
UseEmaFilter only confirms a signal once the histogram has also crossed its own Signal EMA in the expected direction, adding a second, independent momentum check.
This is what sets Deep MTF Divergence No-Repaint Pro apart from an ordinary "MACD on a higher timeframe" indicator. A naive multi-timeframe histogram only updates once per higher-timeframe bar — on H1, for example, you would only see the value change once every hour, no matter which chart you're actually watching. This indicator works differently:
base_fastEMA[s_sync+1], base_slowEMA[s_sync+1], base_signalEMA[s_sync+1]) is carried forward and updated one more step using the current bar's close.TimeFrame_Select set to H1, you get a fresh, accurate read of the H1 momentum state on every closed M15 candle — four updates per hour instead of one — without ever repainting the already-confirmed part of the histogram.| Why it matters for divergence | Divergence setups are time-sensitive — the earlier you see the higher timeframe starting to lose momentum, the earlier you can prepare. This mechanic lets you see that shift the moment it happens on your own chart, instead of waiting up to a full higher-timeframe bar to find out. |
|---|---|
| Why it doesn't repaint | Everything before the currently forming higher-timeframe bar is calculated once, from fully closed historical bars, and is never touched again. Only the projection for the still-open higher-timeframe bar changes — and once that bar closes, its value is fixed for good, exactly like the rest of the history. |
| Histogram & separator | The same recalculated value drives the visible histogram (histUp / histDn / histNe), so the plotted momentum reflects the current-chart-bar-by-bar projection described above. A vertical separator line is drawn at the open of every higher-timeframe bar so you can see exactly where one higher-timeframe candle ends and the next begins. |
Each divergence setup is checked on every closed bar of your current chart and passes through up to three stages, colour-coded so you always know how mature a setup is:
| Bearish (SELL) setup | Builds when price prints a new high beyond the zone's ZigZag high while the projected momentum histogram fails to exceed its own prior extreme — a classic "higher high, weaker momentum" pattern. Shown with down-pointing arrows above the histogram. |
|---|---|
| Bullish (BUY) setup | The mirrored pattern — price prints a new low beyond the zone's ZigZag low while the histogram fails to make a new low. Shown with up-pointing arrows below the histogram. |
| From Warning to Get Ready | The jump from grey to gold requires two extra conditions at once: price must clear the ZigZag extreme by the full HiLoDist value for the active timeframe, and the still-open higher-timeframe candle must flip direction relative to its own open. |
| From Get Ready to Signal | The gold arrow only becomes a confirmed red/green arrow once the higher-timeframe bar closes and its final close price confirms the same reversal — plus, if enabled, the PrevHigh and EMA filters both agree. |
Each timeframe from M1 to MN has its own independent HiLoDist value, in points, automatically selected to match the TimeFrame_Select input. This is the minimum distance a price extreme must clear the zone's ZigZag level by before the setup is allowed to progress from a grey warning into a gold "get ready" arrow, and later into a confirmed signal — scaled from a tight M1 setting up to a wide MN setting so the filter always matches the volatility of the timeframe you're trading.
| HiLoDist_M1 / M5 / M15 / M30 | 20 / 30 / 70 / 100 points by default — tight thresholds suited to intraday noise levels. |
|---|---|
| HiLoDist_H1 / H4 | 200 / 250 points by default — wider thresholds for swing-level moves. |
| HiLoDist_D1 / W1 / MN | 500 / 1000 / 1000 points by default — sized for daily and higher timeframe swings. |
| Where it applies | Used identically for the gold "get ready" arrow (against the live, still-forming higher-timeframe bar) and for the confirmed red/green signal (against the higher-timeframe bar's final high/low), so both stages are held to the same distance requirement. |
The TimeFrame_Select input picks which timeframe the whole divergence engine runs on — it can equal the current chart or any higher timeframe up to MN. Whenever the number of bars on that timeframe changes, the indicator rebuilds its base dataset from scratch in a dedicated PrecalculateBase() routine, so the underlying calculation always stays perfectly in sync with fresh price history.
| Stage 1 — Momentum histogram | A Fast/Slow EMA pair is computed bar by bar on the selected higher timeframe to build the MACD value; the ShowOsma switch decides whether the histogram plots raw MACD or MACD minus its own Signal EMA (OsMA). The running high/low of the current histogram zone is tracked at the same time. This closed-bar dataset is exactly what the "state on every lower-timeframe close" feature projects forward from. |
|---|---|
| Stage 2 — ZigZag construction | For every bar, a forward search window sized by ZZDepth looks for the lowest low and highest high; a candidate extreme is kept only if it clears the current running ZigZag point by more than ZZDev points, with ZZBackstep preventing two extremes from forming too close together. Each ZigZag point is then matched against a genuine 5-bar fractal at the same price. |
| Stage 3 — Divergence zones | Each momentum zone (the stretch between two zero-line crosses) gets its own running maximum/minimum ZigZag price and running maximum/minimum histogram value, searched within LookForwardBars and Lastcandel respectively — these become the reference points every new bar is compared against for divergence. |
| History | The History input caps how many bars back the main loop recalculates on every tick; set it to 0 to process the full available history. |
| UsePrevHighFilter | When enabled, a confirmed sell signal additionally requires the current zone's histogram extreme to be weaker than the previous, already-closed higher-timeframe bar's extreme (and the mirrored check for buy signals) — this removes divergences that aren't actually a step down (or up) in momentum strength. |
|---|---|
| UseEmaFilter | When enabled, a confirmed signal also requires the histogram's own Signal EMA to sit on the correct side of the current histogram value at the moment of confirmation, adding a second, independent momentum check before the confirmed arrow is drawn. |
| ShowSignalEma | Independently of the filter, this switch plots the Signal EMA of the histogram as its own line on the indicator window so you can see the exact value the EMA filter is comparing against. |
| ZZDepth | Size of the forward search window (in bars) used to find each candidate ZigZag high/low. |
|---|---|
| ZZDev | Minimum deviation, in points, a new extreme must clear the current running ZigZag point by before it replaces it. |
| ZZBackstep | Minimum bar spacing enforced between two ZigZag extremes of the same type, preventing extremes from clustering too closely together. |
| MinAmplitude | Optional minimum price distance, in points, between two consecutive confirmed fractal/ZigZag points on the same side; set to 0 to disable and accept every qualifying fractal. |
| ArrowOffset | Vertical spacing, in points, between an arrow and the histogram value it marks. |
|---|---|
| SizeDynamic | Size of the grey warning and gold "get ready" arrows. |
| SizeConfirmed_MTF / SizeConfirmed_Signal | Size of the confirmed red/green arrow — automatically larger when the engine runs on a higher timeframe than the chart, and smaller when it runs on the current timeframe itself. |
| ColorYellowArr / ColorRedArr / ColorGreenArr | Colors for, respectively, the grey warning arrows (default dark grey) and the gold "get ready" arrows on sell/buy setups (default gold). |
| ColorOrangeArr / ColorBlueArr | Colors for the final confirmed, no-repaint sell and buy arrows — red and green (lime) by default. |
| EnablePopupAlert / EnableSoundAlert / SoundFile | A confirmed (red/green) arrow can trigger an on-screen popup and/or play the sound file set in SoundFile (default alert.wav); each higher-timeframe bar can only trigger one alert, so re-quoting an already-confirmed bar never fires a duplicate. |
Deep MTF Divergence No-Repaint Pro.ex4 from the link at the bottom of this page.MQL4 → Indicators.Indicators folder.A regular higher-timeframe MACD only updates once per higher-timeframe bar. This indicator recalculates the projected higher-timeframe value on every close of your own chart's timeframe, so you see the higher-timeframe momentum state shift far sooner — without repainting anything already confirmed.
Grey is an early warning — price has broken the zone extreme while the higher-timeframe candle is still forming in its original direction. Gold means "get ready, possible signal" — the setup has cleared the Hi/Lo distance filter and the projected higher-timeframe candle has turned. Red (sell) or green (buy) is the final, no-repaint confirmed signal, plotted only after the higher-timeframe bar has actually closed.
Yes — both are based on the still-forming higher-timeframe bar, so they can appear, move or vanish as new lower-timeframe candles close and the projection updates. Only the red/green confirmed arrow, drawn after the higher-timeframe bar closes, is final.
Yes, that's the main use case. Set TimeFrame_Select to any higher timeframe and the indicator maps every current-chart bar to its parent bar on that timeframe automatically, refreshing the projected state on every one of your own chart's closed candles.
UsePrevHighFilter compares the current momentum extreme to the previous, already-closed higher-timeframe bar's extreme. UseEmaFilter checks the histogram against its own Signal EMA. Both can be used together for stricter confirmation, or turned off independently.
A price extreme only becomes a valid divergence anchor point if it is confirmed both by the ZigZag's high/low search window and by a genuine 5-bar fractal at the same price — this two-way check filters out noisy, low-quality swing points.
No. The indicator tracks the last higher-timeframe bar it already alerted on, so a confirmed signal only ever alerts once, and only the confirmed red/green arrow can trigger an alert.
Get the indicator and watch confirmed, no-repaint multi-timeframe divergence signals build in real time.
Download Deep MTF Divergence No-Repaint Pro Indicator