Indicators
MACD Crossover / Divergence
A fast 12-period EMA minus a slow 26-period EMA, plotted against its own 9-period EMA signal line. Crossovers are the basic read, divergence against price is the sharper one.
A real MACD, computed live under the candles
Everything in the panel below is calculated from the actual closing prices as the tape plays, the same 12/26/9 EMA math a real charting platform uses. Step through crossovers as they happen, or switch to the divergence challenge and click two swing points on the price chart plus their matching points on the MACD panel, the tool checks your pick against the real numbers, not against how it looks.
Press play or step to build the MACD live.
- Crossovers will appear here as they happen.
How it works
- Two EMAs, one difference. MACD is just the 12-period EMA minus the 26-period EMA. When the fast average is above the slow one, MACD is positive, momentum leans up. Below zero, momentum leans down.
- The signal line smooths the MACD itself. A 9-period EMA of the MACD line, not of price. When MACD crosses above its own signal line, that is a bullish crossover, below it, bearish.
- The histogram is the gap between the two. MACD minus signal, plotted as bars. It flips sign at every crossover, and its shrinking or growing size shows momentum building or fading before the actual crossover happens.
- Divergence compares two different charts, not two points on one. Bearish divergence: price makes a higher high, but MACD makes a lower high at that second peak, momentum did not confirm the new price extreme. Bullish divergence is the mirror image on lows. The tool checks the exact bar values on both panels, not whether it looks like a divergence.
Where this breaks
Divergence can persist through several more new highs before price ever turns
MACD is built from moving averages, which means it lags price by construction. A crossover confirms a move that has usually already been underway for a few bars, not a move about to start. Divergence is worse in this respect, not better: a market can print a genuine bearish divergence and then go on to make two or three more higher highs, each one deepening the same divergence, before the reversal it was supposedly warning about ever shows up. Waiting for the actual crossover to confirm a divergence signal costs still more of the move. There is no fixed rule for how long a real divergence can persist before it resolves, which is exactly why this tool scores whether your two points are mechanically a genuine divergence, not whether trading it would have worked.