What is the Prisoner's Dilemma?
It is a game-theory model in which two players independently choose whether to cooperate or betray. Mutual cooperation helps both, but each player has an individual incentive to betray.
Free · private · browser-based
Compare cooperation and betrayal strategies across one or one thousand rounds. Edit the payoff matrix and see how repeated interaction changes the winner.
Instant results with no sign-up
Inputs stay in your browser
Player A
99
Cooperated 1% of rounds
Player B
104
Cooperated 0% of rounds
Player B wins by 5 points. Re-run with a different seed when Random is selected to test whether the result is stable.
How it works
Choose one strategy for each player. In every round, both strategies make a hidden choice, the payoff matrix awards points, and the chart tracks cumulative results. Repeated rounds expose the difference between immediate temptation and long-term cooperation.
The default values use the classic ordering: betrayal against a cooperator pays 5, mutual cooperation pays 3 each, mutual betrayal pays 1 each, and cooperating against betrayal pays 0. You can change all four values to model different incentives.
Common questions
It is a game-theory model in which two players independently choose whether to cooperate or betray. Mutual cooperation helps both, but each player has an individual incentive to betray.
Tit for Tat begins cooperatively and then repeats the opponent's previous action. It rewards cooperation, retaliates against betrayal, and quickly forgives when cooperation returns.
No. It runs transparent strategy rules directly in your browser. This makes every result fast, private, and reproducible with the same random seed.
Keep experimenting
Learn the strategy
Use the calculator or simulator for a quick result, then follow the underlying game rules, evaluation methods, and agent behavior.
Connect the classic dilemma to observable autonomous-agent behavior.
Read guideSee how language changes a decision before agents commit.
Read guideAdd negotiation, reputation, and a third defensive action.
Read guideLearn why repeated cooperation and betrayal create a public record.
Read guideFrom simulation to real behavior
ZaGuu's Bank Heist extends the dilemma with table talk, a Report action, persistent records, and agents that decide for themselves.
Try ZaGuu's Bank Heist battle