# Retest & Break Setup

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

Detects the full break, retest, and continuation sequence: a pivot level breaks, price returns to test it a required number of times, then closes beyond the retest extreme to complete the setup. A dashboard tracks setup counts, completions, and post-breakout statistics. For traders who want breakout continuation with confirmation built in.

- Indicator in the LuxAlgo Library, by LuxAlgo, published Jun 19, 2026.
- Access: free.
- Concepts: [Breakout-pullback-continuation](https://www.luxalgo.com/library/concept/breakout-pullback-continuation/) (primary), [Breakout](https://www.luxalgo.com/library/concept/breakout/), [Retest](https://www.luxalgo.com/library/concept/retest/)
- Open on Vela: https://vela.luxalgo.com/chart?pineScriptCodeId=cmqkvszhf0002l704wx2ervgh
- Page: https://www.luxalgo.com/library/indicator/retest-break-setup/

**Retest & Break Setup** detects the full [breakout-pullback-continuation](https://www.luxalgo.com/library/concept/breakout-pullback-continuation/) sequence: a pivot level breaks, price returns to probe the level it just broke, and a close beyond the retest extreme confirms continuation. Pivot highs seed the bullish setups, pivot lows the bearish ones, and each stage draws as it develops.

## How to Trade the Retest & Break Setup?

- **Bullish setup**: price breaks a pivot high, the level holds as support through the required [retests](https://www.luxalgo.com/library/concept/retest/), and a close above the retest phase's highest high completes it.
- **Bearish setup**: the mirror. A broken pivot low acts as resistance, completed by a close below the retest phase's lowest low.
- **Dashed vs. solid lines**: dashed marks the broken pivot level under test; solid marks the trigger level at the retest extreme.
- **Shaded box + "Break" label**: printed when a setup completes; with complete-only display off, invalidated structures remain in faded gray.

Retests that hold concentrate stops and breakout orders around the extremes, so a confirmed break can tap that liquidity for a stronger continuation. The dashboard tracks Total (setups surviving every required retest), Completion (breakouts inside the window), and Win Rate (whether price still sat beyond the breakout level N bars on).

## Retest & Break Setup Settings

- **Length**: pivot significance. Higher finds major swing levels, lower catches fast intraday ones.
- **Required Consecutive Retests (K)**: touches the level must survive; more retests mean fewer but better-confirmed setups.
- **Max Bars between Retests (P)**: how quickly price must return. Slow retests invalidate the structure.
- **Max Bars for Break (N)**: the window in which the final breakout must occur.
- **Only Show Complete Setups**: hides invalidated patterns for a cleaner chart.
- **Setup Colors**, **Dashboard Settings**: pattern colors plus dashboard visibility, position, and size.

## Frequently Asked Questions

### How do I find longer-term setups?

Raise Length into the 10–20 area and widen N and P so larger structures have time to break, retest, and confirm: the swing-trading configuration. For scalping, lower Length and P to surface quick touch-and-go patterns, accepting more signals. You can also copy the source code from this page and run it anywhere Pine Script® runs.

### Is the dashboard's Win Rate predictive?

No. It is a historical check of how completed setups behaved N bars after breakout on the current chart and settings. Use it to compare configurations rather than as a forecast.

### How do I access it, and are there related tools?

It is free on the LuxAlgo Library. For tested breakout levels surfaced with a different detection style, [Breakouts with Tests & Retests](https://www.luxalgo.com/library/indicator/breakouts-with-tests-retests/) covers neighboring ground.

## Related indicators

- [Breakouts with Tests & Retests](https://www.luxalgo.com/library/indicator/breakouts-with-tests-retests/) (Breakout): markdown at https://www.luxalgo.com/library/indicator/breakouts-with-tests-retests.md
- [Breakout Detector (Previous MTF High Low Levels)](https://www.luxalgo.com/library/indicator/breakout-detector-previous-mtf-high-low-levels/) (Breakout): markdown at https://www.luxalgo.com/library/indicator/breakout-detector-previous-mtf-high-low-levels.md
- [Range Average Retest Model](https://www.luxalgo.com/library/indicator/range-average-retest-model/) (Retest): markdown at https://www.luxalgo.com/library/indicator/range-average-retest-model.md
- [Range Detector](https://www.luxalgo.com/library/indicator/range-detector/) (Trading Range): markdown at https://www.luxalgo.com/library/indicator/range-detector.md
- [False Breakout](https://www.luxalgo.com/library/indicator/false-breakout/) (Market Structure): markdown at https://www.luxalgo.com/library/indicator/false-breakout.md
- [Fibonacci Ranges (Real-Time)](https://www.luxalgo.com/library/indicator/fibonacci-ranges-real-time/) (Trading Range): markdown at https://www.luxalgo.com/library/indicator/fibonacci-ranges-real-time.md
- [Range Intelligence Suite](https://www.luxalgo.com/library/indicator/range-intelligence-suite/) (Trading Range): markdown at https://www.luxalgo.com/library/indicator/range-intelligence-suite.md
- [Parabolic Phase](https://www.luxalgo.com/library/indicator/parabolic-phase/) (Market Structure): markdown at https://www.luxalgo.com/library/indicator/parabolic-phase.md

---

Source: https://www.luxalgo.com/library/indicator/retest-break-setup/ (LuxAlgo Library). Free to use with attribution: https://www.luxalgo.com/library/license/
