
How to Play Mastermind: Rules, Setup, and Winning Strategies
Share
When I was a kid, Mastermind was one of the coolest games in our house. I felt like a secret agent breaking coded messages — every guess was a clue, every peg a step closer to cracking the code. What I didn’t know at the time was that Mastermind was actually based on a much older paper-and-pencil game called Bulls and Cows.
If you’ve played Bulls and Cows, you’ll instantly recognize the connection:
- Black pegs = Bulls (right color in the right position)
- White pegs = Cows (right color, wrong position)
Mastermind takes that same logical deduction challenge and gives it a colorful, tactile twist.
Objective
Break your opponent’s secret code of colored pegs in as few turns as possible.
Number of Players
2 players — one is the code-maker, the other the code-breaker.
Age
Ages 8+ — younger kids can play simplified versions with fewer colors or positions.
Game Length
About 10–20 minutes per round, depending on skill level.
Skills Learned
- Logical Deduction – Narrowing possibilities using feedback clues.
- Pattern Recognition – Spotting overlaps between guesses.
- Strategic Guessing – Choosing guesses that reveal the most information.
- Memory – Tracking and applying clues from earlier turns.
Why We Like It for Families and Kids
For me, Mastermind was the perfect mix of fun and brainpower. It felt like solving a spy puzzle, and I loved the “aha” moments when the feedback suddenly made the code click in my head.
Now I get to play it with my kids — sometimes using the classic peg board, and sometimes introducing them to Bulls and Cows as the free, paper-and-pencil version. Watching them go through the same process I did as a kid — learning to make smarter guesses, narrowing down the options, and finally cracking the code — is incredibly satisfying.
What You Need
- Mastermind game board and pegs (or play Bulls and Cows for a free paper version)
Setup
- Place the board between both players.
- The code-maker selects a secret sequence of 4 colored pegs and hides it behind the shield. The sequence can use any combination of the available colors.
- Decide if colors can be repeated — the classic rules allow repeats.
How to Play Mastermind — Step by Step
1: Grab a friend and a Mastermind board
This is a 2-player game. One of you will be the code-maker, the other the code-breaker.
2: Decide who will be the code-maker first
There’s no official method, so you can choose however you like. Flip a coin, roll a die, or use our Who Plays First guide and app to make it fun.
3: Code-maker sets the secret code
Select 4 colored pegs and arrange them in any order behind the shield so the code-breaker cannot see them. Decide in advance if colors can be repeated (classic rules allow repeats).
4: Code-breaker makes the first guess
Insert 4 colored pegs into the first row of guess holes.
5: Code-maker gives feedback
After each guess, place feedback pegs in the smaller holes beside that row:
- Black peg – Correct color in the correct position.
- White peg – Correct color in the wrong position.
- No peg – Color not in the code.
6: Record and analyze feedback
The code-breaker uses the feedback to refine their next guess, keeping track of what’s been confirmed or eliminated.
7: Continue guessing
The code-breaker continues making guesses, one per turn, moving down the rows on the board.
8: Winning the game
The code-breaker wins by matching all 4 pegs in the correct colors and positions (4 black pegs in feedback). The code-maker wins if the code-breaker runs out of rows before cracking the code.
9: Switch roles and play again
Alternate who sets the code each round.
Mastermind Rules (Summary)
- Colors can be repeated unless agreed otherwise.
- Accurate feedback must be given after every guess.
- Black pegs indicate correct color & position.
- White pegs indicate correct color but wrong position.
- Code-breaker wins by guessing the code before running out of rows; code-maker wins otherwise.
Variations to Try
- Change the Code Length – Use 3 or 5 pegs for easier or harder games (printable version).
- Limit the Colors – Fewer colors = easier deduction.
- No Repeats – Makes the puzzle more about placement than elimination.
- Multiple Rounds with Scoring – Earn points based on number of guesses used.
- Play Bulls and Cows – The original paper-and-pencil version of Mastermind, perfect for travel or quick play.
- How to Play Bulls and Cows Like Mastermind – To mimic classic Mastermind, set your Bulls and Cows game to: 4 positions, symbols from 1–6 (or A–F), allow or disallow repeats per your preference, and limit to 10 guesses. Feedback is the same: Bulls = right symbol in the right place, Cows = right symbol in the wrong place.
-
Different Mastermind Versions –
- Deluxe Mastermind – Often has 12 rows for more guesses and a sleeker board.
- Travel Mastermind – Compact size, usually 8–10 rows.
- Super Mastermind – Adds an extra peg position (5 instead of 4) and sometimes more colors, making the game significantly harder.
Tips for Winning
- Start with a balanced guess – Use all different colors to get the most info.
- Use elimination – If a color gets no feedback, drop it from future guesses.
- Track confirmed positions – Lock these in and experiment with the others.
- Think in possibilities – If you know a color is right but misplaced, try it in different positions.
Mastermind FAQs
Rules FAQs
Can colors be repeated?
Yes, in the classic rules — but you can agree otherwise.
Do feedback pegs show which positions are correct?
No, feedback pegs are not positional — they only show totals.
How many guesses do you get?
Classic Mastermind boards give you 10 rows; Deluxe editions may have 12.
Strategy FAQs
What’s the best first guess?
Many experts recommend starting with two pairs of the same color (e.g., AABB) to quickly test multiple possibilities.
Is Mastermind luck or skill?
Mostly skill — luck plays a bigger role only on the first guess.
History FAQs
When was Mastermind invented?
Mastermind was created in 1970 by Mordecai Meirowitz, inspired by the older game Bulls and Cows.
What’s the difference between Mastermind and Bulls and Cows?
Bulls and Cows uses numbers or letters and paper; Mastermind uses colored pegs and a plastic board. The logic is identical.
If you enjoyed Mastermind, try Bulls and Cows for a free, portable version you can play anywhere — plus grab our printable sheet to make it even easier.