What it measures
RSI measures the balance between up-moves and down-moves over a chosen number of bars. It takes each bar’s change from the previous close, averages the rises, averages the falls, and expresses the rises as a share of the two together.
A reading of 50 means the average rise and the average fall are the same size. A reading of 70 means the average rise is a little over twice the average fall. A reading of 100 means there were no falls at all in the stretch it remembers.
The index was set out by J. Welles Wilder Jr. in his 1978 book New Concepts in Technical Trading Systems, with a length of 14 and with his own way of averaging, which this page follows.
How it is calculated, step by step
- 01
Take the change of each bar.
Change = close − previous close.
- 02
Split it into a gain and a loss.
If the change is positive, gain = change and loss = 0. If it is negative, loss = the size of the change (as a positive number) and gain = 0.
- 03
Start the two averages.
First average gain = the sum of the first N gains ÷ N. First average loss = the sum of the first N losses ÷ N. N is usually 14.
- 04
Smooth them from then on (Wilder’s smoothing).
Average gain = (previous average gain × (N − 1) + this bar’s gain) ÷ N, and the same for the loss. Each new bar counts for one part in N.
- 05
Divide one by the other.
RS = average gain ÷ average loss.
- 06
Put it on a scale of 0 to 100.
RSI = 100 − 100 ÷ (1 + RS). If the average loss is zero, RSI is 100.
Because of the smoothing, an RSI value depends a little on every bar since the calculation began. Two programs with different amounts of history loaded can show slightly different readings for the same bar. A few programs use a plain average instead of Wilder’s smoothing, which gives a jumpier line.
A worked example, by hand
Six closes: 10, 11, 10, 12, 13, 12. Length 3. The changes are +1, −1, +2, +1, −1.
- First averages, from the first three changes: gain = (1 + 0 + 2) ÷ 3 = 1; loss = (0 + 1 + 0) ÷ 3 = 0.333
- RS = 1 ÷ 0.333 = 3, so RSI = 100 − 100 ÷ (1 + 3) = 75
- Next change +1: gain = (1 × 2 + 1) ÷ 3 = 1; loss = (0.333 × 2 + 0) ÷ 3 = 0.222
- RS = 1 ÷ 0.222 = 4.5, so RSI = 100 − 100 ÷ 5.5 = 81.8
- Next change −1: gain = (1 × 2 + 0) ÷ 3 = 0.667; loss = (0.222 × 2 + 1) ÷ 3 = 0.481
- RS = 0.667 ÷ 0.481 = 1.385, so RSI = 100 − 100 ÷ 2.385 = 58.1
One falling bar took the reading from 81.8 to 58.1. With a length of 3 each bar counts for a third; with 14 it counts for a fourteenth, and the line is calmer.
The numbers in this example were chosen to be easy to add up. They are not prices of anything.
How people read it
- The 70 and 30 lines. By convention a reading above 70 is called overbought and one below 30 oversold. The words mean only that recent closes have been mostly rises, or mostly falls.
- The 50 line. Above it, average gains have been larger than average losses; below it, the reverse.
- Divergence. The price makes a higher high while RSI makes a lower one, or the mirror image. It is read as a move losing pace, and it is far easier to see afterwards than at the time.
- The range it lives in. In a long rise RSI tends to spend its time in the upper part of the scale and seldom reaches 30; in a long fall it stays in the lower part and seldom reaches 70. The same number means different things in each.
What it cannot tell you
- It cannot say that a turn is due. A market that keeps rising keeps RSI above 70, sometimes for a very long time.
- It cannot tell you how far a price moved. It is a ratio: a quiet rise and a violent one can give the same reading.
- It cannot see anything but closes. Highs, lows, gaps inside a bar, volume and news are all outside it.
- It cannot be compared across lengths. A 5-bar RSI reaches 70 and 30 far more often than a 14-bar one on the same prices.
Common mistakes
- Reading ‘overbought’ as ‘about to fall’. It is a label for what has happened, not a forecast.
- Shortening the length until the line touches 70 and 30 at every turn in the past. That is fitting, and it will not hold on prices not yet seen.
- Finding divergence in hindsight. On any long chart there are many divergences that were followed by nothing.
- Using it alone. One line made from closes is one observation about closes.
Questions people ask
- What does an RSI above 70 mean?
- It means that over the bars RSI remembers, the average rise has been more than about 2.3 times the average fall. The convention is to call that overbought. It describes recent closes and does not mean a fall is due: in a persistent rise RSI can stay above 70 for a long time.
- Why is RSI usually set to 14?
- Because that is the length its author used when he published it in 1978, and most charting programs kept it as the default. It is a convention, not a discovery. A shorter length gives a livelier line that reaches the extremes more often; a longer one gives a calmer line that seldom does.
- Why does my RSI differ from the one on another chart?
- Usually for one of three reasons: a different length, a different way of averaging (Wilder’s smoothing or a plain average), or a different amount of price history behind the calculation. With Wilder’s smoothing every earlier bar has a small lasting effect, so the starting point matters a little.
The words on this page
An indicator is arithmetic on prices that have already happened. It describes what a price did; it does not predict what a price will do. The chart on this page is invented: a seeded random walk, not a market. This page is an explanation for study. It is not advice, a recommendation or a forecast, and nothing an indicator shows says anything certain about what a price will do next.
