Last Updated on June 11, 2021 by Oddmund Groette
The Relative Strength Index (RSI) was developed by Welles Wilder and first introduced in a magazine called Commodities (now Futures) in June 1978. Wilder published a book in the same year called New Concepts In Technical Trading Systems (he also published the ADX indicator in the same book, an indicator we will cover later). The RSI has become one of the most widely used indicators for traders.
But does the RSI really work? And how does it work? In which markets is it likely to work? Do RSI strategies work?
Our research indicates the RSI is one of the most useful indicators for trading stocks and is very useful to develop strategies. However, it does not work on its own. Filters or additional criteria are needed in order for the RSI to be used in a trading strategy. The indicator works best on securities that are mean-reverting.
Most websites present the Relative Strength Index by using anecdotal evidence. But in order to find out if something really has any predictive value you need to backtest. We have backtested trading systems for over 20 years and we can confirm that the RSI works reasonably well on stocks and stock indices. As such, the RSI can be used in trading strategies that are mean-reverting, but only when you add some more criteria, variables, or filters.
If you find this article useful, you might want to have a look at our landing pages for a lot of other trading strategies and edges:
The Relative Strength Index formula
The RSI is an oscillator that measures the magnitude of both gains and losses over a period of n days. You decide the number of days, normally adjusted to the time frame of your analysis. The value of RSI can be a maximum of 100, and the minimum can be zero.
The values oscillate and a low value is regarded as more bullish than high readings. The main idea is to use it as an overbought or oversold indicator. Thus, RSI works only on assets that are mean-reverting.
The formula reads like this:
RSI = 100 – (100 / (1+RS))
RS = average of up closes of the last n days/average of down closes of the last n days
In practice it works like this for a fourteen-day period:
- Add the percentage gains on up days (from close to close). Divide the sum by 14.
- Add the percentage of down days (from close to close). Divide the sum by 14.
- Divide number one (the average up days) by number two (the average down days). This is the RS in the formula.
- Put RS (number three) into the formula above.
This is it. It’s of course cumbersome to do the calculations, but that’s why we have spreadsheets and trading platforms. All software packages have the RSI built into their charting, so there is no need to use this formula, except for understanding how it works.
How to interpret the RSI-formula
The RSI can be used in many ways, but this article briefly looks at the two most popular ways to use the indicator:
Overbought and/or oversold – mean-reverting strategies:
Because the RSI oscillates between 0 and 100, it is mostly used to pinpoint when the security is oversold or overbought. A low reading indicates it has fallen in price, and a high reading indicates it has risen and thus might signal it is overbought.
Here is an example of how a seven-day RSI oscillates:
The indicator is in the lower pane and clearly shifts from oversold to overbought quite frequently. Also, notice how the RSI gets oversold in a rising and trending market. This is because it’s a relative index – as the name of the indicator implies. It only measures the relative performance over the last n number of days. If those days have shown little volatility, then even small changes in the price make the RSI leap up or down.
What happens if a stock is oversold or overbought? Trading is about odds and probabilities. It’s impossible to know if a trade will turn out good or bad if a stock is for example oversold. That’s why you need to backtest an indicator. Furthermore, it depends on the asset class you are testing. The Relative Strength Index works best on stocks and performs worse on other assets.
RSI divergence strategies:
Chart readers and technical analysts (we are not among them) believe a divergence between the price and the indicator is a strong signal. A divergence occurs like this:
- Bullish divergence: when the price sets a new low, while the RSI doesn’t. This is a buy signal.
- Bearish divergences: when the price sets a new high, while the RSI doesn’t. This is a sell signal.
Here are examples:
The problem with divergencies is that they are established after the fact. We can only spot divergencies in hindsight, which of course is not very useful. Additionally, they are harder to quantify and program into a useful code. Our experience is that this is a signal that serves little practical use for traders.
Which threshold settings should you use on the RSI strategies?
There are of course no common settings for which values offer the best thresholds. You need to tweak and test to see what has worked in the past and what hasn’t. Just as the time frame can vary from asset class to asset class, the threshold numbers are dependent on the time frame, the trend of the instrument, and the responsiveness you want.
We have found out that short time frames work best for the RSI. This means we need to use more extreme values like for example 15 for oversold and 85 for overbought. If you use a time frame of ten days, you are less likely to see readings of 15 or less.
Thus, a typical buy signal occurs when the reading shows values of 15 or less. If the reading is above 85, it’s considered a bearish signal as the asset is overbought. Perhaps needless to say, but the shorter the time frame, the more erratic the RSI. A longer time frame usually leads to smoother readings with less volatility of the RSI.
What is the best time frame for RSI strategies?
There is of course no absolute answer to this. It all depends on the properties of the markets you are trading. For example, let’s test a short-term RSI and a long-term RSI on the S&P 500.
The first example is a two day RSI where we buy when it crosses below 15 and sells when it crosses above 85. We get this equity curve:
This simple strategy performs just a tad worse than “buy and hold” from 1993 until November 2020. A 100 000 investment compounded to 861 000. Considering the strategy spends only 42% of the time invested, and additionally has less drawdown than “buy and hold” (33% vs. 55%), it shows how even simple strategies can perform well, even though we would modify and add variables. You must also factor in that the test ignored commissions, slippage, and taxes.
Let’s switch to a long-term RSI of 10 days. A longer-term RSI means there are fewer extreme variations in RSI, and thus we lower our threshold limits: we buy below 30 and sell above 70. The equity curve reads like this:
A ten-day RSI produces half the result compared to a two-day RSI, albeit spending about the same amount of time in the market. The drawdowns are bigger as well.
Where is the sweet spot? Our research indicates shorter time frames work best for the RSI (on stocks). We like to use a time frame lower than ten days, and the best result has come with two and three days. However, you need to work with backtesting yourself to find out what works and what doesn’t.
Combining different time frames of the RSI
What happens if we use two RSIs?
Let’s assume you want to only enter positions in the underlying trend of the instrument. How do you define a trend? You can for example use a longer RSI to determine the longer trend, while you enter on short-term pullbacks. Combining long-term and short-term RSI can take this form:
The long-term 30-day RSI must be above 50, and the two-day RSI must be below 15. If both conditions are met, then enter at the close. The exit is when the short-term RSI crosses above 85 (then exit at the close). On the S&P 500 we get this result:
The result is worse than the original single-RSI formula. Part of this is explained by less exposure in the market: it’s reduced from 42 to 27%. However, the max drawdown is the same at 33%.
The above strategy performed pretty well for almost 25 years until it started to crack in the second half of 2017. The biggest loss is a trade that enters on the 21st of February 2020 and exits on the 26th of March 2020 for a loss of 21.5%.
The code in Amibroker is like this:
Buy= RSI(30)>50 AND RSI(2)<15 ;
There are other twists you can make by combining a long and short RSI that improves the strategy, something we will get back to in a later article.
How do you trade stocks with RSI?
The RSI is a mean-reverting indicator and works best on stocks. As explained above, you need to test both the time frame and threshold settings yourself. And it doesn’t work on all stocks. Commodity related stocks like miners, oil, and coal have historically not worked for mean-reverting strategies. Opposite, the more boring and less volatile the stock, the better RSI performs.
The best way to use RSI strategies
The best way to use RSI is in combination with other tools. These tools can be volume, indicators, relative performance to other stocks or assets, or whatever ace you have up your sleeve.
What is the best indicator to use with RSI?
In stocks, RSI works really well with the Internal Bar Strength Indicator (IBS). As an example you can have a look at a strategy we published in 2016:
What is Connors RSI?
There exist many versions of the original RSI made by Welles Wilder. The most famous is probably Connors RSI developed by Larry Connors and his team at Trading Markets. We believe the formula serves much better as a marketing gimmick for Connors and his team than anything else. Nevertheless, the formula is the average of three parts:
- Relative Strength Index (RSI)
- Up/Down Length (Market Streak Value)
- Rate of Change (ROC)
In addition to Connors RSI there are many others, like for example Cutler’s RSI.
Amibroker and backtesting
The above charts were done by using Amibroker. This is a good trading platform, and you can read our thoughts on this link:
Conclusion: Does RSI really work?
Yes, the RSI works on stocks and in many other asset classes. But you have to use it together with some other indicator(s). On its own, the RSI works, but by adding some kind of filter it can be improved a lot.
As always, make sure you backtest whatever you read on the internet. A software platform for backtesting is a cheap investment!
Disclosure: We are not financial advisors. Please do your own due diligence and investment research or consult a financial professional. All articles are our opinion – they are not suggestions to buy or sell any securities.