Relative Strength Index Calculator (RSI)

Relative Strength Index (RSI) Calculator

Turn a sequence of closing prices into Wilder-style RSI readings, inspect the latest momentum value, and export the full calculation trail to Excel.

Period 14 Prices 20 RSI points 6 Zone Neutral
Example workbook is ready.

Closing price inputs

Whole number from 2 to 100. A 14-period RSI is the conventional default.

Closing prices

Use positive decimal values in chronological order, oldest first. At least period + 1 prices are required for one RSI reading.

Latest RSI
57.92

Above 50 indicates positive momentum, but this reading is below the traditional 70 overbought level.

Latest close

45.64

Latest change

– 0.58

Average gain

0.1898

Average loss

0.1379

Relative strength

1.3761

Latest RSI is 57.92, based on 20 closing prices and a 14-period lookback.

RSI curve

The line plots each available RSI observation on the standard 0 – 100 oscillator scale. Dashed reference levels mark 30 and 70.

RSI6 observations; latest 57.92
Traditional levels70 overbought / 30 oversold

The latest point is 57.92 at Price 20. RSI can remain high or low during strong trends, so the level is context rather than a standalone trade instruction.

RSI calculation trail

Each row corresponds to a price where an RSI value is available. The averages use Wilder's recursive smoothing after the initial period.

Price index Close Change Gain Loss Avg gain Avg loss RS RSI

The first RSI uses simple averages over the selected period. Later rows update those averages using Wilder's smoothing: previous average × (period – 1), plus the current gain or loss, divided by the period.

How to use this Relative Strength Index calculator

What this calculator does

This calculator converts an ordered series of security closing prices into the Relative Strength Index, or RSI, using the classic Wilder method. RSI is a bounded momentum oscillator from 0 to 100. It compares the magnitude of recent upward price changes with recent downward price changes, then smooths those averages as new prices arrive. The result can help you describe momentum and spot stretches that traders often call overbought or oversold. It does not forecast a guaranteed price reversal, estimate intrinsic value, or tell you whether a particular investment is suitable for you. Fidelity's RSI indicator guide explains the conventional 70 and 30 reference levels and also notes that RSI can remain in extreme zones during strong trends.

When to use it

Use the calculator when you want to reproduce an RSI value from raw closes, audit the arithmetic behind an RSI shown on a charting platform, compare how a different lookback period changes momentum sensitivity, or inspect the sequence of smoothed gains and losses behind an RSI curve. It is also useful for teaching or spreadsheet work because the Excel export records both the inputs and the calculation trail.

How to calculate

  1. The calculator opens with a complete 20-price demonstration and a 14-period lookback, so the results, chart, table, and example XLSX are ready immediately.
  2. Replace the value in RSI period with a whole number from 2 to 100. The period is a count of price changes, not calendar days; a daily close series with period 14 therefore uses 14 daily changes.
  3. Edit Closing prices from oldest to newest. Use Add price to extend the series and Remove last to shorten it. At least period + 1 prices are needed for one RSI reading; at least period + 3 are needed for the line chart to contain three RSI observations.
  4. Read Latest RSI first, then use Latest close, Latest change, Average gain, Average loss, and Relative strength to understand what drove the oscillator. The RSI curve shows how the available RSI readings evolved, and the RSI calculation trail exposes every smoothed step.
  5. Select Download Excel to export the current validated state. Reset clears the demonstration data, removes extra price rows, and disables export until you enter a complete valid state again.

Input guide

RSI period is required and accepts an integer from 2 through 100. The conventional example is 14. A smaller period reacts more quickly because each new price change has more influence on the smoothed averages; a larger period generally produces a slower-moving RSI. Avoid entering decimals, a period greater than the available change count, or a value copied with units such as “14 days.” Closing prices are also required. Each Price field accepts a positive plain decimal in U.S.-style notation, such as 45.64 or 1,250.50; scientific notation, currency symbols, decimal commas, negative numbers, and mixed text are rejected. Enter prices chronologically, oldest first. Reversing the order changes every gain and loss and therefore changes the RSI. The Add and Remove controls only change the number of price fields; they do not invent or interpolate prices.

Output guide

Latest RSI is the newest oscillator reading, shown to two decimals. A value near 50 indicates roughly balanced smoothed gains and losses; a value above 50 means the smoothed gain is larger than the smoothed loss, while a value below 50 means the opposite. Traditional analysis often describes readings above 70 as overbought and below 30 as oversold, but these are context labels rather than certain reversal signals. Latest close is the newest input price. Latest change is the newest close minus the prior close. Average gain and Average loss are the current Wilder-smoothed positive and negative changes. Relative strength is average gain divided by average loss; when losses are zero, the finite RSI limit is 100 even though the ratio itself is not finite, so the calculator displays the ratio as not applicable rather than sending Infinity to the page or workbook. The summary pills report the selected Period, number of Prices, number of RSI points, and current Zone. In the table, Price index identifies the close used for that row; Close, Change, Gain, Loss, Avg gain, Avg loss, RS, and RSI are the exact model components used by the same results and export.

Worked example

The startup series begins at 44.34 and ends at 45.64 with period 14. For the first 14 changes, the average gain is about 0.2386 and the average loss is 0.1000, which gives the first RSI at Price 15 of about 70.46. Each later row applies Wilder's smoothing. By Price 20, the smoothed average gain is about 0.1898 and the smoothed average loss is about 0.1379. Relative strength is therefore about 1.3761, and RSI = 100 – 100 ÷ (1 + 1.3761) = 57.92. That number matches the first-open result, the final table row, the plotted final point, and the exported workbook.

Learn more

RSI is one technical-analysis input, not a complete investment decision process. Fidelity's current technical analysis overview describes oscillators as tools for reading momentum and emphasizes their probabilistic, non-guaranteed nature. For broader context, Investor.gov explains that all investments involve risk and that market prices can fluctuate for many reasons beyond a momentum indicator.

How the RSI formula works

RS = average gain ÷ average loss
RSI = 100 – 100 ÷ (1 + RS)

The initial average gain is the sum of positive price changes over the chosen period divided by that period. The initial average loss is the absolute sum of negative price changes divided by the same period. After the first RSI, the calculator follows Wilder's recursive smoothing for both averages: new average = (previous average × (period – 1) + current component) ÷ period. A flat change contributes zero to both gain and loss. If every change in the initial window is flat, RSI is treated as 50 because neither side has momentum; if average loss is zero but gains are positive, RSI is 100; if average gain is zero but losses are positive, RSI is 0.

Interpreting high and low RSI readings

A high RSI describes strong recent gains relative to recent losses; a low RSI describes the reverse. The conventional 70/30 zones are widely used, but the same reading can mean different things in a persistent trend, a range-bound market, or a very volatile security. RSI divergence – when price and oscillator direction differ – can be informative, but it still needs context. Avoid treating a threshold crossing as a guaranteed buy or sell signal. Investor.gov's guidance on researching investments is a useful reminder to combine market indicators with broader due diligence.