TradeLabs AILearn

Simple Moving Average (SMA)

The simple moving average is the plain average of recent closes. Learn the SMA formula, how lag works, popular SMA settings and practical trading uses.

Beginner3 min readUpdated 3 Oct 2026
Markdown
Lesson 2 of 22

The simple moving average (SMA) is the most basic moving average: the arithmetic mean of a set number of recent prices, usually closing prices. Every price in the window counts equally. Its simplicity makes it easy to understand and calculate, and the long period SMAs, like the 50 and 200 day, are among the most watched lines in all of finance.

The formula#

SMA = (P₁ + P₂ + ... + Pₙ) ÷ n

Here P₁ to Pₙ are the last n closing prices. Each new period, the oldest price drops out and the newest enters.

Lag: the SMA's main trait#

Because every price in the window has equal weight, an SMA reacts slowly to new information. A useful rule of thumb is that an SMA lags price by about half its length: a 20 day SMA reflects roughly where price was 10 days ago in a steady trend.

Another quirk is the drop off effect: when a large price move leaves the window, the SMA can shift noticeably even if today's price barely moves. The EMA avoids this by fading old prices gradually. See Exponential Moving Average (EMA).

SMATypical use
10 to 20Short term trend, swing pullbacks
50Intermediate trend, institutional reference
100Longer trend
200Long term trend; bull or bear market filter

The 200 day SMA is particularly famous. Many investors consider a market above its 200 day SMA to be in a long term uptrend and below it to be in a downtrend.

Trading with the SMA#

Trend filter#

Only take long trades when price is above a rising 200 day SMA, and short trades when below a falling one. This simple rule keeps many traders out of the worst downtrends.

Pullback entries#

In an uptrend, wait for price to pull back to the 20 or 50 day SMA and show a reaction, then enter with a stop below the recent swing low.

Crossovers#

A shorter SMA crossing a longer one signals a change in momentum. The 50 and 200 day crossover (golden cross and death cross) is the best known. See Moving Averages Explained.

Building block for other indicators#

Bollinger Bands use a 20 period SMA as their middle line, and many oscillators use SMAs for smoothing. See Bollinger Bands.

SMA vs EMA at a glance#

SMAEMA
WeightingEqualRecent prices more
Reaction speedSlowerFaster
NoiseSmootherMore reactive to noise
Drop off effectYesNo
Best forLong term trend, widely watched levelsShort term timing

Choosing a length#

Match the SMA length to how long you hold trades. A swing trader holding for one to three weeks might use the 20 and 50 day SMAs; a position trader holding for months might focus on the 50 and 200 day. Pick a small set, use them consistently and judge them over many trades rather than switching after each loss. Looking back at how a market behaved around your chosen SMAs over the last year is a quick way to see whether they are worth watching.

Common mistakes#

  • Expecting precise support at the SMA; reactions happen near it, not at it to the cent.
  • Using long SMAs for short term timing, where their lag is too large.
  • Trading every crossover in a sideways market.

Frequently asked questions#

How is the simple moving average calculated?#

By adding the last n closing prices and dividing by n, then repeating as each new period closes.

Why is the 200 day SMA important?#

Because so many traders and investors use it as a long term trend filter, making it a widely watched level where price often reacts.

Is the SMA better than the EMA?#

Neither is better overall. The SMA is smoother and better for long term trend; the EMA reacts faster and suits short term timing.

Next, learn the faster version: the Exponential Moving Average (EMA).

Check your understanding

3 quick questions on this lesson. Get them all right to finish it.

Turn on JavaScript to take the quiz.

Finished this lesson?Sign in to save your progress across devices.
Next lessonExponential Moving Average (EMA)The EMA weights recent prices more heavily, so it reacts faster than an SMA. Learn the EMA formula, the smoothing factor, popular settings and how traders use it.

Mentioned in