Minesweeper Logic Solver & Game
Enter numbered clues from a Minesweeper puzzle, then find guaranteed safe squares and mines without guessing. Or play a fresh Minesweeper board with visual clues and logical hints.
Enter a Minesweeper puzzle
Choose a brush below, then tap squares to enter numbers, known mines or known safe cells. Numbers count mines in the eight surrounding squares.
Click or tap cells with the selected brush. Right-click to mark or unmark a known mine. Keyboard: 0β8, F (mine), S (safe), Delete (unknown).
Paste, copy or print a puzzle
One row per line, values separated by spaces. Use . for unknown, 0β8 for numbered squares, F for a known mine and S for known safe. Importing replaces the board.
Logical deductions
The solver considers combinations that fit every numbered clue. Green and red outlines mark cells that are the same in every valid combination.
Ready to analyze
Load an example or enter your clues, then select Analyze Logic.
No global mine total is assumed in the editor. Squares far from all number clues may stay undecidable. If a region is too complex to enumerate, it is reported as unresolved rather than guessed.
Play Random Minesweeper
Reveal safe squares, flag suspected mines, and use the numbers to deduce where mines must be. Your first reveal is always safe.
On desktop, right-click any covered square to flag it. On mobile, switch to Tap to Flag. Mines appear if the game ends.
*Mines left is the total mine count minus flags placed. A flag is a guess, not confirmation of a mine.
Playing tips
Use deduction, not luck
A 1 means exactly one of its eight neighbors contains a mine. If all but one surrounding square is already known to be safe, the remaining one must be a mine.
A 0 means every adjacent square is safe.
Reveal some numbered cells, then select Find a Logical Hint. The helper won't inspect the hidden mine locations or assume your flags are correct.
Some random Minesweeper games require a guess. The hint system highlights only mathematically certain cells; it never pretends an uncertain square is safe.
How Minesweeper logic works
- Each revealed number tells you how many mines are in its eight surrounding cells, including diagonals.
- If a clue needs zero more mines, all of its remaining unknown neighbors are safe. If it needs as many mines as unknown neighbors, every one is a mine.
- Harder puzzles can be solved by comparing overlapping clue constraints, or by checking all legal layouts for a group of unknown squares.
- In the editor, F means a confirmed mine and S means a confirmed safe cell. In the game, your flags are not trusted as fact by the hint engine.