Relative Strength Index Calculator (RSI)

Compute the Relative Strength Index using J. Welles Wilder's smoothing formula from your previous average gain/loss and the latest period's price move, then see whether the reading sits in oversold, neutral, or overbought territory.

Quick Facts

Formula
RSI = 100 − 100 / (1 + RS)
RS is the smoothed average gain divided by the smoothed average loss over the look-back period.
Standard period
14 bars
Wilder's original 1978 default; 9 reacts faster, 21 or 25 smooths out more noise.
Common zones
Above 70 overbought, below 30 oversold
Conventions, not guarantees — strong trends can stay in either zone for a long stretch.

Your Results

Calculated
RSI (0–100)
-
Momentum reading
Smoothed average gain
-
Wilder-smoothed gain per period
Smoothed average loss
-
Wilder-smoothed loss per period
Relative strength (RS)
-
Average gain ÷ average loss

Ready

Enter your previous average gain/loss and the latest period's price change, then press Calculate.

How the RSI Calculator works

The Relative Strength Index (RSI) is a momentum oscillator developed by J. Welles Wilder and published in his 1978 book New Concepts in Technical Trading Systems. It measures the speed and size of recent price changes on a scale of 0 to 100, comparing the average size of gains against the average size of losses over a chosen look-back period (14 bars by default). This calculator uses Wilder's own smoothing method — the same formula used in most charting platforms — rather than a plain simple average.

The formula

Wilder's RSI blends the prior period's average gain and loss with the latest period's move, weighted so that the older average carries (N−1) parts and the newest data point carries 1 part, where N is the RSI period:

Average Gain = (Previous Average Gain × (N−1) + Current Gain) / N
Average Loss = (Previous Average Loss × (N−1) + Current Loss) / N

From those smoothed averages, Relative Strength and RSI follow directly:

RS = Average Gain / Average Loss
RSI = 100 − (100 / (1 + RS))

Gains and losses are always entered as positive numbers — a losing period contributes to "loss," never a negative "gain." If a period closes higher than it opened (or higher than the prior close), its move counts as a gain and the loss for that period is zero, and vice versa.

Worked example

Suppose the previous average gain was 1.10 points and the previous average loss was 0.85 points over a 14-period RSI, and the latest period closed up 0.30 points (so current loss is 0). The smoothed average gain becomes (1.10 × 13 + 0.30) / 14 ≈ 1.0429, and the smoothed average loss becomes (0.85 × 13 + 0) / 14 ≈ 0.7893. Relative Strength is RS = 1.0429 / 0.7893 ≈ 1.3213, giving RSI = 100 − 100 / (1 + 1.3213) ≈ 56.9 — a neutral-to-firm reading, not yet overbought.

Why "previous" average gain and loss?

RSI is not recomputed from scratch each period; it is a smoothed moving average, so each new reading depends on the prior one. For the very first RSI calculation on a fresh dataset, the "previous" average gain and loss are simply the plain average of gains and average of losses over the first N periods — no smoothing yet. From the second calculation onward, every new average blends the previous smoothed average with the newest period's move using the weighting above. If you only have a single period of data, enter your first-N-period simple averages as the "previous" values and the next period's move as the current gain or loss.

Overbought, oversold, and their limits

Traders commonly treat RSI readings at or above 70 as overbought and at or below 30 as oversold, with 80/20 sometimes used as "extreme" thresholds. These levels describe how lopsided recent gains versus losses have been — they are not a prediction. In a strong, sustained uptrend RSI can stay above 70 for a long stretch, and in a strong downtrend it can stay below 30, so an overbought or oversold reading on its own is not a signal to act, only a description of recent momentum.

What moves the RSI reading most

  • The size of the latest move relative to the recent average: because only 1 of the N weighting parts is "new," a single large move shifts RSI less than a string of consecutive moves in the same direction.
  • The RSI period: a shorter period (e.g., 9) reacts faster and crosses 70/30 more often; a longer period (e.g., 21 or 25) is smoother and crosses those levels less often.
  • An unbroken run of gains or losses: if average loss falls to zero (every recent period was an up period), RS is undefined and RSI caps at 100; if average gain falls to zero (every recent period was a down period), RSI caps at 0.

Frequently Asked Questions

How is RSI calculated?
RSI uses J. Welles Wilder's smoothing formula: Average Gain = (Previous Average Gain × (N−1) + Current Gain) / N, and Average Loss = (Previous Average Loss × (N−1) + Current Loss) / N, where N is the RSI period (14 by default). Relative Strength RS = Average Gain / Average Loss, and RSI = 100 − (100 / (1 + RS)).
What do RSI readings above 70 or below 30 mean?
An RSI at or above 70 is traditionally read as overbought, meaning average gains have outpaced average losses by a wide margin over the period. An RSI at or below 30 is read as oversold, the opposite case. Readings above 80 or below 20 are sometimes called extreme. These are conventions, not guarantees of a reversal — a strong trend can stay overbought or oversold for a long stretch.
Why does the calculator ask for a previous average gain and loss?
Wilder's RSI is a smoothed (exponential-style) moving average, not a simple average recalculated from scratch each period. Every new RSI reading blends the prior period's average gain and loss with the latest period's gain or loss, weighted (N−1)-to-1. That is why the standard formula needs the previous averages as inputs, not just today's price change.
What RSI period should I use?
Wilder's original 1978 default is 14 periods (days on a daily chart). Shorter periods such as 9 react faster and swing between overbought and oversold more often; longer periods such as 21 or 25 smooth the line and reduce false signals but respond more slowly to price changes. There is no single correct period — it depends on the timeframe and the sensitivity you want.