- What the MACD indicator is and how it's calculated
- The three components: MACD line, Signal line, and Histogram
- How to identify MACD crossovers (bullish and bearish signals)
- MACD divergences: powerful reversal signals
- Proven MACD trading strategies with entry/exit rules
- How to combine MACD with other indicators for high-probability setups
What is the MACD Indicator?
MACD (Moving Average Convergence Divergence) is a trend-following momentum indicator that shows the relationship between two moving averages of a stock's price.
Developed by: Gerald Appel in the late 1970s
Purpose: MACD helps traders:
- Identify trend direction: Is momentum bullish or bearish?
- Spot trend changes: When does momentum shift from positive to negative (or vice versa)?
- Measure trend strength: Is the trend accelerating or decelerating?
- Generate buy/sell signals: MACD crossovers signal entry and exit points
The Three Components of MACD
MACD consists of three parts:
1. MACD Line (The Fast Line)
MACD Line Formula:
MACD Line = 12-period EMA - 26-period EMA
This measures the difference between a short-term and long-term exponential moving average.
- 12-period EMA: Fast EMA (reacts quickly to price changes)
- 26-period EMA: Slow EMA (smooths out short-term fluctuations)
- Interpretation: When the MACD line is positive, the short-term EMA is above the long-term EMA → bullish momentum
2. Signal Line (The Slow Line)
Signal Line Formula:
Signal Line = 9-period EMA of the MACD Line
This is a smoothed version of the MACD line, used to generate crossover signals.
- Purpose: Acts as a trigger for buy/sell signals
- Crossovers: When MACD crosses above Signal Line → bullish, when MACD crosses below Signal Line → bearish
3. MACD Histogram
Histogram Formula:
Histogram = MACD Line - Signal Line
The histogram shows the distance between the MACD and Signal lines.
- Positive histogram: MACD is above Signal Line (bullish momentum)
- Negative histogram: MACD is below Signal Line (bearish momentum)
- Growing histogram: Momentum is accelerating
- Shrinking histogram: Momentum is decelerating (potential reversal)
Imagine looking at a stock chart with MACD below the price:
- MACD Line (blue line): Oscillates above and below the zero line
- Signal Line (red line): Follows the MACD line, crossing it periodically
- Histogram (vertical bars): Green bars when MACD > Signal, red bars when MACD < Signal
Key insight: The histogram is the first to signal momentum changes—when it starts shrinking, a crossover is imminent.
How to Read MACD Crossovers
Bullish Crossover (Buy Signal)
Bullish MACD Crossover:
- Signal: MACD Line crosses above the Signal Line
- Histogram: Turns from negative (red bars) to positive (green bars)
- Interpretation: Short-term momentum is accelerating above long-term momentum → trend may be turning bullish
Trading strategy: Enter long when MACD crosses above Signal Line, especially if confirmed by price breaking above resistance.
Apple formed a bullish MACD crossover after a pullback:
- Date: April 12, 2024
- Signal: MACD crossed above Signal Line at -2.5 (below zero but turning up)
- Price action: Apple was at $165, bouncing off $150 support
- Outcome: Apple rallied from $165 to $185 over the next 6 weeks (+12%)
Key lesson: Bullish crossovers near support levels (and when MACD is below zero) often produce strong rallies.
Bearish Crossover (Sell Signal)
Bearish MACD Crossover:
- Signal: MACD Line crosses below the Signal Line
- Histogram: Turns from positive (green bars) to negative (red bars)
- Interpretation: Short-term momentum is decelerating below long-term momentum → trend may be turning bearish
Trading strategy: Exit longs or enter short when MACD crosses below Signal Line, especially if price breaks below support.
Tesla formed a bearish MACD crossover after a failed rally:
- Date: July 8, 2024
- Signal: MACD crossed below Signal Line at +5.2 (above zero but rolling over)
- Price action: Tesla was at $260, failing at $280 resistance
- Outcome: Tesla fell from $260 to $220 over the next month (-15.4%)
Key lesson: Bearish crossovers near resistance levels (and when MACD is above zero) often precede selloffs.
MACD Divergences: Powerful Reversal Signals
Divergences occur when price and MACD move in opposite directions. These are high-probability reversal signals.
1. Bullish Divergence (Reversal Up)
Bullish MACD Divergence:
- Price: Makes a lower low
- MACD: Makes a higher low (or less negative low)
- Interpretation: Selling pressure is weakening even as price makes new lows → reversal likely
Trading strategy: Enter long when MACD crosses above Signal Line after bullish divergence + price breaks above resistance.
Microsoft showed bullish MACD divergence at a key support level:
- First low (Sept 2023): Price = $310, MACD = -8.5
- Second low (Oct 2023): Price = $305 (lower low), MACD = -6.2 (higher low)
- Signal: Bullish divergence confirmed when MACD crossed above Signal Line
- Outcome: Microsoft rallied from $305 to $380 over the next 3 months (+24.6%)
Key takeaway: MACD divergences at major support levels have exceptional win rates (70%+).
2. Bearish Divergence (Reversal Down)
Bearish MACD Divergence:
- Price: Makes a higher high
- MACD: Makes a lower high (or less positive high)
- Interpretation: Buying pressure is weakening even as price makes new highs → reversal likely
Trading strategy: Exit longs or enter short when MACD crosses below Signal Line after bearish divergence + price breaks below support.
Amazon showed bearish MACD divergence before a correction:
- First high (July 2024): Price = $195, MACD = +12.8
- Second high (Aug 2024): Price = $200 (higher high), MACD = +9.5 (lower high)
- Signal: Bearish divergence confirmed when MACD crossed below Signal Line
- Outcome: Amazon fell from $200 to $170 over the next 6 weeks (-15%)
Key takeaway: Bearish MACD divergences near resistance often precede sharp pullbacks.
Proven MACD Trading Strategies
Strategy 1: MACD Zero Line Crossover
Setup:
- MACD crosses above zero line (12-EMA crosses above 26-EMA)
- This is a stronger signal than a simple MACD/Signal crossover
Entry Rules (Bullish Zero Line Cross):
- Buy signal: MACD crosses above zero + price is above 50-MA
- Confirmation: Volume spike + RSI > 50
Exit Rules:
- Stop loss: Below recent swing low or 50-MA
- Profit target: When MACD crosses back below zero or 15-20% gain
Strategy 2: MACD Histogram Reversal
Setup:
- Histogram has been growing (bars getting taller)
- Suddenly, histogram starts shrinking (bars getting shorter)
- This signals momentum is decelerating—crossover is imminent
Entry Rules (Early Reversal Signal):
- Buy signal: Histogram stops shrinking and starts growing again (momentum accelerating)
- Confirmation: Price forms a bullish candlestick pattern (hammer, engulfing)
Exit Rules:
- Stop loss: Below the histogram low
- Profit target: When histogram starts shrinking again or 10-15% gain
Strategy 3: MACD + RSI Combo (High-Probability Setup)
Setup:
- MACD shows bullish crossover (MACD > Signal Line)
- RSI is oversold (<30) or just bouncing from oversold
- Price is above 50-MA (confirming uptrend)
Entry Rules:
- Buy signal: All three conditions met (MACD bullish + RSI oversold + price > 50-MA)
- Confirmation: Volume spike on the entry day
Exit Rules:
- Stop loss: Below 50-MA or recent swing low
- Profit target: When MACD crosses below Signal Line or RSI hits overbought (>70)
Common MACD Mistakes and How to Avoid Them
Top MACD Mistakes:
- ❌ Trading every crossover: MACD crossovers in sideways markets produce frequent false signals (whipsaw).
- Solution: Only trade MACD crossovers when price is in a clear trend (above/below 200-MA).
- ❌ Ignoring the zero line: Crossovers above zero are more reliable than crossovers below zero.
- Solution: Prioritize bullish crossovers when MACD is above zero, bearish crossovers when MACD is below zero.
- ❌ Using MACD alone: MACD is a lagging indicator—it confirms trends but doesn't predict them.
- Solution: Combine MACD with leading indicators (RSI, support/resistance, volume) for confirmation.
- ❌ Chasing late crossovers: Entering after a crossover when price has already moved 10%+ often results in buying near a top.
- Solution: Wait for a pullback after the crossover to enter at better prices.
Adjusting MACD Settings
The default MACD settings are 12, 26, 9 (12-EMA, 26-EMA, 9-EMA for Signal Line). Traders adjust based on their timeframe:
| Trading Style | MACD Settings | Best For |
|---|---|---|
| Day Trading | 5, 13, 5 (faster) | Quick scalps, intraday swings |
| Swing Trading | 12, 26, 9 (standard) | 2-4 week trades, trend following |
| Position Trading | 19, 39, 9 (slower) | Multi-month holds, fewer signals |
Recommendation: Start with the default 12, 26, 9 settings. Only adjust after you've mastered the basics.
Action Steps: How to Start Using MACD
- Open TradingView and add MACD to any stock chart (Indicators → "MACD")
- Identify the trend: Is the stock in an uptrend (price > 50-MA) or downtrend?
- Look for bullish crossovers (MACD crosses above Signal) in uptrends
- Look for bearish crossovers (MACD crosses below Signal) in downtrends
- Scan for divergences: zoom out to 6-12 months and find historical divergences that predicted reversals
- Combine MACD with RSI: only trade MACD signals when RSI confirms (oversold for buys, overbought for sells)
- Backtest: test the "MACD zero line crossover" strategy on 10 stocks over the past year
Final Thoughts
MACD is one of the most versatile and widely-used indicators in technical analysis. It combines trend-following (moving averages) with momentum (rate of change), giving you a complete picture of market dynamics.
The key to success with MACD is patience and confirmation. Don't trade every crossover—wait for signals in the direction of the trend, confirmed by volume and other indicators like RSI or support/resistance.
And remember: MACD divergences are gold. When price makes a new high/low but MACD doesn't confirm it, pay attention. These divergences have an exceptional track record of predicting major reversals.
Next Steps: Now that you've mastered MACD, combine it with other technical tools for a complete trading system. Read our guides on Moving Averages, RSI, and Support & Resistance to build a professional trading approach.
Related Articles
Moving Averages Explained
MACD is built from moving averages—understand the foundation of this powerful indicator.
RSI Indicator Guide
Combine MACD crossovers with RSI oversold/overbought levels for confirmation.
Support & Resistance Levels
Use MACD signals at key S/R levels for high-probability breakout trades.
Free Cash Flow Guide
Find fundamentally strong stocks, then use MACD to time your entries perfectly.