TradeReign
Back to HomeEducation HubCompatibilityAboutDisclosures
TradingView Indicators

How to Add a Moving Average to RSI Check the Source in TradingView

A price average and an RSI average can use the same candles but produce values in different units. Check what feeds the moving average before using it in a chart rule or alert.

Quick Answer

In TradingView, add RSI and Simple Moving Average to the chart. Open the moving average’s Settings → Inputs → Source and select the main RSI plot. Set Length to 3 and Offset to 0 for the example below. If you only need a moving average of RSI, you can also use the Smoothing setting inside RSI.

Start 7-Day TrialMore Guides

Set the moving average’s source to RSI

Open a standard five-minute chart on a dated MES contract. Add the built-in Relative Strength Index from Indicators. Set RSI Length to 14 and Source to Close. For this check, set the RSI indicator’s Smoothing Type to None so the main plot is easy to identify.

Add Simple Moving Average. In its own Settings → Inputs, open Source and select the main RSI plot. Set Length to 3 and Offset to 0. The alternative route is to use the three-dot menu next to RSI and choose Add indicator/Strategy on…, then find the moving average. Either way, reopen its settings and confirm which plot the new average uses.

If you only want an average alongside the RSI line, open RSI’s Inputs → Smoothing, choose SMA and enter Length 3. Use that built-in output or the separate indicator for this check so you can identify the line you are reading.

Verify three values on the same completed bar

In your chart’s Data Window, read the completed RSI values at the target candle and the two preceding closes. Add those values and divide by three. Match the average at the same bar with Offset set to 0. Use the full stored precision for the calculation when possible. Rounded readings can differ by a hundredth.

At A in the fictional MES chart, the average of the three RSI readings is 56.30. The average of the three closing prices is 6,001.33. If your moving average is near the futures price, reopen its Source and check whether it still says Close. The main RSI calculation here uses 24 earlier fictional closes before the displayed candles.

Three fictional five-minute inputs for marker A
Bar close (ET)MES closeRSI
10:356,001.2556.47
10:406,002.0061.41
10:456,000.7551.01

A three-period SMA on the 14-period RSI

Synthetic MES 5-minute candles. Times are bar closes in ET.

At A (10:45 ET), the gold three-period average of RSI is 56.30. With Close as the source instead, the same three bars give a price average of 6,001.33. The blue line shows the original 14-period RSI.

What to check if the TradingView Source option is missing

Open the settings for the indicator that is supposed to receive the data. Confirm both indicators are loaded on the same chart and look for Source under Inputs. Some scripts do not accept an external source. TradingView documents an input.source() field for Pine scripts that do. The source must come from an indicator plot. A strategy can receive an indicator input, but its outputs cannot serve as this external source.

If the RSI name is present but the value is wrong, check the plot selected and whether an extra smoothing overlay is active. Compare three completed bars again to isolate the input. If an alert uses the old settings, verify its saved copy separately before changing a notification or relying on it.

Sources

Official References

Platform details on this page were checked against these official resources.

TradingView’s external indicator inputsCheck the More menu route, Source control and which scripts can supply a plot.TradingView Simple Moving Average documentationVerify the arithmetic, Source and Offset.TradingView built-in indicator smoothingSee how the smoothing control adds an average to RSI.TradingView’s Pine indicator FAQCheck which script inputs support an external plot.
Related Guides

Keep Building the Rule System

Compare NinjaTrader and TradingView RSI

Check the chosen plot and starting history on the same completed futures candle.

Use price and RSI together in an alert

Verify both conditions at the intended bar close.

FAQ

Common Questions

Can I smooth RSI without adding another indicator in TradingView?

Yes. Open RSI Settings, go to Inputs and use its Smoothing section. Choose SMA and set the length to control how many RSI readings enter the average.

Why is my moving average near the futures price instead of the RSI values?

Check that the receiving moving average uses the RSI plot as its Source. With Close selected, it averages prices in the instrument’s units.

Risk Disclosure

Futures trading contains substantial risk and is not suitable for every investor. TradeReign is a trading-discipline and rule-enforcement application. It does not provide trading advice, trade signals, investment recommendations, or performance guarantees.

TradeReign is not a broker-dealer, futures commission merchant, or investment advisor.

Futures trading contains substantial risk and is not for every investor. An investor could potentially lose all or more than the initial investment. Only risk capital - money that can be lost without jeopardizing financial security or lifestyle - should be used for trading. Past performance is not necessarily indicative of future results.