Skip to content
SudokuPart 14 of 49
SudokuPuzzlesLogic Games

The X-Wing in Sudoku, Explained With Real Grids

Two rows where a digit fits in only two cells, both using the same two columns. The digit then leaves those columns everywhere else. Two worked grids that finish on singles after it.

By Bimal Khatri·13 min read·Sep 9, 2026·Updated Sep 10, 2026
The X-Wing in Sudoku, Explained With Real Grids

An X-Wing is a rectangle in one digit. Pick a digit. If it has exactly two possible cells in one row, exactly two in another row, and both rows use the same two columns, then that digit can be rubbed out of those two columns everywhere else.

It never places anything. It only removes candidates, which sounds weak until you watch what the removals do. On both grids below, one X-Wing is the only move above singles that the puzzle needs, and after it every remaining cell falls to a single.

You need pencil marks for one digit at a time, not for all nine. That is what makes the search cheap enough to run on a stuck grid.

Hunting one on a phone? Sudoku Master will paint every cell already holding the digit you tapped, and step 3 below is mostly reading that picture. The whole catalogue is free, and no ads while you solve.

The pattern, in one table

Part of itWhat has to be true
The digitOne digit, checked on its own. What else those cells could hold does not matter
The two rowsThe digit fits in exactly two cells of each. Not three, not one
The two columnsThose cells sit in the same two columns in both rows
The cornersFour cells at the corners of a rectangle
What you winThe digit leaves every other cell of those two columns
What you never learnWhich pair of corners actually holds it

Draw both ways the digit can land and you get the two diagonals of that rectangle, crossing in the middle. That is the name.

Everything on this page works the same with rows and columns swapped. Two columns with two spots each, in the same two rows, clears the digit out of those two rows. There is a worked one of those further down.

A hard grid, and the 8 that opens it

This puzzle has 26 givens.

3.7....9.
...4..2.7
.....8..5
.1..239..
..469..2.
.........
......31.
.5....7.8
86.3..4.2

Naked and hidden singles place five cells and then stop dead. Here is where they leave you.

3.7....9.
...4..2.7
.....8..5
.1..239..
..469..2.
.........
..2...319
.53...768
86.3..452

Fifty cells still empty, five moves in, and nothing to place. No naked pair helps. Row 6 is completely blank. This is the moment the X-Wing is for.

Map one digit

The 8 is already on the board three times: r3c6, r8c9 and r9c1. Six rows still need one. Write down where it can go in each of them, and nothing else.

RowWhere the 8 can still go
1r1c2, r1c7
2r2c2, r2c3, r2c8
3Placed at r3c6
4r4c3, r4c4, r4c8
5r5c2, r5c7
6Six different cells
7r7c4, r7c5
8Placed at r8c9
9Placed at r9c1

Three rows have exactly two spots: 1, 5 and 7. Now compare their columns. Row 1 uses columns 2 and 7. Row 5 uses columns 2 and 7. Row 7 uses columns 4 and 5, so it pairs with nothing and you can forget it.

Rows 1 and 5 are your X-Wing. The corners are r1c2, r1c7, r5c2 and r5c7, one in each of boxes 1, 3, 4 and 6.

Why the eliminations are safe

Two cases, and there are only two.

Say r1c2 holds the 8. Then row 1 is done, so r1c7 does not. Column 2 now has its 8, so r5c2 is out, which forces row 5 to put its 8 at r5c7. Columns 2 and 7 both have their 8 inside rows 1 and 5.

Say instead r1c7 holds it. Then r5c7 is out, so row 5 has to use r5c2. Columns 2 and 7 both have their 8 inside rows 1 and 5 again.

You cannot tell which of the two it is, and you never will from this pattern alone. You do not need to. Both branches park the 8s of column 2 and column 7 in the same two rows, so anything else in either column is finished.

Cash it in

Column 2 has 8 as a candidate in four cells: r1c2, r2c2, r5c2, r6c2. Two of them are corners. Column 7 has three: r1c7, r5c7, r6c7. Two are corners. So three eliminations.

CellBeforeAfter
r2c2{8,9}{9}
r6c2{2,3,7,8,9}{2,3,7,9}
r6c7{1,5,6,8}{1,5,6}

Look at the first row of that table. r2c2 held two candidates and now holds one, so it is a 9. That is the whole payoff, and it is typical: an X-Wing does not place a digit, it makes some other cell placeable.

Place the 9 and the grid comes apart. r3c4 is a hidden 9 in row 3, then r3c5 is a 7, then r9c5 drops to a naked 1, and it keeps going. Fifty cells, all of them singles, no further technique of any kind.

387562194
695431287
241978635
518723946
734695821
926184573
472856319
153249768
869317452

One rectangle, three candidates crossed out, a finished puzzle. That is the argument for learning it.

The same thing sideways: a column X-Wing

Here is a different puzzle, already worked down as far as singles, naked and hidden pairs and pointing pairs will take it.

627...9.5
..9...2.6
354962817
..6.7..2.
..523.468
.32..6...
2.3......
.98..3..2
.61.2..8.

Nothing basic moves. Take the 9 and map it by column this time.

ColumnWhere the 9 can still go
1r4c1, r5c1, r6c1
2Placed at r8c2
3Placed at r2c3
4Placed at r3c4
5r6c5, r7c5
6r4c6, r5c6, r7c6, r9c6
7Placed at r1c7
8r6c8, r7c8
9r4c9, r6c9, r7c9, r9c9

Columns 5 and 8 have two spots each, and both use rows 6 and 7. Same pattern, rotated. Whichever way it resolves, rows 6 and 7 each hold one of those two 9s, so no other cell in row 6 or row 7 can be a 9.

That kills the 9 in r6c1, r6c9, r7c6 and r7c9. And r6c9 was {1,9}, so it is a 1. From there this grid also finishes on singles alone.

Notice what the two examples have in common. In both, the useful elimination landed on a cell that already held two candidates. That is where to look first when you are checking whether a pattern is worth the trouble: not at how pretty the rectangle is, but at whether anything in those two lines is nearly decided.

How to hunt for one

Do not start here. Run the cheap techniques until they stop, because an X-Wing found on a grid that still has a hidden single in it is wasted effort, and because every placement you make changes the map you are about to draw.

  1. Get the grid to a genuine stall. Singles, naked and hidden pairs, pointing pairs and box-line reduction. The last of those is worth clearing first because it removes candidates that would otherwise hide the rectangle.
  2. Pick one digit. Start with a digit that already sits on the board five or six times, because the rows it can still occupy are few and short.
  3. Write out, for that digit only, which cells of each unplaced row could take it. Nine short lists. Ignore every other digit while you do it.
  4. Keep only the rows with exactly two. One spot is a hidden single you missed. Three or more is not this pattern.
  5. Compare their column numbers. Two rows using the same pair of columns is an X-Wing. Anything else is not.
  6. Cross the digit out of the other cells of those two columns.
  7. Repeat by column, then move to the next digit.

Steps 3 to 5 take about a minute per digit once you have done it a few times. Six digits is six minutes, which sounds slow until you compare it with staring at a stalled grid for twenty.

I built Sudoku Master, and two of its settings exist for exactly this kind of scan. Highlighting every copy of a digit shows you which rows and columns are already spoken for, which is the half of step 3 you would otherwise do by eye. Auto-removing notes when you place a value keeps the marks honest, and an X-Wing is only ever as good as the marks under it. The app does not walk you through techniques, and I am not going to pretend it does: its solver hands back a finished grid, so it settles an argument rather than teaching one.

Four things that look like an X-Wing and are not

Two rows with two spots each, in different columns. Rows 1 and 7 on the first grid both had exactly two homes for the 8. Row 1 used columns 2 and 7 and row 7 used columns 4 and 5, and that is the end of it. Two is not enough. The columns have to match.

A row with a third spot. The proof above leans on row 5 having nowhere else to go once column 2 is taken. Give row 5 a third cell and that step collapses, because the row can duck into the third cell and leave both columns free. One extra candidate anywhere in those two rows and you have nothing.

A pattern whose work is already done. That same stalled grid carries a second X-Wing, on the 3, in rows 2 and 3 across columns 5 and 8. It eliminates one candidate: the 3 in r6c8. But in box 3 the 3 only fits at r2c8 or r3c8, both in column 8, and that pointing pair clears the same cell in a tenth of the time. Finding an X-Wing is not the goal. Moving the grid is.

A rectangle built on stale marks. The map in step 3 is only as true as the candidates it is drawn from. Leave one dead mark standing and a row that has one home for the digit will look like it has two, which is exactly the shape you are hunting. The rectangle you then find is sound reasoning applied to a board that does not exist. Clean pencil marks are not optional above the singles.

One case that surprises people is legal: the corners can share boxes. Two rows in the same band, or two columns in the same stack, still give a valid X-Wing. Check first whether a box-line reduction already made the elimination, because when the corners bunch up it usually has.

Where it sits on the ladder

X-Wing is the first technique on the ladder that looks at four cells scattered across the grid instead of one row, one column or one box. Everything below it works inside a single unit. That is the real step up, and it is why the pattern feels different rather than merely harder.

TechniqueLines it usesWhat it needs
Hidden singleOneNo marks at all
Naked pairOneMarks in one unit
Pointing pairTwo, sharing a boxMarks in one box
X-WingTwo rows and two columnsMarks for one digit, grid-wide
SwordfishThree rows and three columnsThe same, one row longer

Swordfish is the same argument with three lines instead of two, and it is the reason this pattern is worth real attention: learn the X-Wing properly and Swordfish costs you an afternoon rather than a week. The XY-Wing sits nearby on the ladder and works nothing like it, on three cells and their shared candidates rather than on one digit.

Puzzles that need any of this are the top end. Most hard newspaper grids are singles and pairs all the way down, with one awkward stretch in the middle. When a grid genuinely stops, work the checklist before you start drawing rectangles.

Questions people ask

Why is it called an X-Wing?

The digit lands on one of the two diagonals of the rectangle. Draw both possibilities on the four corners and the lines cross in an X. The rest of the fish naming, Swordfish and Jellyfish for the three-line and four-line versions, followed later and has no logic to it beyond sounding like a series.

Does an X-Wing ever place a digit?

Not by itself, ever. It only removes candidates from other cells. What happens in practice is that one of those removals leaves a cell with one candidate, and that cell is a placement. On both grids above the very next move was a single.

Do the four corners have to be in four different boxes?

No. That is the common case and the easiest to see, but two rows inside one band work fine and so do two columns inside one stack. The logic never mentions boxes. When the corners do share a box, check whether box-line reduction gets the same elimination more cheaply.

What if one of the rows has three places for the digit?

Then there is no X-Wing and you have to move on. The argument only works because each row has nowhere else to put the digit. A third cell gives it somewhere else, both columns can then come up empty, and every elimination you were about to make is unsound.

Is an X-Wing the same as a naked pair?

No, though they rhyme. A naked pair is two cells in one unit holding the same two candidates, and it clears those two digits from the rest of that unit. An X-Wing is one digit in two cells of each of two units, and it clears that digit from two other units. Different shape, different payoff.

How do I know which digit to try first?

Count how many times each digit is already placed. A digit sitting on the board six times can only be missing from three rows, so the map takes seconds to draw and the lists are short. Digits that appear twice will give you nine long lists and almost never a pair of rows with exactly two spots.

Do I need to write out the full candidate grid?

No, and it is faster not to. The search runs on one digit at a time, so all you need is nine short lists of cells. Full pencil marks help afterwards, when you want to see which cell the eliminations have squeezed down to one.

Can one grid have more than one X-Wing?

Yes. The first grid on this page has two at the same moment, on the 8 and on the 3. Only one of them was worth anything, because the other made an elimination a pointing pair had already covered. Check what a pattern actually removes before you congratulate yourself for spotting it.

Keep reading

Get it: Sudoku Master, free on iPhone and Android. The link sends you to whichever store your phone uses.

More writing

Keep reading