Indicators

Moving Average

A moving average is the average closing price over a set number of recent periods, recalculated each period to smooth out noise and show the direction of the trend.

Also called: SMA · Simple moving average · MA

A moving average is the simplest trend tool on any chart. By averaging recent closes, it filters out the bar-to-bar noise and shows whether price is generally rising, falling or flat. Unless stated otherwise, “moving average” usually means the simple moving average (SMA); the faster-reacting variant is the EMA.

How it’s calculated

SMA = (sum of the last N closes) ÷ N

Each new period, the oldest close drops out and the newest is added, so the line “moves”.

Widely used settings:

  • 20-period: short-term trend; also the middle line of Bollinger Bands.
  • 50-period: medium-term trend.
  • 200-period: long-term trend, closely watched on daily charts.

Typical uses: the slope shows the trend direction, price above or below the average shows bias, and rising averages often act as dynamic support (falling ones as resistance). Crossovers of a fast and a slow average are a basic trend-following signal.

Example

A 5-period SMA on closes of 10, 11, 12, 13 and 14:

  • SMA = (10 + 11 + 12 + 13 + 14) ÷ 5 = 12

The next close is 15. The 10 drops out:

  • SMA = (11 + 12 + 13 + 14 + 15) ÷ 5 = 13

Notice that price is at 15 while the average is at 13: the SMA trails price by design. On a longer setting such as 200 periods, that lag is much larger.

Common mistakes

  • Expecting averages to predict. They describe what has already happened. Crossovers usually arrive after a good part of the move.
  • Using them in ranges. In sideways markets, price crosses a flat average constantly, producing false signals.
  • Treating the line as an exact level. Price often overshoots a moving average before reacting; think of it as a zone.
  • Optimising the period endlessly. Fitting the “perfect” length to past data rarely holds up; standard settings are easier to compare.

The MACD is built from two EMAs and turns their gap into a momentum reading. For how averages combine with other indicators, see RSI, MACD, ATR and EMA explained.

Educational content — not financial advice.

Updated

Frequently asked questions

What is the difference between SMA and EMA?

A simple moving average weights every period equally; an exponential moving average gives more weight to recent prices, so it reacts faster but is also more sensitive to noise.

What is a golden cross?

A golden cross is when a shorter moving average, commonly the 50-period, crosses above a longer one, commonly the 200-period. The opposite is called a death cross. Both lag price.

Which moving average is best?

None is best in general. The 20, 50 and 200 periods are widely watched, which is part of why price often reacts near them.