sudokly
Advanced technique

XY-Wing

An XY-wing is a three-cell pattern. The pivot cell has candidates {X, Y}. Two wing cells see the pivot, with one wing holding {X, Z} and the other holding {Y, Z}. Whatever digit the pivot takes, one of the wings must hold Z, so Z can be eliminated from any cell that sees both wings.

How it works

XY-wing is the first true chain technique. It tracks consequences across three cells linked by a shared digit Z.

The pivot cell must be bivalue with candidates X and Y. Each wing must also be bivalue. One wing must contain X and Z, and must see the pivot. The other wing must contain Y and Z, and also see the pivot. Wings do not need to see each other.

If the pivot takes X, the X-wing must take Z. If the pivot takes Y, the Y-wing must take Z. Either way Z is placed in one of the two wings. Any cell that sees both wings cannot be Z, no matter how the pivot resolves.

When to look for it

After X-wing fails. Scan for three-cell bivalue chains where two ends share a common digit (Z).

Tips for spotting the pattern

  • Find bivalue cells first; chains build from them.
  • The pivot must see both wings, but the wings do not need to see each other.
  • Z is the digit you eliminate, never X or Y.

Common mistakes

  • Wings with three candidates. XY-wing requires every cell to be exactly bivalue.
  • Eliminating X or Y. The eliminations always target Z.
  • Forgetting the visibility condition. The pivot must see both wings.
Practice on expert sudoku