Williams Fractals¶
Indicators · Pivots
Bill Williams's 5-bar fractal high / low detector.
Williams Fractals, from Bill Williams, marks the small recurring turning points in price — a fractal high is a bar with two lower highs on each side, a fractal low a bar with two lower lows on each side. They're the simplest formal definition of a local swing point, drawn as little arrows above and below the bars. Fractals give you a consistent, mechanical way to identify pivots for structure reading, stop placement, and breakout levels.
How it works¶
The block uses the classic 5-bar pattern: a fractal high is confirmed when a bar's high is greater than the highs of the two bars on each side of it (and the mirror for a fractal low). Because confirmation needs two bars to the right, every fractal carries a 2-bar lag — it can only be marked two bars after it actually formed, with no lookahead. The output is a stream of fractal points (swing dots) on the price pane that downstream logic can consume.
When to use it¶
Use Williams Fractals as a lightweight, fixed-definition pivot detector. They're handy for placing stops beyond the most recent fractal, for spotting the swing structure of a trend, and as breakout references (a break of the last fractal high). In Williams's own system they're combined with the Alligator — a fractal that forms outside the Alligator's "mouth" is a higher-quality signal. They're a fixed 5-bar definition, so for tunable swing sensitivity reach for Swings (adjustable lookback) instead; for noise-filtered major turns, ZigZag.
Example¶
Fractal-break entry: wire bars into Williams Fractals to mark the swing points, and trade a break of the most recent fractal high as a breakout — combine with an Alligator "mouth open" trend condition through an And gate into a Buy Signal. Place the Structural Stop-Loss below the last fractal low. Backtest in the Tester.
Tips & gotchas¶
- Fixed 5-bar definition — for tunable sensitivity use Swings, for filtered major turns ZigZag.
- 2-bar confirmation lag — honest, no lookahead, but never the exact bar.
- Pairs with the Alligator in Williams's system — fractals outside the mouth are stronger.
- Great for stop placement — beyond the most recent fractal.
Related blocks¶
Inputs¶
| Socket | Type | What to wire in |
|---|---|---|
| Bars | bars |
Price bars |
Outputs¶
| Output | Type | Plots as | Description |
|---|---|---|---|
| Fractals | swings |
Swing dots | Detected fractal highs and lows |
Reference auto-generated from the block catalog · category Indicators.