OPEN-SOURCE SCRIPT
RSI

MT5-Style RSI Zones (20/30/70/80) with Signals & Alerts
Description (English first)
What it does
This script reproduces an MT5-style RSI with four-level zones (20/30/70/80) to better distinguish early/late overbought-oversold conditions. It highlights zone transitions, plots optional background shading, and triggers entry/exit alerts on precise crossings.
How it works (high-level logic)
Core is Wilder’s RSI on close (length = <default 14>).
Two oversold bands at 20 and 30; two overbought bands at 70 and 80.
Optional smoothing (<EMA/SMA>), and MTF confirmation (optional) compares current RSI vs a higher timeframe RSI.
Signals:
Long setup: RSI crosses above 20 (early) or 30 (conservative); confirmation if higher-TF RSI is rising.
Take-profit / exit: RSI fails to hold above 70 or crosses below 70 after being >80.
Short setup: mirror logic with 70/80 → 30/20.
Inputs
RSI Length (<14>), Source (close)
Upper Bands (70, 80), Lower Bands (30, 20)
Smoothing (<EMA 3> on RSI, optional)
Higher Timeframe (<none / 60>), Confirm with HTF (on/off)
Background Zones (on/off), Alerts (on/off)
How to use
Choose your market/timeframe. For FX/indices, M5–H1 works well; for swing, H1–H4.
Pick your aggressiveness: use 20/80 for early reversals, 30/70 for conservative trend pullbacks.
With MTF confirmation on, prioritize entries aligned with the higher timeframe RSI slope.
Combine with structure (S/R) or a simple MA filter for trend direction.
Originality & usefulness
Unlike generic RSI scripts, this version provides dual-zone logic (20/30/70/80) with clear visual states, optional HTF confirmation, and ready-made alerts designed to match MetaTrader-like RSI workflows. It is not a direct clone of public open-source scripts; zone handling and alert conditions are purpose-built for timing pullbacks vs. extremes.
Best markets & limitations
Works on FX, gold (XAUUSD), and indices (US30/NAS100).
In strong trends, overbought/oversold can persist—use bands as context, not standalone signals.
Spikes around news can cause false triggers—consider widening bands or disabling trades near events.
Alerts included
RSI Crosses Above 20, RSI Crosses Above 30
RSI Crosses Below 70, RSI Crosses Below 80
MTF Confirmed Long/Short (optional)
User interface translations (if your UI is in Spanish)
RSI Length → Periodo RSI
Upper Bands → Bandas Superiores
Lower Bands → Bandas Inferiores
Smoothing → Suavizado
Higher Timeframe → Marco Temporal Superior
Confirm with HTF → Confirmar con MTS
Background Zones → Zonas de Fondo
Alerts → Alertas
Disclaimer
This tool is for educational purposes. Not financial advice.
Description (English first)
What it does
This script reproduces an MT5-style RSI with four-level zones (20/30/70/80) to better distinguish early/late overbought-oversold conditions. It highlights zone transitions, plots optional background shading, and triggers entry/exit alerts on precise crossings.
How it works (high-level logic)
Core is Wilder’s RSI on close (length = <default 14>).
Two oversold bands at 20 and 30; two overbought bands at 70 and 80.
Optional smoothing (<EMA/SMA>), and MTF confirmation (optional) compares current RSI vs a higher timeframe RSI.
Signals:
Long setup: RSI crosses above 20 (early) or 30 (conservative); confirmation if higher-TF RSI is rising.
Take-profit / exit: RSI fails to hold above 70 or crosses below 70 after being >80.
Short setup: mirror logic with 70/80 → 30/20.
Inputs
RSI Length (<14>), Source (close)
Upper Bands (70, 80), Lower Bands (30, 20)
Smoothing (<EMA 3> on RSI, optional)
Higher Timeframe (<none / 60>), Confirm with HTF (on/off)
Background Zones (on/off), Alerts (on/off)
How to use
Choose your market/timeframe. For FX/indices, M5–H1 works well; for swing, H1–H4.
Pick your aggressiveness: use 20/80 for early reversals, 30/70 for conservative trend pullbacks.
With MTF confirmation on, prioritize entries aligned with the higher timeframe RSI slope.
Combine with structure (S/R) or a simple MA filter for trend direction.
Originality & usefulness
Unlike generic RSI scripts, this version provides dual-zone logic (20/30/70/80) with clear visual states, optional HTF confirmation, and ready-made alerts designed to match MetaTrader-like RSI workflows. It is not a direct clone of public open-source scripts; zone handling and alert conditions are purpose-built for timing pullbacks vs. extremes.
Best markets & limitations
Works on FX, gold (XAUUSD), and indices (US30/NAS100).
In strong trends, overbought/oversold can persist—use bands as context, not standalone signals.
Spikes around news can cause false triggers—consider widening bands or disabling trades near events.
Alerts included
RSI Crosses Above 20, RSI Crosses Above 30
RSI Crosses Below 70, RSI Crosses Below 80
MTF Confirmed Long/Short (optional)
User interface translations (if your UI is in Spanish)
RSI Length → Periodo RSI
Upper Bands → Bandas Superiores
Lower Bands → Bandas Inferiores
Smoothing → Suavizado
Higher Timeframe → Marco Temporal Superior
Confirm with HTF → Confirmar con MTS
Background Zones → Zonas de Fondo
Alerts → Alertas
Disclaimer
This tool is for educational purposes. Not financial advice.
Açık kaynak kodlu komut dosyası
Gerçek TradingView ruhuna uygun olarak, bu komut dosyasının oluşturucusu bunu açık kaynaklı hale getirmiştir, böylece yatırımcılar betiğin işlevselliğini inceleyip doğrulayabilir. Yazara saygı! Ücretsiz olarak kullanabilirsiniz, ancak kodu yeniden yayınlamanın Site Kurallarımıza tabi olduğunu unutmayın.
Feragatname
Bilgiler ve yayınlar, TradingView tarafından sağlanan veya onaylanan finansal, yatırım, işlem veya diğer türden tavsiye veya tavsiyeler anlamına gelmez ve teşkil etmez. Kullanım Şartları'nda daha fazlasını okuyun.
Açık kaynak kodlu komut dosyası
Gerçek TradingView ruhuna uygun olarak, bu komut dosyasının oluşturucusu bunu açık kaynaklı hale getirmiştir, böylece yatırımcılar betiğin işlevselliğini inceleyip doğrulayabilir. Yazara saygı! Ücretsiz olarak kullanabilirsiniz, ancak kodu yeniden yayınlamanın Site Kurallarımıza tabi olduğunu unutmayın.
Feragatname
Bilgiler ve yayınlar, TradingView tarafından sağlanan veya onaylanan finansal, yatırım, işlem veya diğer türden tavsiye veya tavsiyeler anlamına gelmez ve teşkil etmez. Kullanım Şartları'nda daha fazlasını okuyun.