🧮
🧮 Math & statistics

Monty Hall Problem Simulator (switch or stay? 3 or more doors)

Results update as you type.

Your numbers

Understanding the Monty Hall problem simulator — concept and principle

This simulator plays the Monty Hall game thousands of times with 3 or more doors and compares the win rates of switching and staying with the theoretical values. You choose how many doors there are and whether the host opens one goat door or all but one. Use it to see, rather than just be told, why switching wins.

Monty HallStick or switch?1your pick2goat shown3switch herestay wins1/3 = 33.33 %switch wins2/3 = 66.67 %one simulation of 10,000: switch 67.3 %, stay 32.8 %
Your first pick is right 1/3 of the time; the other 2/3 moves to the one closed door left.

How it is calculated

Staying wins only if the first pick was right: P(stay) = 1/n.

Switching, when the host opens all other doors but one: P(switch) = (n − 1)/n.

Switching, when the host opens just one goat door: P(switch) = (n − 1)/n × 1/(n − 2).

The principle

The host knows where the prize is and always opens a goat door, so his choice carries information. Your first pick is right only 1 time in 3. In the other 2 times out of 3, the prize is behind one of the other two doors and the host is forced to reveal the goat, leaving the prize behind the remaining door. So switching wins exactly when your first pick was wrong: 2/3 of the time.

Worked example

Default inputs: 3 doors, host opens one goat door, 10,000 games, run 1. The simulation is random, so your numbers will vary slightly; when this page was checked it showed:

  1. Theoretical: switch wins 66.67 %, stay wins 33.33 %.
  2. Simulated: switching won 6,725 games, 67.3 %; staying won 3,275 games, 32.8 %.
  3. Switching wins about 2× as often as staying.
How Win rate if you switch (simulated) changes with Run number (change it to simulate again)How Win rate if you switch changes with…6565.56666.56767.50.250.50.7511.251.52Example: 66.6%Run number (change it to simulate again)
Each point is the calculator re-run with only “Run number (change it to simulate again)” changed; the gold point is the default example. Change the inputs above and this chart follows your numbers.
Run number (change it to simulate again)Win rate if you switch (simulated)
0.2566.1%
0.567.1%
0.7566.8%
166.6%
1.2565.5%
1.566.7%
265.4%

How to read the result

The simulated rates sit within about 1 percentage point of the theory, as expected with 10,000 games. With more doors the advantage grows: with 100 doors and the host opening 98, switching wins 99 % of the time. The puzzle depends on the host's behaviour; if he opened a door at random and happened to show a goat, the odds would be 50/50.

Common mistakes

Keep in mind: The result depends on the rules: the host always opens a goat door and always offers the switch.

Frequently asked questions

Should you switch in the Monty Hall problem?

Yes, switching wins 2/3 of the time with 3 doors.

Why isn't it 50/50?

The host's choice is not random; it depends on where the prize is.

Who popularised the problem?

Steve Selvin posed it in letters to The American Statistician in 1975.

Sources: S. Selvin (1975), "A problem in probability" and "On the Monty Hall problem", letters, The American Statistician 29(1) and 29(3)

Checked 9 Nov 2026. S. Selvin, letters to the editor, The American Statistician, Feb. 1975 (“A problem in probability”) and Vol. 29 No. 3, Aug. 1975 (“On the Monty Hall problem”); win probabilities for n doors derived here by conditioning on whether the first pick is correct.

🧮 All math & statistics tools →🌍 Calculators by country →