X-Wing Strategy in Sudoku: Visual Guide

The X-Wing is an advanced sudoku technique that eliminates candidates by finding a specific rectangular pattern. It works like this: when a candidate number appears in exactly two cells in each of two different rows, and those cells line up in the same two columns, the candidate can be eliminated from all other cells in those two columns. The X-Wing is named for the X shape formed when you connect the four cells diagonally. It is typically the first advanced technique solvers learn after mastering naked pairs and pointing pairs, and it is essential for solving hard-level puzzles.

Understanding the X-Wing Pattern

An X-Wing requires four cells arranged in a rectangle. These four cells satisfy very specific conditions:

  1. Pick a candidate number (say, 5).
  2. Find two rows where 5 appears as a candidate in exactly two cells each.
  3. The two cells in each row must be in the same two columns.

When these conditions are met, the four cells form the corners of a rectangle. The candidate must go in two of these four cells — specifically, in one of the two diagonal pairs. Think of it as an X connecting the four corners, which is where the name comes from.

Because the candidate must occupy two of these four cells (one per row), and both possible arrangements place the candidate in both target columns, you can eliminate the candidate from every other cell in those two columns. The candidate is "locked" into those four cells as far as the columns are concerned.

Visual Example: Row-Based X-Wing

Let us walk through a concrete example. Imagine you are looking for the number 3 across the grid. You find:

  • In Row 2, the number 3 can only go in Column 4 or Column 7.
  • In Row 8, the number 3 can only go in Column 4 or Column 7.

The four cells (R2C4, R2C7, R8C4, R8C7) form a rectangle. Now consider the two possible arrangements:

  • Option A: 3 goes in R2C4 and R8C7.
  • Option B: 3 goes in R2C7 and R8C4.

In both options, Column 4 gets a 3 and Column 7 gets a 3. There is no arrangement where a column does not get a 3. Therefore, no other cell in Column 4 or Column 7 can contain a 3. You can safely remove 3 as a candidate from every other cell in these two columns.

Here is a simplified grid showing the pattern (focusing only on Column 4 and Column 7):

         Col 4    Col 7
Row 1:   3?       3?     ← eliminate 3 from both
Row 2:   [3]      [3]    ← X-Wing corner
Row 3:   3?       3?     ← eliminate 3 from both
Row 4:   3?       .      ← eliminate 3 from C4
Row 5:   .        3?     ← eliminate 3 from C7
Row 6:   3?       .      ← eliminate 3 from C4
Row 7:   .        .
Row 8:   [3]      [3]    ← X-Wing corner
Row 9:   3?       3?     ← eliminate 3 from both

Every cell marked "3?" has 3 eliminated. Only the four corner cells (marked [3]) retain the candidate.

Ready to compete?

Sudoku Royale is the world's only battle royale sudoku game. Compete against up to 10 players in real time on the same board with elimination rounds.

Download Sudoku Royale — Free on iOS

Column-Based X-Wing

The X-Wing works symmetrically with columns as the base. If a candidate appears in exactly two cells in each of two columns, and those cells are in the same two rows, you can eliminate the candidate from all other cells in those two rows.

The logic is identical — just rotated 90 degrees. Instead of rows defining the pattern and columns receiving eliminations, columns define the pattern and rows receive eliminations.

In practice, you should check for both orientations. Some solvers naturally scan rows first; others prefer columns. Checking both ensures you do not miss any X-Wing patterns.

How to Search for X-Wings Systematically

Finding X-Wings requires pencil marks and systematic scanning. Here is a step-by-step search process:

Step 1: Full Pencil Marks

You need complete (or near-complete) pencil marks across the grid. X-Wings depend on knowing exactly where each candidate appears, so incomplete pencil marks can cause you to miss patterns or find false ones.

Step 2: Count Candidates by Row

For each candidate number, go row by row and count how many cells contain that candidate. You are looking for rows where the candidate appears in exactly two cells. Make a mental note of which columns those cells are in.

Step 3: Look for Column Alignment

If two different rows both have the candidate in exactly two cells, and the column positions match, you have found an X-Wing. This is the key insight — the columns must align.

For example, if Row 3 has candidate 7 in columns 2 and 9, and Row 6 also has candidate 7 in columns 2 and 9, that is an X-Wing on 7 in rows 3 and 6, columns 2 and 9.

Step 4: Eliminate

Remove the candidate from all other cells in the two columns (for a row-based X-Wing) or the two rows (for a column-based X-Wing). Do not remove the candidate from the four corner cells themselves.

Step 5: Check for Cascading Effects

After eliminating candidates, re-check for hidden singles, naked pairs, and other patterns that may have been created. X-Wing eliminations frequently trigger cascading deductions.

Why X-Wings Are Hard to Spot

X-Wings are notoriously difficult for intermediate solvers to find, even when they know the technique. There are several reasons:

  • The pattern spans the entire grid. Unlike naked pairs (which live within a single group), X-Wings involve four cells that may be far apart. Your eyes need to connect distant parts of the grid.
  • You need accurate candidate counts. The X-Wing only works when each row has exactly two candidates for that number. Miscounting (or having incomplete pencil marks) breaks the pattern.
  • There are many possible combinations. For nine rows and nine digits, there are many potential row pairs to check. Systematic scanning is essential — random searching is inefficient.

The best advice for spotting X-Wings is to develop the habit of noting rows with exactly two candidates for a given number. When you notice two such rows with matching columns, the X-Wing becomes obvious.

X-Wing vs. Swordfish

The X-Wing is the simplest member of a family of techniques called "fish" patterns. The Swordfish extends the X-Wing concept from two rows/columns to three. Where an X-Wing uses two rows with two candidates each (forming a 2x2 pattern), a Swordfish uses three rows with candidates in up to three columns each.

If you are comfortable with X-Wings, the Swordfish is a natural next step. The logic is identical — just applied to a larger pattern. Beyond Swordfish, the Jellyfish extends to four rows/columns, but this is exceedingly rare in practical puzzles.

When to Look for X-Wings

X-Wings are not needed for easy or most medium puzzles. They are a hard-level technique. You should look for X-Wings when:

Do not waste time looking for X-Wings early in the solve. Apply simpler techniques first — they are faster and solve more cells. X-Wings are a tool for breaking through specific bottlenecks in hard puzzles.

Practice Tips

To build X-Wing recognition:

  1. Solve hard puzzles with complete pencil marks. X-Wings only become visible with thorough notation.
  2. Scan one number at a time. Pick a candidate number, note every row where it appears in exactly two cells, and check for column alignment.
  3. Use a solving guide or app hint to confirm. When you think you have found an X-Wing, verify the pattern before eliminating. One wrong elimination can ruin the entire puzzle.
  4. Work up to speed. Once you can reliably find X-Wings, practice finding them faster. In competitive play (like Sudoku Royale matches), the ability to spot an X-Wing quickly can mean the difference between winning and losing.

For a complete picture of where X-Wings fit in the technique hierarchy, see our difficulty levels guide.

Frequently Asked Questions

What is an X-Wing in sudoku?

An X-Wing is a pattern where a candidate number appears in exactly two cells in each of two rows, and those cells align in the same two columns. This allows you to eliminate that candidate from all other cells in those two columns. It also works symmetrically with columns as the base and rows receiving eliminations.

How do I find an X-Wing pattern?

Fill in complete pencil marks, then scan each candidate number row by row. Look for rows where the candidate appears in exactly two cells. When you find two such rows with matching column positions, you have an X-Wing. Eliminate the candidate from all other cells in those columns.

When should I look for X-Wings?

Look for X-Wings after exhausting simpler techniques — naked singles, hidden singles, naked pairs, and pointing pairs. X-Wings are a hard-level technique and are not needed for easy or most medium puzzles. They are most useful when you are stuck on a hard puzzle with no obvious deductions.

What is the difference between X-Wing and Swordfish?

An X-Wing involves two rows and two columns (a 2x2 pattern). A Swordfish extends this to three rows and three columns (a 3x3 pattern). The underlying logic is identical — both use aligned candidates to eliminate possibilities. Swordfish is rarer and harder to spot, but the technique is a natural extension of X-Wing.

Try Sudoku Royale

Download Free on the App Store
Sudoku Royale — the world's only battle royale sudokuDownload Free