Everything before this page works on rows, columns, and boxes directly. XY-Wing is the first technique on this site that reasons through a short chain of cells instead — three cells, each with exactly two candidates, linked by which digits they share.

The three cells

Find a “pivot” cell with two candidates, say X and Y. Now find two cells that are each peers of the pivot (same row, column, or box) and also have exactly two candidates: one sharing X with the pivot and pairing it with some third digit Z, the other sharing Y with the pivot and also pairing it with that same Z.

Follow the logic through: whatever the pivot turns out to be, X or Y, one of the two wing cells is forced to be Z. If the pivot is X, the Y-wing is free to be Z. If the pivot is Y, the X-wing is free to be Z. Either way, Z ends up somewhere — which means any cell that’s a peer of both wings (but isn’t the pivot) can have Z eliminated, since one of the wings is guaranteed to take it.

Worked example

89
38
5
47
47
6
29
1
23
7
1
4
2
3
59
8
59
6
6
39
2
1
8
59
7
4
35
3
2
6
78
57
1
4
58
9
1
7
89
489
45
3
6
2
58
5
4
89
689
26
28
3
7
1
28
6
1
58
9
7
25
3
4
289
58
7
3
1
4
259
6
28
4
589
3
568
26
28
1
89
7

r1c1 (8/9) with r7c1 (8/2) and r1c7 (9/2) form an XY-Wing, clearing 2 from cells that see both wings.

Notice the eliminated cell doesn’t touch the pivot at all — it only needs to see both wing cells. That’s what makes this feel different from everything else on this site: the deduction runs through a chain, not a single row, column, or box.

How to find one quickly

Start from any bi-value cell (exactly two candidates) and check its peers for other bi-value cells. You’re looking for two peers that each share exactly one digit with your starting cell, and share a different, common third digit with each other. When you find that shape, check for a cell seeing both of the outer two — that’s where the elimination lands.

XY-Wing is usually tried after X-Wing and swordfish come up empty — it’s a different kind of pattern, not a bigger version of either. Uniqueness basics is the other tool worth knowing at this level, since it reasons from a completely different property of a valid sudoku.

Puzzles at Evil are the first level that may need this.