What kind of puzzle is Masyu?
Masyu is a logic puzzle where you draw one closed loop through the centers of grid cells so that it passes every white and black pearl, each in its own prescribed way. It is a Japanese pencil puzzle, also called the pearl loop puzzle.
The loop runs only horizontally and vertically, never branches or crosses itself, and must close without gaps. Cells without a pearl may be visited or skipped. There are just two rules, but a handful of pearls interlock until only one path remains, and watching that path narrow down is the whole pleasure of the puzzle.
What are the white and black pearl rules?
In a white pearl cell the loop must go straight, and it must turn in at least one of the two cells right before or after it. In a black pearl cell the loop must turn, and in both directions it must then run straight through the neighbouring cell for at least one more step.
| Pearl | In that cell | In the neighbouring cells |
|---|---|---|
| White pearl | Straight (horizontal or vertical pass) | At least one of the two cells before and after turns. Both going straight is wrong |
| Black pearl | Turn (an L shape) | Both neighbours go straight. Turning again right next to it is wrong |
| Empty cell | May be visited or not | If visited, straight or turn, anything goes |
A black pearl on the border cannot leave the board, so its two inner directions are fixed, and a white pearl on the border can only run along that border. Starting from the edges is the usual first step.
Which openings can I use right away?
A few common layouts let you draw lines at a glance. Look for the shapes in this table first.
| Shape | Lines you can draw immediately |
|---|---|
| Black pearl on an edge | It cannot go outward, so draw two cells straight in each of the two inner directions. A black pearl in a corner is completely determined. |
| White pearl on an edge | It runs along the edge. Three or more white pearls in a row along an edge can never satisfy the rules, so such layouts never appear. |
| Three white pearls in a row | If the middle one were passed along the row, both neighbours would also run along the row, leaving the middle pearl straight on both sides. So all three are crossed perpendicular to the row. |
| Two black pearls side by side | Neither can head toward the other, because the cell next to a black pearl must be straight and the neighbour is a black pearl that turns. Each goes two cells the other way. |
| Black pearl one cell from an edge | Toward the edge there is no room for two straight cells, so that direction is blocked. Mark it with × and draw two cells the other way. |
| Dead end cell | A cell the line enters with only one way out has that exit fixed, and a cell with no way out is never visited. |
How are boards made, and is the answer really unique?
Yes. Every board is generated fresh and released only after a solver has confirmed that it has exactly one answer.
The generator first builds a random loop through every cell, then presses in pockets of empty cells, and places a pearl at every position along the loop where the rules allow one. Once that board is confirmed unique, pearls are removed one at a time, keeping only removals that leave a single answer. Easy keeps plenty of pearls, while Hard strips them down as far as possible so the chains of deduction grow longer. The daily puzzle takes its seed from the date, so everyone gets the same board that day.
What do Hint and Check tell me?
Hint draws one segment of line, and Check marks in red any rule your current lines already break. Both are counted in your record.
- Hint: if you have a wrong line or a wrong ×, it removes that first. Otherwise it draws one segment that can be deduced from what you have, preferring one next to your existing lines.
- Check: a white pearl that turns or runs straight on both sides, a black pearl that goes straight or turns again right next door, and any cell where three lines meet are circled in red. Loose ends get a yellow dotted ring, and a loop that closed before reaching every pearl is reported too.
- Undo: a line drawn in one drag is undone in one go.
Tips for solving Masyu faster
- Walk the border first. Corner and edge pearls have almost no choice, so that is where the first lines appear.
- Use × freely. Marking impossible edges makes it obvious when a cell is left with only one exit.
- Follow loose ends. Every open end must continue somewhere. If only one unmarked edge is left in that cell, draw it.
- Beware small loops. If the line would close before reaching every pearl, the closing edge is an ×.
- Settle white pearl turns early. When both sides of a white pearl are drifting toward straight, one of them must turn, so decide where before it is too late.
Controls
- Touch or mouse: drag from a cell to a neighbouring cell to draw a line; start the drag on an existing line to erase. Tap between two cells for a line, again for ×, and once more to clear.
- Keyboard: arrows move the cursor, Shift+arrow draws or erases a line, Ctrl+arrow places or removes ×. Z undo, H hint, C check, and Enter on the title screen starts a Normal board.
Best times and daily completions stay in this browser and are never sent to a server. Share result turns your time and difficulty into a picture card.