Simple Moving Average: SMA in Trading (2024)

  • Home
  • Learn
  • Trading guides
  • Simple moving average

The simple moving average (SMA) is a popular technical analysis tool. Used mainly to identify trends, it is one of the most commonly used indicators across all financial markets. The SMA works by smoothing out past price data and is generally seen as a lagging indicator​.

Trading with the SMA shows the average price of a security over a certain length of time and is plotted as a single line on a candlestick chart​. Because it is customisable over different time horizons, the SMA is used by both short-term traders and long-term investors.For example, a short-term trader may use the 20-day simple moving average to identify short-term price trends​. In contrast, a long-term investor may use the 200-day SMA to identify the long-term trend. It can be applied to all financial markets, such as shares, currencies, indices and exchange-traded funds (ETFs).

See inside our platform

Get tight spreads, no hidden fees and access to 10,000+ instruments.

Start trading

Includes free demo account

Trustpilot

Simple Moving Average: SMA in Trading (1)

Quick link to content:

What is the simple moving average?

The simple moving average is a lagging indicator because it is based on past price data. The longer the time period of the SMA, the greater the lag. While the SMA is a helpful technical analysis​ tool, it is best used along with other popular indicators such as trendlines and volume analysis.

In most trading scenarios, the SMA is plotted on a price chart along with the exponential moving average (EMA). They share similarities and differences but, like most technical indicators, they work best together to define price trends and momentum in trading.

How to calculate the SMA

The simple moving average is quite easy to calculate. Most trading platforms offer tools that can automatically calculate the SMA. This means that traders will almost never have to manually calculate the SMA for their trades as modern charting software will perform all the calculations instantly. However, the below formula is good for a trader's general knowledge.

SMA indicator formula

  • The SMA formula is calculated by averaging a number of past data points. Past closing prices are most often used as data points.
  • For example, to calculate a security’s 20-day SMA, the closing prices of the past 20 days would be added up, and then divided by 20.
  • Similarly, to calculate a security’s 200-day SMA, the closing prices of the past 200 days would be totalled, and divided by 200.

How to use a simple moving average

There are two main ways to use the simple moving average. The first is trend analysis. At a very basic level, traders and investors use the SMA to assess market sentiment and get an idea of whether the price of a security is trending up or down.

The basic rule for trading with the SMA is that a security trading above its SMA is in an uptrend, while a security trading below its SMA is in a downtrend. For example, a security trading above its 20-day SMA is thought to be in a short-term uptrend. In contrast, a security trading below its 20-day SMA is thought to be in a long-term downtrend. By analysing the SMA, the investor or trader can quickly assess market trends and determine whether the security is trending upward or downward.

Simple moving averages can be useful in spotting trend changes. They can also be used to identify support and resistance​ levels. Often, during a trend, the SMA will provide a dynamic level of support or resistance. For example, a security in a long-term uptrend may continually pull back a little, but find support at the 200-day SMA. This can also be helpful in identifying trend changes. This method can be used across many markets, including foreign exchange, indices and stock markets.

Browse our range of technical indicators

Start with a live account

Start with a demo

Difference between simple and exponential moving average

The simple moving average is the simplest type of moving average. It is calculated by adding up past data points and then dividing by the total number of data points. While the SMA is a very popular technical indicator, it does have one main weakness. Some traders and investors believe that it is flawed because every data point has the same weight. They argue that current data is more important than previous data and should therefore have a higher weight. As a result, some traders and investors prefer to use another form of moving average, known as the exponential moving average (EMA).

In comparison to the SMA, the exponential moving average gives more weight to the most recent prices. This is the key difference between the SMA and EMA. The EMA is more responsive to the latest data than the SMA, because the latest data has a larger impact on the calculation. Calculating the EMA is more complicated than the SMA. However, like the SMA, most charting software available will draw an EMA line at the click of a button, including our online trading platform, Next Generation.

Simple moving average and technical analysis

Technical analysis is mainly used by short-term traders in strategies such as day trading​. This form of analysis uses past security price patterns to predict future price movements. In contrast, fundamental analysis is favoured by long-term investors. This style of analysis focuses on economic indicators such as company revenue, profit and growth in order to identify potential investments.

One advantage of the simple moving average is that the tool can be used for both technical and fundamental analysis​. While the two styles are very different, the simple moving average can be used to complement both. For example, a short-term trader that trades using technical analysis may be interested in finding out whether a security is trending up or down over a 10-day period. This trader could analyse the 10-day SMA to determine the trend.

In contrast, a long-term investor that generally uses fundamental analysis might be more interested in buying an upward-trending security after a pullback to the 200-day SMA. This investor could use the SMA to find out how to calculate an attractive entry point.

Simple moving average strategy

There are many different trend-based strategies involving the simple moving average. Two of the most popular signals that traders look for are bullish crossovers and bearish crossovers.

A bullish crossover occurs when a security’s price moves back above the SMA after being below it. This action signals that the downtrend or correction is over and a possible uptrend is starting. A bullish crossover can be used as a signal to enter a long trade. During trending markets, this signal can be quite reliable. However, during choppy or sideways markets, the indicator can be less reliable in measuring market fluctuations. Bullish crossovers are less important when the long-term trend is down.

A bearish crossover occurs when a security’s price falls below the SMA after trading above it. This action signals that the uptrend is over and the trend may now be downward. A bearish crossover can be used as a signal to exit a long position or, alternatively, enter a short position. During choppy or sideways markets, a bearish crossover is less meaningful.

SMA crossover

Another popular strategy with the SMA is the moving-average crossover. This occurs when a short-term SMA crosses over a long-term SMA. A moving average crossover is often referred to as a golden cross or death cross.

A golden cross occurs when a security’s short-term SMA crosses above its long-term SMA. For example, the classic setup here is when the 50-day SMA crosses above the 200-day SMA. This is a bullish signal and indicates that the price of the security may continue rising. A golden cross can be used as a trading signal to enter a long trade.

The reverse of the golden cross is a bearish indicator known as the death cross. A death cross is identified when a security’s short-term SMA crosses below its long-term SMA. For example, the 50-day SMA might cross over and fall under the 200-day SMA. This is a bearish signal and indicates that the price of the security may continue falling. A death cross may be used as an exit strategy.

Read more about golden/death crosses​.

Simple Moving Average: SMA in Trading (4)

Explore our leading and lagging indicators

Seamlessly open and close trades, track your progress and set up alerts

Open a demo account

Learn more

Set up the simple moving average algorithm

Our online trading platform, Next Generation, has a wide range of technical indicators that can be applied any financial market, using either short-term or long-term trading strategies. Our simple moving average indicator is automatically calculated for your ease of trading, along with the exponential moving average. These work best when combined with other popular trend indicators, such as Bollinger Bands, relative strength index (RSI), stochastic oscillator and the ADX indicator.

Read more about our charting features here to take advantage of our drawing tools, technical indicators and price projection tools. We offer a variety of chart displays to show your data clearly.

SMA for MT4

Our international hosted platform, MetaTrader 4​, also comes with the built-in simpe moving average indicator, for users who are already familiar with the trading platform.

Summary: SMA trading

The simple moving average is a popular tool that can benefit both short-term traders and long-term investors. The SMA smooths out price data by averaging a security’s price over a certain length of time. It is drawn as a single line on a chart and is helpful in identifying trends. The benefit of the SMA is that it quickly enables a trader or investor to determine whether a security is trending up or down.

See why serious traders choose CMC

Get tight spreads, no hidden fees, access to 10,000+ instruments and more.

Simple Moving Average: SMA in Trading (5)

FCA regulated

Simple Moving Average: SMA in Trading (6)

Segregated funds

Learn more

Includes free demo account

Simple Moving Average: SMA in Trading (7)

Simple Moving Average: SMA in Trading (2024)

FAQs

Simple Moving Average: SMA in Trading? ›

A simple moving average (SMA) is a technical indicator that's calculated by adding the closing price of a stock or other security over a specific period of time and dividing the total by the appropriate number of trading days. For example, a 20-day SMA is the average closing price over the previous 20 days.

What is an example of a simple moving average SMA? ›

The equation for SMA is quite simple. It is just the average closing price of a security over the last “n” periods. Using a 5-day SMA, we can calculate that at Day 10 (n=10), the 5-day SMA is $18.60. Using a 10-day SMA, we can calculate that at Day 10 (n=10), the 10-day SMA is $14.90.

What does SMA mean in trading? ›

The most commonly used moving average is a so-called simple moving average (SMA), which is the average closing price of a given security over a specific number of days. For example, you can find a stock's 20-day SMA by adding its prices over 20 days, then dividing that number by 20.

What is simple moving averages simpler trading? ›

The Simple Moving Average is a fundamental tool used in technical analysis to identify price trends and reversals. The SMA provides a smoothed line that helps reduce market noise and highlight the underlying trend.

What is the most common SMA in trading? ›

Usually, the 20, 50, 100 and 200 period SMA's are most perceived to act as support or resistance levels, and hence these are the most popular ones.

How to use SMA in trading? ›

At a very basic level, traders and investors use the SMA to assess market sentiment and get an idea of whether the price of a security is trending up or down. The basic rule for trading with the SMA is that a security trading above its SMA is in an uptrend, while a security trading below its SMA is in a downtrend.

What happens when 20 SMA crosses 50 SMA? ›

Scan Description: If 20 SMA line cuts 50 SMA line from below, it is bulish pattern and price is likely move up.

Do traders use SMA or EMA? ›

Many shorter-term traders use EMAs because they want to be alerted as soon as the price is moving the other way. Longer-term traders tend to rely on SMAs since these investors aren't rushing to act and prefer to be less actively engaged in their trades. Ultimately, it comes down to personal preference.

Do most traders use EMA or SMA? ›

With moving averages in general, the longer the time period, the slower it is to react to price movement. But everything else being equal, an EMA will track price more closely than an SMA. Because of this, the EMA is typically considered more appropriate in short-term trading.

What is the most popular simple moving average? ›

For identifying significant, long-term support and resistance levels and overall trends, the 50-day, 100-day, and 200-day moving averages are the most common.

Which simple moving average is best? ›

20 / 21 period: The 21 moving average is my preferred choice when it comes to short-term swing trading. During trends, price respects it so well and it also signals trend shifts. 50 period: The 50 moving average is the standard swing-trading moving average and very popular.

What is a good simple moving average? ›

A 200-bar simple moving average is usually used as a substitute for the long-term trend. Likewise, a 50-bar simple moving average is used to evaluate the intermediate trend. Short period simple moving averages are used to determine short-term trends.

What is the best SMA to use? ›

That depends on whether you have a short-term horizon or a long-term horizon. For short-term trades the 5, 10, and 20 period moving averages are best, while longer-term trading makes best use of the 50, 100, and 200 period moving averages.

What is the gold standard for SMA? ›

In the modern era, genetic testing is considered the gold standard to test for SMA, though these other assessments also may be included in the diagnostic workup when genetic tests are inconclusive, or when used to evaluate disease severity.

Is SMA a good indicator? ›

The 50-day simple moving average (SMA) is popular with traders and market analysts because historical analysis of price movements shows it to be an effective trend indicator. The 50-, 100-, and 200-day moving averages are probably among the most commonly found lines drawn on any trader's or analyst's charts.

What is an example of a SMA? ›

For example, to calculate a security's 20-day SMA, the closing prices of the past 20 days would be added up, and then divided by 20. Similarly, to calculate a security's 200-day SMA, the closing prices of the past 200 days would be totalled, and divided by 200.

What is an example of a simple moving average? ›

A simple moving average is formed by computing the average price of a security over a specific number of periods. Most moving averages are based on closing prices; for example, a 5-day simple moving average is the five-day sum of closing prices divided by five.

What is SMA in moving average? ›

A simple moving average (SMA) calculates the average of a selected range of prices, usually closing prices, by the number of periods in that range.

What is an example of a simple moving average forecasting? ›

For example, let's say it's the end of March, so your first sales quarter is almost over. To get the simple moving average (SMA) you would divide the total sales from January – March by the number of periods, which in this case would be 3 (3 months), giving you a simple average number of sales per month.

Top Articles
Latest Posts
Article information

Author: Foster Heidenreich CPA

Last Updated:

Views: 5509

Rating: 4.6 / 5 (76 voted)

Reviews: 83% of readers found this page helpful

Author information

Name: Foster Heidenreich CPA

Birthday: 1995-01-14

Address: 55021 Usha Garden, North Larisa, DE 19209

Phone: +6812240846623

Job: Corporate Healthcare Strategist

Hobby: Singing, Listening to music, Rafting, LARPing, Gardening, Quilting, Rappelling

Introduction: My name is Foster Heidenreich CPA, I am a delightful, quaint, glorious, quaint, faithful, enchanting, fine person who loves writing and wants to share my knowledge and understanding with you.