How to play Mastermind

Mastermind is the classic code-breaking duel between you and a hidden pattern. The game secretly picks a sequence of four coloured pegs, drawn from six possible colours, and you have ten guesses to work out exactly which colours go in exactly which order. It's a pure logic game — no luck once the code is set, just clever deduction from the clues each guess returns.

Goal

Reveal the hidden four-peg code before you run out of rows. Crack it and you win; use all ten guesses without matching it and the code is shown to you. Colours can repeat within the secret, so a code might be two reds and two blues, or even four of one colour — keep that possibility in mind as you reason.

Making a guess

Build each guess from the six-colour palette. Tap a colour and then tap a slot to drop it in, or tap a slot directly to cycle it through the colours until you reach the one you want. Once all four slots are filled, press the ✓ button to submit the row and receive your feedback.

Reading the feedback

Beside each submitted guess sits a small cluster of marker pegs. They tell you how close you were — but never which slots:

  • ● black peg — one of your pegs is the right colour and in the right position.
  • ○ white peg — one of your pegs is the right colour but sitting in the wrong position.
  • blank — that peg's colour isn't needed there at all.

Crucially, the markers are unordered: a black peg doesn't say where the correct match is, only that one exists. Untangling positions from these counts across several rows is the whole heart of the puzzle.

Strategy

Open with a guess that spreads several different colours out so you quickly learn which ones belong in the code at all. Each new row should test a specific idea, not a wild change — alter one thing and watch how the black-and-white count shifts. Track which colours have been ruled out, and use four blacks as your target as the answer narrows.

How to play Mastermind

Pick colours, submit, read the feedback. ● = right colour right place. ○ = right colour wrong place.

Settings

Theme

Appearance