Harmonic Patterns: automatic XABCD detection with a reversal zone
Harmonic Patterns scans your chart for XABCD structures and draws them for you. It recognises Gartley, Bat, Alternate Bat, Butterfly, Crab, Deep Crab, Shark, Cypher, 5-0 and AB=CD, measures every leg against the Fibonacci ratios of the pattern, and labels the result. While the last leg is still forming it projects the potential reversal zone (PRZ) ahead of price, so you see the area where the pattern would complete before it gets there.

What the indicator is
A harmonic pattern is a sequence of swing points whose legs relate to each other by specific Fibonacci ratios. Finding them by hand means measuring three or four ratios on every candidate. The indicator does that work on each new swing.
It starts from confirmed swing pivots. A high or low counts as a pivot once it has Pivot strength bars on each side (5 by default), and the pivots alternate between highs and lows. Each time a new pivot is confirmed, the indicator takes the last five pivots as X, A, B, C and D and tests them against the ratio windows of every enabled pattern: AB against XA, BC against AB, CD against BC, and AD against XA. For the Cypher, D is measured against XC instead. If several patterns fit, the closest match wins. If no five-point pattern fits, the last four pivots are tested for an AB=CD.
Ratio tolerance controls how strict the match is. The default of 0.20 allows each ratio to sit within 20% of the window the pattern defines.
A bullish pattern completes at a low D and points up. A bearish pattern completes at a high D and points down.
Harmonic Patterns comes with SabrTrader on the Pro, Ultimate and Perpetual plans. There is no separate licence. The same plans include the rest of the premium library, such as TDU Auto Fibs, Market Structure and Volume Profile.
How to read it on the chart
Completed patterns
A completed pattern is drawn as solid lines from X to A to B to C to D, with a translucent fill, a letter at each point and the pattern name in bold next to D. AB=CD has four points, so it starts at A. Bullish patterns use the bullish colour (green by default) and bearish patterns the bearish colour (red by default). Turn on Show ratios to print the measured ratio of each leg next to B, C and D.
A completed pattern stays on the chart until one of three things happens: price closes beyond its far anchor (the more extreme of X and D), it becomes older than Maximum pattern age (bars), or newer patterns push it past Max patterns on chart.
Emerging patterns
When X, A, B and C already fit a pattern and only D is missing, the indicator draws the pattern as emerging. The last leg is dashed, the end point is labelled D?, and the name reads, for example, "Emerging Bat". One emerging pattern is shown at a time, and only while it is relevant: price must not have closed through the zone, and the zone must be within two zone-heights of the current close.
The potential reversal zone
The PRZ is the price band where D should fall for the pattern to be valid. It is drawn as a rectangle from C to the right, past the last bar by PRZ extension (bars). With Fibonacci time zones on, the rectangle is split into coloured slices that measure time from C against the length of the XA leg (the AB leg for AB=CD). The slices are labelled 1, 1.128, 1.272, 1.414, 1.618 and 2 and run from green through yellow, orange and red to magenta. Green means the pattern is completing on schedule. Magenta means it has taken twice as long as the first leg and is getting stale.
Three ways traders use it
Plan the entry in advance
Use the emerging pattern and its PRZ to mark where you want to see a reaction. You know the area and the direction before price arrives, which leaves time to set a working order or an alert.
Trade the confirmed D
Wait for the pattern to complete and the alert to fire, then look for your own trigger in the direction of the pattern. The far anchor of the pattern is the natural place where the idea is wrong, and it is also where the indicator removes the pattern.
Filter by direction
Set Direction to BullishOnly or BearishOnly to see only patterns that agree with your higher time frame view.
Add a second opinion
A PRZ that overlaps a level from TDU Pivots or a volume node from Volume Profile gives two independent reasons to watch the same price.
Let the chart do the measuring
Harmonic Patterns is included in Pro, Ultimate and Perpetual together with the whole premium library.
Download SabrTrader free See plans & pricingHow to add it in SabrTrader
- Open a chart of the instrument you trade and load enough history for several swings.
- Add the indicator. Open the indicator list, search for Harmonic Patterns and add it. It draws on the price panel.
- Start with the defaults. All ten patterns are enabled, emerging patterns and the PRZ are shown, and the alert for completed patterns is on.
- Tune the swing size. Raise Pivot strength for fewer and larger patterns, lower it for more and smaller ones. Raise Minimum leg (ticks) to drop patterns whose first leg is too small to trade.
- Narrow the list. Untick the patterns you do not trade in the Patterns group.
Settings reference
Detection
| Setting | Default | What it does |
|---|---|---|
| Pivot strength | 5 | Bars on each side of a swing needed to confirm a pivot. Range 1 to 50. |
| Ratio tolerance | 0.20 | Relative tolerance applied to every Fibonacci ratio window. Range 0 to 0.5. |
| Minimum leg (ticks) | 10 | Minimum size of the XA leg (AB for AB=CD) in ticks. |
| Maximum pattern age (bars) | 500 | Completed patterns older than this are removed. Patterns that span more bars than this are not detected. |
| Max patterns on chart | 10 | How many completed patterns stay drawn. The oldest drop off first. |
| Direction | Both | Both, BullishOnly or BearishOnly. |
| Time symmetry filter | Off | Rejects patterns whose consecutive legs differ too much in bar count (outside 0.382 to 2.618). |
Patterns
| Setting | Default | What it does |
|---|---|---|
| Gartley, Bat, Alternate Bat, Butterfly, Crab, Deep Crab, Shark, Cypher, 5-0, AB=CD | All on | One switch per pattern. |
Display
| Setting | Default | What it does |
|---|---|---|
| Bullish color / Bearish color | Green / Red | Colour of the outline, fill, labels and zone for each direction. |
| Line width | 1.5 | Width of the pattern outline. |
| Fill patterns | On | Shades the pattern body with a translucent fill. |
| Show point labels | On | The X, A, B, C and D letters. |
| Show ratios | Off | The measured ratio of each leg on completed patterns. |
| Show pattern name | On | The pattern name next to D. |
| Show emerging patterns | On | Projects and draws the pattern whose D point is still forming. |
| Show PRZ | On | The potential reversal zone rectangle of the emerging pattern. |
| PRZ extension (bars) | 30 | How far past the last bar the PRZ rectangle extends. |
| Fibonacci time zones | On | Colours the PRZ by Fibonacci time measured from C. |
| Font size / Font family | 11 / chart default | Text used for letters, ratios and names. |
Alerts
| Setting | Default | What it does |
|---|---|---|
| Alert on completed | On | Alert when the D point of a pattern confirms. The message names the direction, the pattern and the price. |
| Alert on emerging | Off | Alert when price closes inside the PRZ of a pattern that is still forming. Once per formation. |
| Sound | Default sound | The WAV file played with the alert. |
Markets and data
Harmonic Patterns works from the high, low and close of each bar. It does not use volume, tick data or order flow. That makes it usable on futures, stocks, forex and crypto, and on time, tick, volume, range and Renko bars alike. Any connected feed that delivers bars will do, for example Rithmic, dxFeed, Databento, IQFeed or Interactive Brokers.
Alerts are raised on live data only, so loading a chart does not replay alerts for old patterns. For automation the indicator publishes four values per bar: In PRZ (1 when the close is inside a bullish zone, -1 for a bearish zone), PRZ High, PRZ Low and PRZ Time, the Fibonacci time ratio measured from C.
Frequently asked questions
Which patterns does it detect?
Nine five-point patterns (Gartley, Bat, Alternate Bat, Butterfly, Crab, Deep Crab, Shark, Cypher and 5-0) and the four-point AB=CD. Each has its own switch.
What is the difference between an emerging and a completed pattern?
An emerging pattern has X, A, B and C in place and a projected D. It is a forecast, drawn with a dashed last leg and a PRZ. A completed pattern has a confirmed pivot at D that satisfies all ratios, and is drawn with solid lines.
Can a completed pattern change or disappear?
Yes, in a few defined cases. A pivot is confirmed Pivot strength bars after the swing, so D is marked with that delay. If the same swing later extends to a more extreme pivot, D moves with it, and the pattern is withdrawn if the ratios no longer fit. A pattern is also removed when price closes beyond its far anchor or when it exceeds the maximum age.
I see very few patterns. What should I change?
Lower Pivot strength to pick up smaller swings, raise Ratio tolerance a little, or lower Minimum leg (ticks). Check that Direction is set to Both and that the patterns you expect are enabled.
What do the colours inside the PRZ mean?
They show how much time has passed since C compared with the length of the first leg. Green starts at a ratio of 1. The colour moves through yellow, orange and red, and turns magenta from a ratio of 2. Switch Fibonacci time zones off for a plain rectangle.
Is Harmonic Patterns a separate purchase?
No. It is included in the Pro, Ultimate and Perpetual plans. See pricing or the full list of premium indicators.
Find the next XABCD without a ruler
Harmonic Patterns ships with SabrTrader on Pro, Ultimate and Perpetual. No add-on fee and no separate licence.
Download SabrTrader free Compare plans All premium indicators