TraderAI
FeaturesPricingBlog
Sign InGet Started
  1. Home
  2. Indicator library
  3. Simple Moving Average
Moving averages

Simple Moving Average

The Simple Moving Average (SMA) is the plain average of the last N prices. Every price in the window has the same weight, so the line smooths out short-term noise and shows the underlying direction.

Open on live chart All indicators

Adds Simple Moving Average to a free BTC/USDT chart.

Formula

SMA = (x[t] + x[t-1] + ... + x[t-N+1]) / N

How TraderAI calculates it

TraderAI averages the last 20 closes by default; you can change the length and use another price source such as the high, the low or the typical price. The first value appears once 20 candles exist, and each new candle replaces the oldest one in the window.

Live example

How traders read it

  1. 1

    Price above a rising SMA is commonly read as an uptrend, and price below a falling SMA as a downtrend.

  2. 2

    Two SMAs of different lengths crossing each other, for example the 50 and the 200, are widely watched as a change in trend.

  3. 3

    Longer SMAs react slowly but filter more noise; shorter SMAs react quickly but produce more false turns.

Limitations

  • An SMA lags price because old and new prices carry the same weight, and it can move when the oldest price drops out of the window.
  • In sideways markets price crosses moving averages often without a lasting trend.

Settings and defaults

SettingDefaultAllowed range
Price sourceCloseOpen, High, Low, Close, High-low average, Typical price, OHLC average
Period201 to 500

What it plots

Drawn on the price chart, on the same scale as the candles.

LineUnitDrawn asFirst value
ValuePriceLineafter 20 candles

Calculation notes

  • Average of the selected price over the period. Starts once a full window exists.

Questions

What is Simple Moving Average?

The Simple Moving Average (SMA) is the plain average of the last N prices. Every price in the window has the same weight, so the line smooths out short-term noise and shows the underlying direction.

How does TraderAI calculate Simple Moving Average?

TraderAI averages the last 20 closes by default; you can change the length and use another price source such as the high, the low or the typical price. The first value appears once 20 candles exist, and each new candle replaces the oldest one in the window.

What are the default settings of Simple Moving Average?

The defaults are Price source: Close, Period: 20. You can change every setting on the live chart.

Can I use Simple Moving Average for free on TraderAI?

Yes. Every indicator in the library can be added to the free live chart. The free plan keeps up to 2 indicators active at the same time; Pro lets you combine more on one chart.

Educational content. Indicators describe past prices; they do not predict future prices and are not investment advice.

Category
Moving averages
Drawn as
Drawn on the price chart, on the same scale as the candles.
First value
after 20 candles
Formula version
traderai-classic-v1
Open on live chart

Free plan: up to 2 indicators active at the same time. Pro lets you combine more indicators on one chart.

See plans

Related indicators

  • Exponential Moving Average
  • Weighted Moving Average
  • Guppy Multiple Moving Average
  • Tillson T3
  • Triangular Moving Average
  • Zero-Lag EMA
How TraderAI's AI reads a chart