The Trading PathStart free
Trading glossary

What is a moving average?

In short

A moving average is the average closing price over the last few periods, recalculated with every new candle. Strung together, those averages form a smooth line that filters out noise and shows the underlying direction. The two most common are the simple moving average (SMA), which weights every data point equally, and the exponential moving average (EMA), which gives more weight to recent prices.

How it’s calculated

Simple moving average (SMA): add up the last n closes and divide by n. With sample closes of $50, 52, 51, 53 and 54, the 5-period SMA is (50 + 52 + 51 + 53 + 54) ÷ 5 = $52.00. If the next day closes at $57, the 50 drops out and the 57 comes in: (52 + 51 + 53 + 54 + 57) ÷ 5 = $53.40.

Exponential moving average (EMA): uses a multiplier k = 2 ÷ (n + 1). For 5 periods, k = 0.3333. Starting from 52.00, the next day’s EMA is 57 × 0.3333 + 52.00 × 0.6667 = $53.67. It reacts more to the latest price than the SMA, which landed at 53.40.

Your platform does these calculations for you; understanding them helps you see why each average behaves the way it does.

28.1534.1240.1046.0852.06EMA 20SMA 50
A 20 EMA and a 50 SMA in an uptrend: the exponential average hugs the price, while the slower simple average shows the underlying direction.

The most common periods

  • 9 to 21 EMA: short averages for tracking the immediate pace, used mostly by short-term traders.
  • 50 SMA or EMA: the reference for the intermediate trend.
  • 200 SMA: the most closely watched gauge of the long-term trend on daily charts. Many market participants consider a price above it to be in a bullish long-term backdrop.

There’s no universally correct period: what matters is choosing one that fits your time horizon and using it consistently.

How traders use them

  • Direction: a rising average with price above it describes an uptrend.
  • Dynamic support: in healthy trends, pullbacks often stall near an average, which acts as a moving support level.
  • Crossovers: a golden cross happens when the 50 SMA crosses above the 200 SMA; a death cross, when it crosses below. They’re late confirmations of context, not early entry signals.

A practical example

A sample stock trades at $120 on the daily chart. Its 200 SMA is at $104 and rising, and its 50 SMA is at $115, also rising. The read on context is bullish: price is above both, and the short average is above the long one.

If price pulls back to the 50 SMA and stalls there, many traders read it as a pullback within the trend. If instead it closes below the 50 SMA for several days and the average starts to flatten, the backdrop is losing strength. Neither scenario is an automatic order: the average is a reference you combine with price levels, candles and a trading plan.

The main limitation

Every moving average lags price, because it’s calculated from past data. It works well in trends and poorly in ranges: when price moves sideways, it crosses the average again and again, and each crossover is a false signal (known as a whipsaw). That’s why it pays to combine it with a read of the structure of highs and lows and with other types of indicators, such as the MACD, which is in fact built from exponential moving averages.

Jesse · the MasterA moving average doesn’t predict anything: it tells you where price has been going. Use it to swim with the current, not to guess the turn.

Phase 2 · Lesson 2.4

Learn it in depth in lesson 2.4: Moving averages

In the course you practice it with real charts, pop quizzes and an exam that tells you whether you really got it. Start free with lesson 1.1; no card required.

Frequently asked questions

Which is better, the SMA or the EMA?

Neither is better across the board. The EMA reacts faster to changes, which helps you spot turns sooner but produces more false signals. The SMA is slower and steadier. Many traders use EMAs for short periods and SMAs for long ones.

What does a golden cross mean?

It’s when the 50-period simple moving average crosses above the 200-period one. It shows that the medium-term average has moved above the long-term average. It arrives with a long delay, so it’s used as confirmation of context.

Why do moving averages fail in sideways markets?

Because in a range, price oscillates around the average and crosses it constantly. Each crossover looks like a trend-change signal, but it isn’t. A flat average is the warning that the market has no direction.

Related terms

Educational content from The Trading Path. Not a recommendation to buy or sell any asset.