WhitmanTrading

What Is MACD?

MACD is the distance between a twelve-period and a twenty-six-period exponential moving average, drawn as a line. A nine-period average of that line is the signal line, and the histogram is the gap between the two. It is a trend-following tool built entirely from moving averages.

What Is MACD? — illustrated on a chart Watch me read trend on a live chart (15:03)

MACD looks more sophisticated than it is. Underneath the panel and the three components there is one subtraction, and knowing that changes what you should reasonably expect from it.

How it works

MACD is the distance between two exponential moving averages.

A candlestick chart with a twelve-period and a twenty-six-period exponential moving average drawn on it.
A fast average and a slow one. MACD is the gap between them. Illustrative chart - not real market data.

Take the twelve-period average and subtract the twenty-six-period one. When the fast average is above the slow one the result is positive; when it is below, negative. Plot that number and you have the MACD line.

A price chart with a MACD panel showing two lines and a histogram beneath it.
The MACD line, its signal line, and the histogram between them.

Two more pieces sit on top of it. The signal line is a nine-period average of the MACD line — an average of an average. The histogram is the gap between those two.

So all three components come from the same subtraction. Nothing on this panel knows anything the two moving averages did not.

The zero line

The MACD panel with the moment the line crosses zero annotated.
Zero is where the two averages are equal. Crossing it means they swapped places.

MACD equals zero when the two averages are equal. Above zero, the fast average is above the slow one; below zero, beneath it.

This makes the zero line the more meaningful of the two crossings on the panel, and it is discussed far less than the signal cross.

The histogram

The MACD panel with the tallest histogram bar annotated as the widest gap between the lines.
Tallest bar, widest gap. The bars are a distance, not a quantity.

The histogram is not volume and it is not strength. It is the vertical distance between the MACD line and its signal line, drawn as bars.

Tall bars mean the two lines are far apart, which means the fast average is pulling away from the slow one — the averages are separating quickly. Shrinking bars mean they are converging, which usually happens before a crossover for the simple reason that a crossover is what happens when the gap reaches zero.

What 12, 26 and 9 actually change

Three inputs, and each one does something you can state plainly.

The fast length (12) sets how quickly the line reacts. Lower it and the line becomes jumpier and crosses more often.

The slow length (26) sets the baseline it is measured against. Raising it makes the line slower and the zero crossings rarer.

The signal length (9) only smooths the line that already exists — it changes when crossovers happen and nothing about the market being measured.

Two of the three change what is measured. The third changes only when you are told about it. More crossings is not more information, which is the thing to hold onto before tuning any of them.

The crossover, honestly

The MACD panel with the point where the MACD line crosses above its signal line marked.
The MACD line crosses above the signal line. The classic entry.
The same crossover with the stretch between the low and the cross shaded on the price chart.
The shaded stretch is what happened before the signal fired.

Here are the actual numbers from that chart. The low was 98.26 and the eventual high was 103.55. The cross fired with price at 100.42.

So the signal arrived after part of the move — and left 59% of it still ahead. That is a perfectly respectable result for a lagging indicator, and it is worth saying rather than repeating the usual line that crossovers are hopeless.

The problem is not this chart. It is the next one.

A worked example

Read the trend chart forward, using the panel as a filter.

The falling stretch. MACD is below zero and below its signal. The fast average is under the slow one and falling away from it. The useful conclusion is negative: not a place to look for longs.

The base. The line drifts back toward zero and the histogram bars shrink to almost nothing. This is the reading that matters most and gets taught least — a MACD line pinned to zero means the two averages are on top of each other, which means there is no trend at all.

The zero cross. The fast average moves above the slow one. The character of the chart has changed before any signal-line crossover has happened.

The signal cross. Now the classic entry fires, with the move already partly underway.

The trend chart with a price level marked and the MACD panel showing the line held above zero throughout.
Above zero the whole way. The level is what you would actually trade.

The panel told you the market was trending. The chart told you where to act. Those are two different jobs and the indicator only does the first.

The original data

Across our study of 24,971 trading videos, 698 cover MACD. The median one gets 2,130 views, 84% never pass 50,000, and the median length is 8.8 minutes.

That is among the lowest medians of any topic in this glossary — below moving averages at 4,868, RSI at 3,893 and support and resistance at 18,609, and beaten only by a handful of much smaller fields led by forex or stocks at 910.

The likeliest reading is saturation rather than disinterest: 698 videos on a forty-year-old indicator whose explanation does not change. There is no new thing to say about the calculation, so the videos are near-identical and the audience is split hundreds of ways.

The corpus carries description text for 110 of those 698, and across those 110, four mention invalidation, failure, or what a bad read looks like.

When it fails

A sideways range with the MACD line crossing its signal line repeatedly, each crossing marked.
Five crossovers over thirty-five bars, marked by the maths. None began a trend.

This is the failure. MACD is built from moving averages, and moving averages have nothing to say about a market that is not trending. In a range the line sits on zero and crosses its signal repeatedly — five times on the chart above.

Every one of those is a signal by the standard interpretation, and none of them led anywhere.

Divergence that does not resolve

Price making a higher high while the MACD line makes a distinctly lower high.
Price higher, MACD lower. A real divergence in the numbers.

The divergence above is genuine — price made a higher high and the MACD line did not. It is a true statement that the second push was weaker than the first.

It is still not a reason to be short. Weaker is not the same as finished, and the same picture appears on plenty of charts that carry on upward. See RSI for the same problem in more detail, with a chart of it failing.

You are reading it as its own thing

Every reading on the panel is a restatement of where two averages are. If the averages are not telling you anything, neither is the panel, no matter how elaborate it looks.

You found the settings afterwards

The chart cut off two bars after the crossover, with no outcome visible.
Two bars past the cross. Which of the two charts above this becomes is not visible.

Twelve, twenty-six and nine are conventions from before personal computers. They are not optimal and they are not magic — and any three numbers can be tuned to have caught the moves on a chart you have already seen.

Moving averages are what MACD is made of, and the page covers the lag that explains every one of its shortcomings.

RSI is the other oscillator worth knowing, and it fails in a different and instructive way.

And market structure supplies what no oscillator can: the specific price at which your read is finished.

What I actually do

This sits in the same bucket for me as every other indicator: context, not a trigger. It is two averages subtracted, so it can only tell me what the averages already told me, slightly later. Where I have found it genuinely useful is as a quick read on whether a market is trending at all - if the line is hugging zero and crossing back and forth, that is a market I do not want to be taking trend setups in, and that reading takes about a second.

— Michael Whitman, from this video

This page is educational, not financial advice. Test every idea on your own charts before risking money.