Peg Solitaire
Jump pegs to leave just one. Where the last peg can end is decided by the opening — a mod-3 invariant rules out most squares.
Where you can finish was decided before you started
Label every hole twice — once by row plus twice the column, modulo three, and once by row minus twice the column. Every legal jump changes both counts in the same fixed way, so the pair is an invariant of the whole game. That means the square a lone surviving peg can occupy is fixed by the opening position, before you make a single move.
This is why "one peg left, but not in the middle" happens so often and feels so arbitrary. It is not arbitrary at all — it was determined by where the empty hole started. From the standard English board with the centre empty, only a handful of the 33 squares are reachable as a final resting place, and the centre is one of them. Turn the hint on to see which ones the arithmetic allows.
How to use
- Tap a peg, then tap the hole two squares away to jump.
- The peg you jumped over is removed.
- Finish with a single peg — ideally in the centre.
- Turn hints on to see which squares can hold the final peg.
Frequently asked questions
How do you play peg solitaire?
Jump one peg over an adjacent peg into an empty hole directly beyond it, in a straight line horizontally or vertically. The peg you jumped over is removed. You keep jumping until no legal move remains, and the aim is to be left with exactly one peg.
Can you always finish with one peg?
On the English 33-hole board starting with the centre empty, yes — and famously the final peg can be made to land in the centre. On the European 37-hole board with the centre empty it is impossible to finish with a single peg at all, which is a striking difference for a board that looks so similar.
Why does my last peg always end up in the wrong place?
Because it was decided before you started. There is an invariant: label each hole by row plus twice the column modulo three, and again by row minus twice the column. Every legal jump changes both counts in the same fixed way, so the square a lone peg can occupy is fixed by the opening position.
What is the mod-3 invariant?
A pair of counts that no legal move can alter. Because a jump always removes two pegs and adds one in a fixed geometric pattern, the number of pegs on each of three diagonal classes changes predictably. Working backwards from a single peg tells you which squares are consistent with your start, and it is usually only a handful.
How many moves does a full solution take?
Exactly 31 on the English board, and that is forced rather than a matter of efficiency. You start with 32 pegs and finish with one, and every jump removes exactly one peg, so any complete solution takes precisely 31 jumps. What varies is which 31.
What is the fewest moves possible?
Eighteen, if you count a chain of jumps by the same peg as a single move — which is the usual convention for record-setting. The 31 individual jumps do not change, but grouping consecutive jumps by one peg into a single sweeping move compresses the solution considerably.
Why is the European board harder?
Because its shape changes the invariant. The 37-hole board with the centre empty cannot be reduced to a single peg at all — the arithmetic simply forbids it — and the best possible finish is two pegs. It is a good demonstration that the invariant is a real constraint rather than a rule of thumb.
Is there a good general strategy?
Avoid stranding pegs. Isolated pegs with no neighbours can never be removed and can never move, so every one you create is a peg you will finish with. Working in from the edges and keeping the remaining pegs connected is the usual advice, along with thinking in packages of jumps rather than single moves.
What are the different board shapes?
The English cross of 33 holes and the European of 37 are the common ones, but triangular boards of 15 holes, diamonds, and various larger crosses all exist. Each has its own invariant and its own set of achievable finishes, which is why a strategy learned on one does not transfer cleanly to another.
How old is the game?
The earliest clear evidence is a 1687 engraving of a French noblewoman with a board, so it is at least that old, and it was well established at the French court by then. The mathematical analysis came much later — the invariant argument is usually attributed to work in the twentieth century.
Is it the same as Brainvita?
Yes, that is the common name for the same game in India, usually played on the English 33-hole board with marbles rather than pegs. Solo Noble is another name for it. The rules and the mathematics are identical whatever it is called.
Does the game save my progress?
No. Everything runs in your browser and nothing is stored or uploaded, so closing the tab loses the current board. Undo works within a session as far back as your first move.
🔒 This tool runs entirely in your browser. Nothing you enter is uploaded, logged, or stored.