Among the advanced Sudoku techniques, XY-Wing is the one that most often gets the reaction “how did you see that?” It uses just three cells and produces an elimination that seems to come from nowhere — a cell losing a candidate because of a pattern spread across a different part of the grid. Once you understand the logic, it feels inevitable. Until you do, it looks like magic. And it isn’t just theory: our toughest printable grid can’t be finished without one.

The Setup: Pivot and Two Wings

XY-Wing needs three bivalue cells — cells with exactly two candidates each — called the pivot, wing 1 and wing 2. The pivot holds X and Y. Wing 1 holds X and Z. Wing 2 holds Y and Z. The pivot must see both wings (share a row, column or box with each). The wings don’t need to see each other.

Pivot: {X, Y} — sees both wings
Wing 1: {X, Z} — sees the pivot
Wing 2: {Y, Z} — sees the pivot

Z is the digit the two wings share.
X is shared by the pivot and wing 1.
Y is shared by the pivot and wing 2.

The Logic: Why Z Gets Eliminated

The pivot must be either X or Y. Follow both cases:

If the pivot is X: wing 1 sees the pivot, so it can’t be X. It only has {X, Z}, so wing 1 must be Z.

If the pivot is Y: wing 2 sees the pivot, so it can’t be Y. It only has {Y, Z}, so wing 2 must be Z.

Either way, one of the two wings is Z. So any cell that sees both wings can’t be Z — whichever wing turns out to hold it will rule it out. Remove Z from every such cell.

A Real XY-Wing in Our Hard Sudoku #3

We ran all eight of our Sudoku through a step-by-step solver that only uses human techniques. Seven of them never need anything fancier than pairs and triples. Hard Sudoku #3 is different. Singles fill 53 of the 81 squares, a naked triple tidies up some candidates, and then the grid stops. Even X-Wing, Swordfish and Simple Colouring can’t move it on. It needs an XY-Wing.

Hint, not a spoiler: With full pencil marks in Hard Sudoku #3, look at the top-left cell of the grid. It can only be 2 or 4: that’s your pivot. One wing is in the same box, the other is in the same column, and the digit they share is 5. Of the cells that see both wings, one still has 5 pencilled in — and that 5 can come out.

That single elimination is enough to restart the solve, which then needs an X-Wing and, later on, a second XY-Wing centred in row 4. If you can find both, you’ve solved the hardest grid in our library without a single guess.

Advertisement

Finding XY-Wing Patterns

With full pencil marks, list the cells with exactly two candidates. Each one is a possible pivot. For a pivot holding {X, Y}, look among the cells it sees for one holding X plus some other digit — call that digit Z. Then look for a second cell the pivot sees that holds exactly {Y, Z}. If you find it, you have an XY-Wing.

Now find every cell that sees both wings and check whether it still lists Z. If it does, erase it. Often you get just one elimination — but in a hard puzzle, one is frequently all it takes to set off a run of simpler deductions.

Tip: In Hard Sudoku #3, the two wings of the first XY-Wing sit in different boxes, rows and columns, so only a handful of cells see both — and the one that loses its 5 isn’t even in the pivot’s box. That’s why the elimination feels like it comes from nowhere.

XY-Wing vs. XYZ-Wing

Once XY-Wing feels natural, XYZ-Wing is the next step. Its pivot holds three candidates {X, Y, Z} instead of two. The logic is similar, but because the pivot itself might be Z, only cells that see the pivot and both wings can lose Z — a tighter condition. None of our current grids needs an XYZ-Wing, so master XY-Wing on Hard #3 first; the extension follows from the same reasoning.