Built from the gap between two moving averages
MACD (Moving Average Convergence Divergence) is a momentum indicator: the gap between a 12-day and a 26-day exponential moving average of price. Its signal line is a 9-day average of that gap, and the histogram shows the distance between the two. MACD lags price, so it confirms a candlestick pattern rather than predicting a turn.
MACD stands for Moving Average Convergence Divergence. Gerald Appel developed it in the 1970s, and it answers one question:
Is the push behind price building or fading?
To answer it, MACD compares two exponential moving averages (EMAs) of the closing price. An EMA is an average that gives more weight to recent days. Momentum is how fast price is moving in one direction — the push behind it. MACD uses a fast one (12 days, about two and a half weeks of trading) and a slow one (26 days, about five weeks).
When the fast average pulls away above the slow one, recent prices are rising faster than the longer trend: upside momentum is building. When it pulls away below, downside momentum is building. The name describes this: the two averages converge when momentum fades and diverge when it builds. Don’t confuse this with MACD divergence, covered below — that is a different idea: price and MACD disagreeing.
A MACD panel shows two lines and a set of bars. Each comes from the one before:
| Part | How it’s calculated | What it tells you |
|---|---|---|
| MACD line | 12-day EMA − 26-day EMA | Which way momentum points, and how strongly |
| Signal line | 9-day EMA of the MACD line | A smoothed version of MACD — its recent average |
| Histogram | MACD line − signal line | Whether MACD is speeding up or leveling off |
The histogram was added by Thomas Aspray in 1986. It adds no new information; it just makes the distance between MACD and its signal line easier to see.
MACD is built from moving averages, but it is not a moving average of price. It is the gap between two of them. That gap measures how fast price is moving, not how high it is.
When price climbs quickly, the fast average races ahead of the slow one and the gap widens. When price climbs slowly, the slow average keeps up and the gap stays small.
Picture two rallies. The first runs from $80 to $100 in two weeks. After a pullback to $92, the second grinds up to $104 over five weeks, slowing as it goes. Price makes a new high at $104, but it got there slowly, so the gap never opens as wide. MACD peaks lower the second time.
Price says the trend is still going up. MACD says the push behind it is weaker. That disagreement is called divergence, and it is covered below.
MACD is zero when the two averages are equal. Which side of zero it sits on tells you the direction of the shorter-term trend:
Above zero: the 12-day average is above the 26-day, so the shorter-term trend is up. Below zero: it is below, and the shorter-term trend is down.
A zero-line cross is the moment the two averages cross. It usually comes well after a signal-line cross, because MACD has to climb all the way from its low. That makes it a poor entry signal but a useful description of the trend a candle forms in.
The signal line is a smoothed version of MACD. When MACD crosses above it, momentum has turned up compared with its recent average. When MACD crosses below it, momentum has turned down. This is the classic MACD signal.
On its own, a crossover says little. What gives it meaning is where it happens:
MACD stops falling and turns up through its signal line while still far below zero. Downside momentum is fading. This can be the first sign of a recovery, and it is where a bullish reversal candle gains the most from MACD.
Price pulls back, MACD dips toward zero, then crosses back above its signal line. Momentum is picking up again in the direction of the trend. This is a continuation signal, not a reversal.
MACD dips just under its signal line, then turns back up through it. The trend is already stretched, so this is often a short pause in a mature rally. It adds little, and buying it can mean buying late.
The crossover tells you momentum changed. The zero line tells you which trend it changed in. Always read them together. For bearish crosses, flip each case.
The histogram is MACD minus its signal line, drawn as bars above and below zero. It is the easiest part of MACD to read:
Bars getting longer (above or below zero): MACD is pulling away from its signal line, so momentum in that direction is strengthening. Bars getting shorter: MACD is still moving the same way, but it is no longer speeding up.
Shorter bars do not mean MACD has turned. It can still be rising, just more slowly. In a steady trend that is normal: MACD has caught up with the move. When bars shrink while price is also slowing near a high or low, it can be an early sign the move is tiring.
When the histogram crosses zero, MACD is crossing its signal line. They are the same event, shown two ways.
Divergence is when price reaches a new high or low and MACD does not. It happens because MACD measures speed, not level.
Bearish divergence: price makes a higher high, but MACD makes a lower high. Price went further, but the push behind it was weaker. Bullish divergence: price makes a lower low, but MACD makes a higher low. The decline continues, but each leg down has less momentum. On-Balance Volume reads the same disagreement from volume instead of momentum.
The first rally is fast, so MACD surges. The second rally reaches a higher price, but slowly, and MACD peaks well below its first high. Each bearish cross (red dot) comes only after price has already topped.
Treat divergence as a warning. It can last through several more highs while the trend carries on, and it does not always end in a reversal. Its value is in telling you where to look: a bearish reversal candle at a new high is more convincing when MACD makes a lower high beneath it.
A candlestick pattern tells you where and when buyers or sellers reacted. MACD tells you whether momentum is turning the same way. Use them together in three steps:
Higher highs and higher lows mean an uptrend. Lower highs and lower lows mean a downtrend. Neither means a range, where MACD crosses back and forth most.
In an uptrend, you want MACD rising and above zero. In a downtrend, falling and below zero. When they agree, a pattern in the direction of the trend has momentum behind it.
If price is still rising but the histogram is shrinking or a bearish divergence is forming, be more cautious, and pay attention to bearish reversal candles. The same applies in reverse at the bottom of a decline.
For example, a Hammer at support after a long decline shows buyers rejecting lower prices. If MACD is also turning up from well below zero and has just crossed its signal line, momentum is turning with the candle. The candle and the momentum read agree.
Now take a Bullish Engulfing that prints while the histogram bars below zero are still getting longer. Downside momentum is still speeding up, so the candle is going against momentum. It may still work, but the candle and momentum disagree.
Four questions for any MACD panel: Is MACD above or below zero? Has it crossed its signal line? Is the histogram growing or shrinking? Does MACD agree with price?
In the 42Fibonacci screeners, a result shows a MACD crossed up chip on the bullish screeners, or MACD crossed down on the bearish ones, when that cross happened in the last few sessions.
It can’t call the turn. MACD is built from averages of past prices, so its crosses come after price has already turned. Only a slowdown, such as shrinking histogram bars or a lower MACD high, can show up earlier.
It struggles in sideways markets. When price goes nowhere, the two averages sit close together and the lines cross back and forth on small moves. Few of those crosses lead anywhere.
Its values can’t be compared between stocks. MACD is measured in dollars, so a $500 stock produces bigger readings than a $20 stock for the same percentage move. Read its shape, not its number.
It has no overbought or oversold levels. Unlike RSI, MACD has no fixed range, so there is no line where momentum is “too high.”
A stock has rallied for three weeks. MACD is far above zero. It dips just under its signal line, then crosses back above it. Someone says: 'MACD just crossed up. Buy.'
What's missing from this reasoning?
Location. A bullish cross far above zero, after a long rally, is usually a short pause and restart, not a new move. Buying it means buying late, with a sensible stop a long way below. Better questions: Is the histogram growing, or barely above zero? Is price at resistance? Is price making a higher high while MACD makes a lower one? Without a candlestick pattern at a level, the cross is just noise.
| Mistake | Instead |
|---|---|
| Trading every crossover MACD crossed above the signal line. That is my buy. | A crossover only says momentum turned compared with its recent average. Check where it happened, what the trend is, whether volume supports the move, and whether resistance is overhead. The cross is one piece of evidence, not the decision. |
| Using MACD in a sideways market Three crosses in two weeks. MACD is giving me plenty of signals. | In a range, the averages hug each other and cross on every small swing. Frequent crosses mean there is no trend for MACD to measure. |
| Treating divergence as a reversal call Bearish divergence. The top is in. Time to short. | Divergence says momentum is fading. Trends can make several divergent highs before turning, and some never turn. Wait for a bearish candlestick pattern and its confirmation. |
MACD (Moving Average Convergence Divergence) is a momentum indicator developed by Gerald Appel in the 1970s. It subtracts a 26-day exponential moving average of price from a 12-day one. When the fast average pulls away above the slow one, upside momentum is building; when it pulls away below, downside momentum is building.
The signal line is a 9-day exponential moving average of the MACD line: a smoothed version of MACD, its recent average. When MACD crosses above it, momentum has turned up; when MACD crosses below it, momentum has turned down.
The histogram is the MACD line minus the signal line, drawn as bars. Longer bars mean MACD is speeding up; shorter bars mean it has stopped speeding up. In a steady trend that is normal, but bars shrinking while price stalls near a high or low can be an early warning. When the histogram crosses zero, MACD is crossing its signal line.
Not on its own. A crossover says momentum has turned compared with its recent average, not that price will follow. Where it happens matters: a bullish cross well below zero can be the first sign of a recovery, while one far above zero is often a short pause in a long rally. Use it to confirm a candlestick pattern, not as the trigger.
MACD crosses zero when the 12-day EMA crosses the 26-day EMA. Above zero, the shorter-term trend is up; below zero, it is down. A zero-line cross usually comes well after a signal-line cross, so it describes the trend well but is a poor entry signal.
Divergence is when price and MACD disagree. Bearish divergence: price makes a higher high while MACD makes a lower high, so the push behind the new high was weaker. Bullish divergence is the opposite: a lower low in price with a higher low in MACD. Divergence is a warning that momentum is fading; it can last for weeks, and the trend can continue through it.
Lagging. MACD is built from averages of past prices, so its crosses come after price has already turned. What it can show early is a slowdown, such as a lower MACD high at a new price high, which warns that momentum is fading before price reverses. Let a candlestick pattern and its confirmation do the timing.
They answer different questions. RSI runs from 0 to 100 and tells you how stretched a move is, with overbought and oversold levels. MACD has no fixed range and tells you whether momentum is building, fading, or turning. Used together, they tell you whether a move is stretched and whether it is still gaining momentum.
They are the settings Appel published, and nearly every charting platform uses them, so what you see matches what other traders and most published examples show. Faster settings react sooner but cross more often on noise; slower ones are steadier but later.
Not directly. MACD is measured in dollars, so a reading of 2 is a large gap for a $40 stock and a small one for a $900 stock. Compare a stock's MACD with its own recent history, or read its shape (crosses, histogram, divergence), which works at any price. The Percentage Price Oscillator divides the same gap by the slower average to make it comparable across stocks.
MACD doesn’t make a candlestick pattern work. It tells you whether momentum is turning the same way as the candle, or quietly pulling the other way.
So when you check MACD behind a pattern, ask one question: “Does momentum agree with this candle?” A bullish pattern with MACD rising from below zero and the histogram growing says yes. The same pattern with the histogram still growing to the downside says not yet. A new high that MACD won’t confirm says the move has less behind it than it looks.
This is one of seventeen context guides in this series: Candlesticks + Moving Averages for trend structure, Candlesticks + RSI for how stretched a move is, Candlesticks + ADX for trend strength, Candlesticks + Volume for conviction, Candlesticks + On-Balance Volume for volume flow, Candlesticks + Accumulation/Distribution for where the close fell, Candlesticks + Volume Spread Analysis for reading each bar’s effort and result, Candlesticks + Volume Profile for the prices where volume traded, Candlesticks + Anchored VWAP for the average price paid since a turn, Candlesticks + Fibonacci for retracement levels, Candlesticks + ATR for volatility, Candlesticks + Bollinger Bands for volatility bands around an average, Candlesticks + Multi-Timeframe Analysis for the weekly trend, Candlesticks + 52-Week High/Low for where price sits in its yearly range, Candlesticks + Trend Channels for where in the trend price sits, and Candlesticks + Trading Ranges for sideways markets. New to candles? Start with the candlestick basics guide.