Solving guide

How to solve Sudoku

Every Sudoku technique you need, in the order you'll need it, from the first easy singles to the X-Wing. Each one has a worked example you can follow on paper.

The rules

Fill the 9×9 grid so that every row, every column and every 3×3 box contains each of the digits 1 to 9 exactly once. The digits printed in the grid at the start are your clues. A well-made Sudoku has exactly one solution and never needs guesswork. Every puzzle on Puzzlebury is checked for both.

1. Naked singles: one digit left for a cell

Pick an empty cell and look along its row, down its column and around its box. If eight different digits already appear somewhere in those three places, the ninth is the only one left.

123456789
The centre cell sees 1, 2 and 3 in its row, 4, 5 and 6 in its column, and 7 and 8 in its box. Only 9 is left.

2. Hidden singles: one place left for a digit

Turn the question round: choose a box and a digit it still needs, then ask where that digit could go. Every cell that can see the same digit in its row or column is ruled out. If only one cell remains, the digit goes there, even if that cell has other candidates.

55835
The top-left box needs a 5. The 5s in the first and second rows rule out both of those rows, and two cells in the third row are already filled. Only one square is left.

Tip: scan digit by digit. Take the 1s, check every box that still needs a 1, then the 2s, and so on. One sweep often finds several hidden singles. Easy puzzles can be finished using singles alone.

3. Pencil marks and locked candidates

When singles run out, write small candidate digits in the corners of the empty cells. Then look for a digit that is locked into one row or column inside a box.

912356744444444
In the top-left box, a 4 can only go in the top row. Whichever of those two squares it takes, it is the top row's 4, so no other square in that row can be a 4.

It works the other way round too. If, in a row, every possible place for a digit sits inside one box, that digit can be crossed out of the rest of the box. Our medium puzzles often turn on this one idea.

4. Naked pairs (and triples)

If two cells in the same row, column or box have exactly the same two candidates, those two digits must go in those two cells, in some order. Cross them out everywhere else in that unit. Three cells sharing three candidates (a naked triple) work in the same way.

9163737235478358247
Two cells can only be 3 or 7, so the other cells in the row can't be either. Removing them leaves just two candidates in each remaining cell.

The mirror image is a hidden pair: two digits that can only go in the same two cells of a unit. Those cells must hold those digits, so you can erase every other candidate from them. Hard puzzles need pairs and triples.

5. X-Wing

Look at a single digit across the whole grid. If in two rows that digit can only go in the same two columns, it must occupy one corner of that rectangle in each row. Either way it fills both columns, so you can remove it from every other cell in those two columns. The same works with rows and columns swapped. A Swordfish extends the idea to three rows and three columns.

666666666
Rows 2 and 6 can only place their 6 in columns 3 and 8. Those two 6s take both columns, so the other 6 candidates in those columns (crossed out) disappear.

An XY-Wing is the other pattern our expert puzzles use. A cell with candidates A and B sees two cells with A/C and B/C. Whatever the first cell turns out to be, one of the other two must be C, so any cell that sees both of them can't be C.

A good routine

  1. Sweep for singles, digit by digit, until nothing new appears.
  2. Pencil in candidates, then look for locked candidates.
  3. Look for pairs and triples in each row, column and box.
  4. Only then go hunting for X-Wings and XY-Wings.

After every new digit or elimination, go back to step 1: one step usually opens up several more.