What RSI actually measures

RSI is an average of gains against an average of losses over a window. That sentence explains every property people find surprising about it.

11 minute read · no account needed · nothing on this page is advice about what to buy or sell

What you will leave with

  • The formula: average gain over average loss across the lookback, normalised onto 0–100.
  • Wilder smoothing is not the same as a simple mean, which is why two platforms can print different values for RSI(14) and both be right about their own convention.
  • Why 70 and 30 are conventions rather than signals, and why they are reached constantly in a trend.
  • Why the first values on a short series are unreliable, and how many bars of lead-in a Wilder-family study needs before it settles.
  • What divergence claims, and what it does not.

01One sentence, and everything follows from it

RSI is an average of the bars that went up divided by an average of the bars that went down, over a lookback window, squashed onto a 0–100 scale. That is the whole indicator. Nearly every property people find surprising about it — that it can sit above 70 for months, that two platforms print different numbers, that the first few values on a short chart are unusable — falls straight out of that sentence once you take it literally.

Written out: take the change from each close to the next. Split those changes into gains (the positive ones) and losses (the absolute value of the negative ones). Average each side over the lookback. Divide the average gain by the average loss to get RS, the relative strength. Then map RS, which runs from 0 to infinity, onto 0 to 100:

closesone per barchangescloseᵢ − closeᵢ₋₁gainschange if > 0losses−change if < 0RSavg gain ÷ avg lossRSI = 100 − 100 / (1 + RS)maps 0…∞ onto 0…100“Average” is theload-bearing word: it isWilder’s smoothed average,not a simple mean and notan exponential movingaverage — see part 4.
The whole calculation. Every disagreement between implementations lives in one word: “average”.

Two consequences are worth reading off the formula immediately. RSI is bounded, so it can never tell you how big a move is — only how one-sided it has been. And RSI is a ratio, so it does not care about the size of the price at all: a stock at $4 and a stock at $4,000 with identically shaped moves have identical RSI.

02The calculation, on numbers you can check

The canonical worked example is Wilder’s own, published in New Concepts in Technical Trading Systems in 1978: 33 closing prices and the RSI(14) column he computed from them. Take the first 14 changes — that is closes 1 through 14, because close 0 has nothing before it to subtract:

Seed average gain
the mean of the 14 gains = 0.2384
Seed average loss
the mean of the 14 losses = 0.0996
RS
0.2384 ÷ 0.0996 = 2.3936
First RSI
100 − 100 / (1 + 2.3936) = 70.53 — the value Wilder published for that bar is 70.53.

From there the averages are updated rather than recomputed. Each new bar contributes one fourteenth of itself and keeps thirteen fourteenths of what was there before:

next average = (previous average × (14 − 1) + this bar's value) / 14

03Wilder’s published column, next to this product’s output

The table below is computed when this page is built. The left column is Wilder’s published series, transcribed from the worked example. The middle column is what the indicator engine on this site produces when it is handed the same 33 closes — the same code that draws RSI on a live chart here and the same code the alert worker runs. The right column is the subtraction.

BarCloseWilder, 1978This engineDifference
1446.282070.5370.5328+0.0028
1546.002866.3266.3186−0.0014
1646.032866.5566.5498−0.0002
1746.411669.4169.4063−0.0037
1846.222266.3666.3552−0.0048
1945.643957.9757.9749+0.0049
2046.212262.9362.9296−0.0004
2146.252163.2663.2571−0.0029
2245.713756.0656.0593−0.0007
2346.451562.3862.3771−0.0029
2445.783554.7154.7076−0.0024
2545.354850.4250.4228+0.0028
2644.028839.9939.9898−0.0002
2744.178341.4641.4605+0.0005
2844.218141.8741.8689−0.0011
2944.567245.4645.4632+0.0032
3043.420537.3037.3040+0.0040
3142.662833.0833.0795−0.0005
3243.131437.7737.7730+0.0030

The largest disagreement anywhere in that table is 0.0049 RSI points. The published column is rounded to two decimals at source, so half a rounding step is 0.005 — which means the difference is not a difference at all, it is the rounding in Wilder’s own printed column. The first value lands at bar 14, as published.

04Why two platforms print different RSIs, and both are right

The word “average” in the definition is doing more work than it looks. There are three plausible readings and all three ship somewhere:

Wilder’s smoothing
α = 1/14, seeded with the simple mean of the first 14 changes. This is what Wilder defined and what the table above reproduces.
An EMA of period 2p−1
The most widely repeated equivalence in this corner of the field, and it is half true in a way that catches people out. The decay rates really are identical — an EMA of period 27 uses α = 2/28, which is 1/14. What differs is the seed, and a recursion that never forgets its seed never fully converges, so the two series stay apart — furthest apart at exactly the left-hand end of a short chart.
Simple moving averages
Sometimes called Cutler’s RSI. Replacing both smoothed averages with plain rolling means gives a visibly faster line that can disagree by several points through a sustained trend. It is also what a spreadsheet reimplementation usually produces by accident.

None of these is wrong; they are different definitions wearing the same three letters. What is unreasonable is a chart that does not tell you which one it implements, because then a reading of 68 against somebody else’s 71 has no explanation and no resolution. If you are ever reconciling two platforms, check the convention before you check anything else — and check the lookback, since a surprising number of tools quietly default to something other than 14.

05How much history an RSI needs before it means anything

Everything in the previous section reduces to one fact: the smoothed average never fully forgets where it started. After n bars the seed still carries a weight of (1 − 1/14)ⁿ — geometric decay, never zero.

100%01435%502%940.09%250under 0.01%bars of history since the series began
How much of an RSI(14) reading is still the arbitrary value it was seeded with. Getting the seed’s influence under a tenth of a percent takes 94 bars. At 250 — the lead-in a Wilder-family study wants before it is worth comparing with anybody else’s — it is under a millionth.

The practical rule this implies is unglamorous and worth following anyway: a Wilder-family study wants a couple of hundred bars of lead-in before its output is comparable with anybody else’s. It is also why a chart that computes an indicator only over the bars currently on screen shows a line that shifts every time you scroll — the shift is not a bug in the indicator, it is the seed moving. A chart that fetches lead-in beyond the left edge of the viewport does not have that problem, and the difference is visible the moment you drag.

0670 and 30 are conventions, and a trend will sit above 70 for weeks

Wilder proposed 70 and 30 as levels of interest, not as instructions. It helps to see what the arithmetic actually implies: RSI is above 70 when the average gain is more than 2.33 times the average loss. In a market that is genuinely trending, that is not an extreme condition — it is the definition of the trend.

priceRSI(14)7030
A rising series with real pullbacks in it, and the RSI(14) computed from it by the engine on this site. 46 of its 76 readings are at or above 70, and the deepest it ever gets is 54.0 — nowhere near 30. Selling every reading above 70 would have meant selling the whole advance, repeatedly.

The useful framing is that RSI measures one-sidedness, and one-sidedness is what a trend is. “Overbought” is a name for a reading, not a diagnosis. The reading is informative in a range, where it does mean the move has run further than the recent average, and much less informative in a trend, where it will pin near an extreme and stay there. Any rule built on the levels needs to know which of those two regimes it is in, and nothing in RSI itself tells you.

07What divergence claims, and what it does not

Divergence is the observation that price made a higher high while RSI made a lower one (or the reverse). What that literally means is precise and modest: the second advance was less one-sided than the first, relative to the 14-bar window. Fewer up bars, or up bars of a smaller average size, or more down bars mixed in.

That is a real statement about the character of a move. What it is not is a statement about what happens next, and two properties make it treacherous to trade mechanically. It can only be identified after the second high has formed, which means the pivot it is drawn from was not knowable at the time. And in a strong trend it recurs repeatedly without resolving — a series of ever-less-one-sided advances is exactly what a decelerating but continuing trend produces.

08What to keep

It is a ratio
Average gain over average loss, normalised onto 0–100. Bounded, and blind to the size of the price.
The average is Wilder’s
Not a simple mean and not quite an EMA. This is where platforms diverge, and it is checkable.
The first value is at bar p
Not p−1, and every later value inherits the seed.
Lead-in matters
A couple of hundred bars before the number is comparable with anybody else’s.
70 and 30 are conventions
A trend lives above 70. The levels describe one-sidedness, not opportunity.

Where Chartwright comes into it

Ours states its convention in the settings panel and exposes the alternative as a parameter, because an indicator whose convention you cannot see is one you cannot reconcile against anybody else’s.

Open a chartWhat it does

Keep reading