# RSI Failure Swing

RSI Failure Swing is an indicator on [Vela](https://vela.luxalgo.com/chart), our next-generation charting platform, written in Pine Script®.

Runs Wilder's failure swing pattern as a state machine on a 14-period RSI, drawing each setup's swing legs, a dashed fail point line, and HL/LH labels, then marking Bull FS or Bear FS when the fail point breaks. Detection reacts only to confirmed swings (3 bars on each side by default), so Bull FS and Bear FS marks stay put once printed, while an armed setup's HL or LH mark can move to a deeper pullback and its drawings clear if it fails. Setup and completion alerts cover both sides.

- Indicator in the LuxAlgo Library, by LuxAlgo, published Jun 24, 2026.
- Access: free.
- Concepts: [RSI Failure Swing](https://www.luxalgo.com/library/concept/rsi-failure-swing/) (primary)
- Open on Vela: https://vela.luxalgo.com/chart?pineScriptCodeId=tzqmj7xcaet2ct15alic7qsa
- Page: https://www.luxalgo.com/library/indicator/rsi-failure-swing/

**RSI Failure Swing** is the definitive clean build of Wilder's [RSI failure swing](https://www.luxalgo.com/library/concept/rsi-failure-swing/), run as a four-stage state machine on the oscillator itself. The pane plots a 14-period RSI colored by its side of the 50 midline, with dashed bands at 70 and 30; as a sequence unfolds it draws the swing legs, a dashed fail point line, and labels at the fail point and the higher low or lower high. Detection reacts only to swings confirmed by the Swing Strength window, so completion labels do not repaint.

## How to Trade the RSI Failure Swing?

- **Bull FS**: RSI broke above its fail point after holding a higher low above an oversold swing low, the traditional completion trigger.
- **Bear FS**: the mirror image: RSI broke below its fail point after a lower high beneath an overbought swing high.
- **Fail Point Line**: while a setup is armed, the dashed line marks the level whose break completes the swing.
- **HL / LH labels**: the pullback that arms a setup; aggressive entries key off these, conservative ones wait for the break.

Setup and Completed alerts cover both directions.

## RSI Failure Swing Settings

- **RSI Length** (default 14): lookback of the Wilder RSI the swings are read on.
- **Source** (default close): series the RSI is computed from.
- **Overbought Level** (default 70) / **Oversold Level** (default 30): the extremes a sequence must start beyond.
- **Swing Strength** (default 3): bars required on each side of a turning point; higher values isolate larger structures but confirm later.
- **Strict Pullback Rule** (default enabled): voids a setup when RSI re-enters the extreme zone, restarting detection.
- Style toggles for the gradient fill, swing structure, fail point line, and both label sets are on by default.

## Frequently Asked Questions

### How does this differ from Cardwell positive and negative reversals?

Both patterns live on the RSI, but [Cardwell positive & negative reversals](https://www.luxalgo.com/library/indicator/cardwell-positive-negative-reversals/) compare oscillator swings against the prices that produced them and argue for continuation. A failure swing needs no price reference at all, and its message is reversal.

### Why must the first swing start beyond 70 or 30?

The opening excursion is what separates a real momentum turn from mid-range noise. The build enforces it literally: bullish sequences anchor only on swing lows below the Oversold Level, bearish ones only on swing highs above the Overbought Level.

### Do the labels repaint?

Completion labels do not. A swing point needs Swing Strength bars on each side before it exists, and the state machine advances on confirmed bars only, so a Bull FS or Bear FS label stays put once printed. An armed setup's drawings are provisional: its HL or LH label and pullback leg move to a deeper confirmed swing if one forms, and its legs, fail point line and labels are removed if the setup is invalidated before it completes, so failed setups do not stay on the chart. The cost is confirmation delay, which grows with Swing Strength.

## Related indicators

- [RSI Divergence: Out-of-Sample Optimizer](https://www.luxalgo.com/library/indicator/rsi-divergence-out-of-sample-optimizer/) (RSI): markdown at https://www.luxalgo.com/library/indicator/rsi-divergence-out-of-sample-optimizer.md
- [Ultimate RSI](https://www.luxalgo.com/library/indicator/ultimate-rsi/) (RSI): markdown at https://www.luxalgo.com/library/indicator/ultimate-rsi.md
- [RSI-2](https://www.luxalgo.com/library/indicator/rsi-2/) (Momentum & Oscillators): markdown at https://www.luxalgo.com/library/indicator/rsi-2.md
- [RSI Candlestick Oscillator](https://www.luxalgo.com/library/indicator/rsi-candlestick-oscillator/) (RSI): markdown at https://www.luxalgo.com/library/indicator/rsi-candlestick-oscillator.md
- [RSI Multi Length](https://www.luxalgo.com/library/indicator/rsi-multi-length/) (RSI): markdown at https://www.luxalgo.com/library/indicator/rsi-multi-length.md
- [RSI of Other Sources](https://www.luxalgo.com/library/indicator/rsi-of-other-sources/) (Momentum & Oscillators): markdown at https://www.luxalgo.com/library/indicator/rsi-of-other-sources.md
- [Adaptive Bounds RSI](https://www.luxalgo.com/library/indicator/adaptive-bounds-rsi/) (RSI): markdown at https://www.luxalgo.com/library/indicator/adaptive-bounds-rsi.md
- [RSI Prediction by Range Segmentation](https://www.luxalgo.com/library/indicator/rsi-prediction-by-range-segmentation/) (RSI): markdown at https://www.luxalgo.com/library/indicator/rsi-prediction-by-range-segmentation.md

---

Source: https://www.luxalgo.com/library/indicator/rsi-failure-swing/ (LuxAlgo Library). Free to use with attribution: https://www.luxalgo.com/library/license/
