Key Takeaways
- The ZLEMA is an EMA run on adjusted prices. The ZLEMA adds the recent price change to the current price before smoothing, so the line turns sooner than a standard EMA.
- The ZLEMA still lags, just less than an EMA because ZLEMA is built from past prices, so it can only react after price moves. It reacts sooner than an EMA of the same period, but some delay always remains.
- The formula takes three steps by finding the lag with (Period − 1) ÷ 2, build the adjusted price, then apply the normal EMA formula to it.
- Faster signals come with more false signals which the ZLEMA whipsaws more than an EMA in sideways markets, so traders often confirm its signals with volume, RSI or MACD.
- Common setting starting points are 9, 20 or 21, 50 and 200 periods, depending on your trading style.
- MT4 and MT5 don't include the ZLEMA but traders can add the ZLEMA as a custom indicator made by a third party.
What Is the Zero Lag Exponential Moving Average (ZLEMA)?
The Zero Lag Exponential Moving Average (ZLEMA) is an exponential moving average calculated on adjusted prices, which makes the ZLEMA react to price changes sooner than a standard EMA. It aims to eliminate lag in traditional moving averages, so traders and investors who use technical analysis can track market trends, breakouts, trend direction, and crossover signals with a faster moving average, even though it does not remove lag completely. The ZLEMA keeps the EMA's smoothing formula and changes only the price that goes into it. John Ehlers and Ric Way created the ZLEMA in 2001, and Ehlers introduced it in his 2001 book Rocket Science for Traders.
The ZLEMA belongs to the same family as the Double Exponential Moving Average, or (DEMA), and the Triple Exponential Moving Average, or (TEMA). Like those indicators, it is built to reduce the lag of a standard EMA, but each one uses a different method. In this guide, you'll see how the ZLEMA formula works, how it compares with EMA, DEMA, and TEMA, how to interpret its signals, which settings suit different trading styles, what its advantages and limitations are, and how to add it as a custom indicator in MT4 and MT5. Because the ZLEMA turns sooner than an EMA, it can give earlier entries and exits in trend-following and crossover strategies, although sideways markets can still produce false signals.
Does the ZLEMA Really Have Zero Lag?
No, the ZLEMA tries to eliminate lag in traditional moving averages, but it does not remove it completely. The ZLEMA is still built from past closing prices, and the EMA smoothing step still averages those prices over the chosen period, so a delay remains. That delay is shorter than an EMA's delay with the same period, but it is not zero. The "zero lag" part is just what the indicator is called. It does not mean the ZLEMA moves at the same time as price. When price starts a new move, the ZLEMA only turns after the move has begun. It turns earlier than an EMA would, but never before price does.
How Does the ZLEMA Reduce Lag?
The ZLEMA reduces lag by adding the recent price change to the current price before applying the EMA, which makes the average closer to current price movements, provides a more accurate representation of price movements, and gives faster responses to market trends than a standard EMA. The averaging step stays the same as a normal EMA. Only the price that goes into it changes. To see why that works, it helps to look first at where lag comes from.
What Is Lag in a Moving Average?
Lag in a moving average is the delay, or difference between actual price moves and when the average reflects them, between a price move and the moving average reflecting that move. Lag happens because every moving average includes past prices, which hold the line back while price moves on. How much a moving average lags depends on how much weight it gives to older prices.
- A simple moving average, or (SMA) weights every price equally, so the SMA lags the most.
- An EMA weights recent prices more, so the EMA lags less.
- The ZLEMA adjusts the price before smoothing, so the ZLEMA lags even less than the EMA.
Because of lag, a moving average signal only shows up once price has already started moving, and that affects trading decisions by pushing entries and exits later than the actual turn.
How De-Lagged Price Data Works
The ZLEMA's adjusted price is the current price plus the price change over the lag period, so it is meant to reflect real-time momentum before being fed into the EMA instead of the raw close. As a purely illustrative example, if price is 110 today and was 100 at the start of the lag period, the ZLEMA feeds 120 into the EMA instead of 110.
In a trend, the adjusted price sits ahead of the current price and pulls the EMA toward it, so the ZLEMA lands closer to price than a standard EMA would and its output tracks current price action more closely. In a sideways market, the same adjustment can overshoot. A small move gets doubled, so when price turns back, the ZLEMA flips direction too. That overshoot is where the ZLEMA's whipsaws come from. The formula below puts this idea into three steps and applies a modified standard EMA formula to a de-lagged price series.
ZLEMA Formula and Calculation
The ZLEMA formula has three steps. Find the lag with (Period − 1) ÷ 2, build the adjusted price with Price + (Price − Price from Lag bars ago), then apply the EMA formula to that adjusted price.
| Component | Formula | What It Does |
|---|---|---|
| Lag | Lag = (Period − 1) ÷ 2 | Sets how many bars back the comparison price is taken from |
| Adjusted price | Price + (Price − Price from Lag bars ago) = 2 × Price − Price from Lag bars ago | Adds the change over the lag period to the current price |
| Multiplier (k) | k = 2 ÷ (Period + 1) | Same weighting multiplier as a standard EMA |
| ZLEMA | ZLEMA = (Adjusted price × k) + (Previous ZLEMA × (1 − k)) | Applies the EMA formula to the adjusted price |
Step 1: Find the Lag Period
The ZLEMA lag period equals the period minus one, divided by two, and it sets how many bars back the comparison price comes from.
Lag = (Period − 1) ÷ 2
For a 21 period ZLEMA, the lag is (21 − 1) ÷ 2 = 10 bars. A 20 period gives 9.5, and platforms round that differently, some down to 9 and some up to 10. So the same setting can show slightly different values on different charts.
| Period | Lag = (Period − 1) ÷ 2 | Whole Number Needed? | Multiplier k = 2 ÷ (Period + 1) |
|---|---|---|---|
| 9 | 4 | No | 0.2000 |
| 20 | 9.5 | Yes. Platforms round to 9 or 10 | 0.0952 |
| 21 | 10 | No | 0.0909 |
| 50 | 24.5 | Yes. Platforms round to 24 or 25 | 0.0392 |
| 200 | 99.5 | Yes. Platforms round to 99 or 100 | 0.0100 |
Step 2: Calculate the De-Lagged Price
The ZLEMA's adjusted price equals the current price plus the change in price over the lag period.
Adjusted price = Price + (Price − Price from Lag bars ago)
The short form below gives the same result.
Adjusted price = 2 × Price − Price from Lag bars ago
For a 21 period ZLEMA, that means today's close plus the move since 10 bars ago.
Step 3: Apply the EMA to the De-Lagged Price
The ZLEMA applies the standard EMA formula to the adjusted price instead of the closing price, starting with the multiplier.
k = 2 ÷ (Period + 1)
The multiplier then goes into the ZLEMA formula.
ZLEMA = (Adjusted price × k) + (Previous ZLEMA × (1 − k))
This is the normal EMA formula with the adjusted price in place of the close. The very first ZLEMA value needs a starting point, and platforms handle that start differently.
ZLEMA Calculation Example
This example calculates a 21 period ZLEMA on five real EUR/USD daily closes from 11 to 17 September 2026, alongside a 21 period EMA on the same bars. EUR/USD is an illustration only, not a trade idea. The lag is 10 bars and k = 2 ÷ 22 = 0.0909. Both lines start at the 10 September close of 1.1612 to keep the maths simple, so values differ slightly from a live chart, which uses a longer price history.
On Bar 1 (11 September), EUR/USD closed at 1.1600, and the close 10 bars earlier (28 August) was 1.1585.
Adjusted price = 2 × 1.1600 − 1.1585 = 1.1615
ZLEMA = 1.1615 × 0.0909 + 1.1612 × 0.9091 = 1.16123
The table carries the same steps through Bar 5.
| Date (Bar) | Close | Close 10 Bars Ago (Date) | Adjusted Price (2 × Close − Close 10 Bars Ago) | ZLEMA (21) | EMA (21) | Gap to Close (ZLEMA / EMA) |
|---|---|---|---|---|---|---|
| 10 Sep 2026 (start) | 1.1612 | n/a | n/a | 1.16120 | 1.16120 | n/a |
| 11 Sep 2026 (Bar 1) | 1.1600 | 1.1585 (28 Aug) | 1.1615 | 1.16123 | 1.16109 | 12 pips / 11 pips |
| 14 Sep 2026 (Bar 2) | 1.1549 | 1.1618 (31 Aug) | 1.1480 | 1.16002 | 1.16053 | 51 pips / 56 pips |
| 15 Sep 2026 (Bar 3) | 1.1544 | 1.1593 (1 Sep) | 1.1495 | 1.15907 | 1.15997 | 47 pips / 56 pips |
| 16 Sep 2026 (Bar 4) | 1.1466 | 1.1589 (2 Sep) | 1.1343 | 1.15682 | 1.15876 | 102 pips / 122 pips |
| 17 Sep 2026 (Bar 5) | 1.1476 | 1.1626 (3 Sep) | 1.1326 | 1.15461 | 1.15774 | 70 pips / 101 pips |
EUR/USD daily closing prices from Investing.com historical data, pulled 18 September 2026. 1 pip = 0.0001.
As EUR/USD fell from 1.1600 to 1.1476, the ZLEMA fell faster than the EMA. By 17 September, the ZLEMA sat about 70 pips above the close while the EMA sat about 101 pips above it. In short, the ZLEMA stayed closer to price but was still behind it. Next, here is how traders read the ZLEMA on a chart.
How to Use the ZLEMA in Trading
Traders use the ZLEMA to read trend direction, spot crossovers, mark dynamic support or resistance, and improve the timing of entry and exit points in fast-moving trends, including clearer exit points when managing trades. The ZLEMA works the same ways as other moving averages, but its signals show up sooner and change direction more often. In practice, trading ZLEMA also fits both trend-following and mean-reversion strategies.
Reading Trend Direction With the ZLEMA
The ZLEMA helps with trend identification faster than a standard EMA by using its slope and where price sits relative to the line.
- A rising ZLEMA with price above it points to an uptrend.
- A falling ZLEMA with price below it points to a downtrend.
- A flat ZLEMA with price tangled around it points to no clear trend.
These readings show what the trend has done so far, not where price will go next.
Price and ZLEMA Crossovers
A close above the ZLEMA can signal bullish momentum and serve as a potential entry for a long position, while a close below the ZLEMA can mark a shift toward bearish momentum. Many traders wait for the close to hold beyond the line before acting, and some also use reversals back below the line to exit trades, because price often crosses the line and then moves straight back. In a range, price crosses the ZLEMA back and forth, so many of these crossovers lead nowhere.
Dual ZLEMA Crossovers
A dual ZLEMA crossover uses a fast ZLEMA and a slow ZLEMA, such as 9 and 21 or 21 and 50. The fast line crossing above the slow line can mark rising momentum, and crossing below can mark fading momentum. The logic matches a standard moving average crossover. Because both ZLEMA lines react quickly, their crossovers come earlier than EMA crossovers and also flip more often.
Using the ZLEMA as Dynamic Support and Resistance
The ZLEMA can act as dynamic support in an uptrend and dynamic resistance in a downtrend. When pullbacks touch the ZLEMA and turn back, the trend is holding. A clean break through the line can be an early sign the trend is weakening. Some traders place a stop loss just beyond the ZLEMA. A stop limits your risk, but it does not remove it.
Confirming ZLEMA Signals With Other Indicators
Traders often combine ZLEMA with other technical indicators because it works better with confirmation than in isolation.
- Volume: Rising volume behind a crossover shows wider participation in the move, and volume confirmation can improve signal reliability.
- RSI: The Relative Strength Index moving the same way as the signal adds weight.
- MACD:MACD momentum in line with the move supports it.
- Key levels: Crossovers near known support or resistance carry more weight.
How well each of these works depends on the ZLEMA period you choose, which the next section covers.
Best ZLEMA Settings for Different Trading Styles
There is no single best ZLEMA setting, because the right period depends on your trading style and chart timeframe. Short term traders often start with 9 periods, 20 or 21 is a common baseline, and 50 or 200 suit slower trend filtering, with faster settings often preferred in volatile markets even though they also create more noise.
| Trading Style | Typical Chart Timeframe | ZLEMA Period | Trade Off |
|---|---|---|---|
| Scalping and fast intraday | 1 to 15 minute | 9 | Fastest reaction and most false signals |
| Day trading and swing baseline | 15 minute to 4 hour | 20 or 21 | Balance of speed and smoothness |
| Swing and position trading | 4 hour to daily | 50 | Smoother but slower to turn |
| Long term trend filter | Daily to weekly | 200 | Shows the broad trend but is very slow to react |
| Dual crossover pairs | Any | 9 and 21, 21 and 50, or 50 and 200 | Faster pairs signal sooner and flip more often |
The trade off is speed against noise. Shorter periods react faster and whipsaw more, while longer periods are smoother and slower to turn. A 50 and 200 period pairing uses the same lengths as the golden cross and death cross signals. Default lengths also differ between platforms, so check the period your ZLEMA uses before comparing it with another chart. These periods are only common starting points, so test them on your own charts before using them.
ZLEMA vs EMA, DEMA and TEMA
The EMA, DEMA, TEMA and ZLEMA all have smooth prices with exponential weighting, but each one handles lag differently. The ZLEMA changes the price that goes into one EMA, while the DEMA and TEMA combine two or three EMAs.
ZLEMA vs EMA
The ZLEMA uses the same smoothing formula as the EMA but feeds it adjusted prices, so the ZLEMA reacts sooner, responds faster to market trends than a standard EMA, and gives more false signals in sideways markets.
| Feature | EMA | ZLEMA |
|---|---|---|
| Input to the formula | Raw closing price | Adjusted price (2 × Price − Price from Lag bars ago) |
| Smoothing formula | k = 2 ÷ (Period + 1) | Same multiplier, same formula |
| Lag | Noticeable delay behind price | Less delay than an EMA of the same period, but not zero |
| Reaction to trend changes | Slower | Sooner |
| Sideways or choppy markets | Smoother, fewer whipsaws | More prone to whipsaws and false crossovers |
| Typical use | Steady trend tracking and dynamic support or resistance | Earlier trend and crossover signals when timing matters more than smoothness |
| Built into MT4 and MT5 | Yes (Moving Average, Exponential method) | No (custom indicator) |
The EMA suits steadier trend tracking, where a smooth line matters more than speed. The ZLEMA suits setups where earlier signals matter more than smoothness, especially in trending markets. Neither one is better in every market. The EMA and SMA have the same kind of trade off, where the faster line gives up some smoothness.
ZLEMA vs DEMA and TEMA
The ZLEMA, DEMA and TEMA all aim to cut the lag of a standard EMA, but each uses a different method. The ZLEMA adjusts the price input and applies one EMA. The DEMA combines an EMA with an EMA of that EMA, and the TEMA combines three layers of EMAs.
| Feature | ZLEMA | DEMA | TEMA |
|---|---|---|---|
| How it reduces lag | Adjusts the price input, then applies one EMA | 2 × EMA − EMA of the EMA | 3 × EMA − 3 × EMA of the EMA + EMA of the EMA of the EMA |
| EMA layers used | One | Two | Three |
| Built into MT5 | No | Yes | Yes |
| Built into MT4 | No | No | No |
In practice, MT5 includes the DEMA and TEMA as built in indicators but not the ZLEMA, and MT4 includes none of the three. Sources disagree on which of the three has the least lag or the fewest false signals, so this guide does not rank them. With the differences clear, the next section looks at where the ZLEMA helps and where it falls short.
Advantages and Limitations of the ZLEMA
The ZLEMA's speed is both its main strength and its main weakness, and this responsiveness helps it adapt to changing market conditions effectively. As a technical indicator, reduced lag gives earlier signals, and that same reduced lag can also make it a valuable tool while still producing more false signals in sideways markets.
Advantages of the ZLEMA
The main advantage of the ZLEMA is earlier signals, because reduced lag lets the line turn sooner than an EMA of the same period.
- Reacts much sooner to trend changes by turning earlier than a standard EMA of the same period.
- Tracks price much more closely by staying nearer to the price action while still smoothing out market noise.
- Works on any market and timeframe, making it highly versatile for forex, indices, commodities, and shares.
- Seamlessly fits into existing setups by easily replacing the standard EMA in a trader's current crossover or trend strategies.
Limitations of the ZLEMA
The main limitation of the ZLEMA is that it reacts almost instantly, so in sideways conditions and with very short settings it can be extremely sensitive to noise and produce more false signals.
- Produces more whipsaws in choppy markets by flipping back and forth when the price moves sideways.
- Still suffers from lag because it only turns after a new price move has begun, even though it turns earlier than a standard EMA.
- Can overshoot on sharp reversals because its momentum adjustment can swing it too far for a few bars before it finally settles into the new direction.
- Needs additional confirmation, meaning its signals carry far more weight when tools like volume, RSI, or MACD agree.
- Values can differ between platforms because variations in lag rounding and starting values change the numbers from one chart to another.
- It is more complex to calculate than other moving averages because it first adjusts the price and then applies EMA smoothing.
- It is not built into MT4 or MT5, meaning it must be added manually as a custom indicator.
To test the ZLEMA against these limits yourself, you first need it on a chart.
How to Add the ZLEMA to Your Trading Chart
MT4 and MT5 do not include the ZLEMA as a built in indicator, so the ZLEMA is added as a custom indicator through File > Open Data Folder. The standard Moving Average indicator offers only four methods, Simple (SMA), Exponential (EMA), Smoothed (SMMA) and Linear Weighted (LWMA).
- Get a ZLEMA custom indicator file (.mq4 for MT4, .mq5 for MT5), for example from the MQL5 Code Base or the Market inside the platform.
- In the platform, open File > Open Data Folder.
- Open MQL4 > Indicators for MT4 or MQL5 > Indicators for MT5, and paste the file there.
- Restart the platform or refresh the Navigator panel.
- Drag the indicator from Navigator onto your chart and set the period.
Custom indicator files are made by third parties, not TMGM. Only use files from sources you trust.
| Platform | ZLEMA Built In? | How to Add It |
|---|---|---|
| MetaTrader 4 | No | Place a .mq4 ZLEMA file in File > Open Data Folder > MQL4 > Indicators, then restart or refresh Navigator |
| MetaTrader 5 | No | Place a .mq5 ZLEMA file in File > Open Data Folder > MQL5 > Indicators, then restart or refresh Navigator |
Frequently Asked Questions About the ZLEMA
What Are Zero Lag Indicators?
Zero lag indicators are tools that apply a correction to reduce the delay of standard moving averages or oscillators. The ZLEMA and the Zero Lag MACD are two examples. Zero lag indicators react sooner than their standard versions, but they filter out less market noise.
What Is the Zero Lag MACD?
The Zero Lag MACD is a version of the MACD built on lag reduced averages instead of standard EMAs, usually with the same 12, 26 and 9 settings. Zero Lag MACD crossovers come earlier than standard MACD crossovers, and false signals are more frequent.
Is the ZLEMA a Leading or Lagging Indicator?
The ZLEMA is a lagging indicator that uses past prices, so it only turns after price has started a new move. The ZLEMA lags less than an EMA of the same period, but it does not predict future prices. Its signals tell you a move has started, not where price will go next.
How Do You Calculate the ZLEMA in Excel?
You calculate the ZLEMA in Excel with three columns. Column one holds closing prices. Column two, starting from the first row with a price Lag rows above it, calculates 2 × current price − price Lag rows above. Column three applies the EMA formula using k = 2 ÷ (Period + 1).

















