Online sudoku: 5 levels, live generator, persistent stats
Pick a level, start solving. Guaranteed unique solution: the generator removes cells only if the puzzle stays solvable in exactly one way. Timer, on-demand hints, pencil-mark mode, undo/redo, per-difficulty statistics saved in your browser.
| 5 | 9 | 4 | 8 | |||||
| 6 | 2 | 3 | ||||||
| 3 | 2 | 5 | 7 | 1 | ||||
| 5 | ||||||||
| 1 | 9 | 3 | 4 | 2 | ||||
| 2 | 3 | 4 | 1 | |||||
| 9 | 8 | |||||||
| 2 | 6 | 9 | ||||||
| 9 | 4 | 8 | 6 | 5 | 1 |
How sudoku works
-
1
Each row contains 1-9 once
The 9-cell horizontal row must contain each digit from 1 to 9, no repeats.
-
2
Each column contains 1-9 once
Same rule for the vertical 9-cell columns.
-
3
Each 3x3 block contains 1-9 once
The nine 3x3 sub-grids (delimited by thick borders) follow the same rule: each contains 1 through 9, no repeats.
-
4
Start with the certainties
Look for cells where only one digit is possible given row, column and box constraints. These 'naked singles' are the first step of every solver.
-
5
Use pencil marks for ambiguous cells
Press P (or the Pencil button) and type to add small candidate digits to the cell. When only one candidate survives the constraints, commit the digit.
Why this sudoku
Generator with unique solution. Every served puzzle has exactly one correct solution: the algorithm mathematically verifies this property at every cell removal, discarding attempts that would make the puzzle ambiguous. No multi-solution puzzles that frustrate players for no good reason.
Full game experience. Timer to measure yourself, on-demand hints when you're stuck (with time penalty, like in competitive sudoku), pencil-mark mode for multi-candidate cells, unlimited undo/redo, per-difficulty statistics saved in your browser. Works offline once loaded.
Five realistic levels. From Beginner (47 clues, great for learning) to Expert (25 clues, near the theoretical uniqueness limit of 17). Levels are calibrated against standard sudoku literature scales (Sudoku Explainer, NYT difficulty rating). Honest: we don't promise impossible difficulties the generator can't keep unique.
How the generator works
Two phases. Phase 1 (full board): backtracking with shuffled 1-9 digits produces a complete valid 9x9 board in under a millisecond. Phase 2 (puzzle): shuffle the 81 cells, then for each cell try the removal and call a solver with Minimum Remaining Values (MRV) heuristic. If the solver finds more than one solution, restore the cell. Result: every puzzle has a mathematically guaranteed unique solution.
The Expert target (56 holes out of 81 cells) lands at roughly 25 clues remaining, near the practical limit of greedy removal. The theoretical minimum for uniqueness is 17 clues, but reaching it requires exhaustive search with symmetries, out of scope for a real-time generator.
Frequently asked questions
What happens if I close the page mid-puzzle?
How does pencil mode work?
Why does the hint have a time penalty?
What does the streak mean?
Are statistics tracked per level?
Are puzzles different every time?
Can I print them?
Does it work offline?
How do I navigate the grid with keyboard?
Can I reset the statistics?
Interested in algorithms and backend performance?
The MRV solver on this sudoku is a didactic application of constraint propagation. In real consulting work I tackle similar problems: SQL queries with cardinality estimation, cache invalidation, scheduling with multiple constraints. If you have a concrete algorithmic problem in your PHP, Laravel or Symfony backend and want a senior opinion, let's talk.
Let's talk backend performance