If you've been solving Sudoku for a while and you keep hitting a wall on hard puzzles — the kind where all your Singles and Box-Line Reductions run out and you're staring at a grid that refuses to budge — the technique you're almost certainly missing is the X-Wing. It's the first genuine advanced technique most Sudoku solvers encounter, and learning it is the key that unlocks an entire category of puzzles that previously seemed to require guessing.
The Setup: What You Need
An X-Wing requires a specific pattern involving a single candidate digit across two rows (or two columns). The pattern has three conditions that must all be true simultaneously:
First, choose a candidate digit — let's use 7. Second, find two rows where 7 appears as a candidate in exactly two cells each. Third, those two cells in each row must be in the same two columns. That's the whole setup: two rows, two candidates per row, same two columns.
The Logic: Why Eliminations Are Valid
Here's the reasoning. In row 2, the 7 must go in either column 4 or column 8 — there are no other options. In row 7, the same is true: the 7 must go in column 4 or column 8.
Now consider the two columns. In column 4, the 7 must appear exactly once. It will either come from row 2 (if row 2's 7 lands in column 4) or from row 7 (if row 7's 7 lands in column 4). Either way, one of these two rows will place the 7 in column 4. The 7 in column 4 is therefore accounted for by the X-Wing pattern — it cannot also appear in any other cell in column 4. The same logic applies to column 8.
This means you can eliminate 7 as a candidate from every other cell in column 4 and every other cell in column 8, outside the four X-Wing cells. The elimination is logically guaranteed regardless of which diagonal of the X-Wing ends up being the actual solution.
Visualizing It
The name X-Wing comes from the shape the four cells make on the grid — a rectangle where the two diagonals form an X. The top-left and bottom-right cells form one possible solution (one diagonal of the X), and the top-right and bottom-left cells form the other. No matter which diagonal is correct, the two columns are fully accounted for within those four cells.
Some solvers find it helpful to physically mark the four X-Wing cells with a small circle or highlight when they spot the pattern, then sweep both columns for eliminations. The visual marking makes the rectangle obvious and prevents errors during the elimination sweep.
X-Wing on Columns Instead of Rows
Everything above works identically with columns and rows swapped. Find a digit that appears as a candidate in exactly two cells in each of two columns, where both pairs share the same two rows. Eliminate the digit from all other cells in those two rows. The logic is the mirror image of the row-based version, and both occur with roughly equal frequency in hard puzzles.
How to Hunt for X-Wings Efficiently
With full candidate notation in place, scan each digit from 1 to 9 and count how many times it appears as a candidate in each row. Any row where a digit appears exactly twice is a candidate for one half of an X-Wing. Note the column positions of those two candidates. Then scan other rows for the same digit appearing exactly twice in the same two columns. When you find a match, you have your X-Wing.
This scan sounds tedious but becomes fast with practice. Most hard Sudoku puzzles have one or two X-Wings that, once found and applied, trigger a cascade of simpler eliminations that carry the puzzle to completion. The pattern is the lock; finding it is finding the key.
What Comes After X-Wing
Once X-Wing clicks, the path to harder techniques opens up. Swordfish is the three-row version — the same logic extended to three rows and three columns. Jellyfish extends it to four. XY-Wing works on a three-cell chain of candidates rather than a rectangle. Each technique uses the same core idea: a constrained pattern that guarantees an elimination regardless of how it resolves. X-Wing is where that family of thinking begins, and mastering it changes how you see the entire grid.