Game Theory Payoff Matrix Solver

Two-player games up to 5×5: dominance, iterated elimination, best responses underlined, pure and mixed Nash equilibria, zero-sum value and a 2×2 best-response diagram.

Runs in your browser. Your files never leave your device. See how to check

…

How to do it

  1. 1
    Load or build a game

    Pick a classic game or set the number of rows and columns.

  2. 2
    Enter payoffs

    Type the blue payoff for player 1 and the red payoff for player 2 in each cell.

  3. 3
    Read the matrix

    Underlined numbers are best responses and green cells are pure Nash equilibria.

  4. 4
    Check the analysis

    Read dominance, iterated elimination and the mixed equilibria with probabilities.

  5. 5
    Use the diagram

    For 2 × 2 games see where the best-response lines cross.

  6. 6
    Save and practise

    Save games by name, print the analysis or answer generated questions in Practice.

About this tool

Game theory studies decisions where your best move depends on what someone else does: two firms setting prices, two drivers playing chicken, two suspects deciding whether to confess. Economics, politics and computer science students meet it through the payoff matrix, a table where each cell holds one payoff for each player. The key solution idea is the Nash equilibrium, a pair of strategies from which neither player wants to move alone. This solver takes any two-player matrix up to five strategies each, underlines best responses the way a textbook does, eliminates dominated strategies, lists every pure equilibrium and finds mixed equilibria where players randomise. Seven classic games load with one click, including the prisoner's dilemma, battle of the sexes and rock-paper-scissors.

Reading the matrix

Rows are the strategies of player 1 and columns those of player 2. In each cell the blue number is player 1's payoff and the red number player 2's. You can rename players and strategies and resize the table from 2×2 to 5×5. Payoffs can be profits, years in prison as negative numbers or any utility; only their order and, for mixed strategies, their differences matter.

Dominance

A strategy strictly dominates another if it gives a higher payoff whatever the opponent does. A rational player never uses a strictly dominated strategy, so it can be removed, and after one removal new dominations may appear. The tool lists every strict and weak domination and runs iterated elimination of strictly dominated strategies. In the prisoner's dilemma, defecting dominates cooperating for both players, which leaves only (Defect, Defect).

Best responses and pure equilibria

For each column the tool underlines player 1's highest payoff, and for each row player 2's highest payoff. A cell with both numbers underlined is a pure-strategy Nash equilibrium and is shaded green. Some games have several (stag hunt), some have exactly one (prisoner's dilemma) and some have none (matching pennies).

Mixed strategies

When players randomise, a mixed equilibrium makes each opponent indifferent between the strategies they use. In a 2×2 game, player 2 chooses q so that player 1's two rows pay the same, and player 1 chooses p so that player 2's columns pay the same. For larger games the solver uses support enumeration: it tries each set of strategies that might be used, solves the indifference equations and keeps solutions with valid probabilities and no profitable deviation. Nash proved in 1950 that every finite game has at least one equilibrium, possibly mixed.

Worked example

Battle of the sexes: player 1 prefers the opera (2, 1), player 2 prefers football (1, 2), and mismatches pay 0 to both. There are two pure equilibria, (Opera, Opera) and (Football, Football). For the mixed equilibrium, player 2 makes player 1 indifferent: 2q = 1 − q, so q = 1/3. Player 1 makes player 2 indifferent: p = 2(1 − p), so p = 2/3. Each player's expected payoff is 2/3, lower than either pure equilibrium.

Limits

The solver covers finite two-player games in normal form with complete information. It does not handle sequential games, repeated games, bargaining or incomplete information, and in degenerate games with ties it may list only some of infinitely many equilibria. It is a study aid and not advice for real negotiations.

Worked example

Battle of the sexes: pure (Opera, Opera) and (Football, Football); mixed p = 2/3, q = 1/3, payoffs 2/3 each.

Quick facts

Frequently asked questions

What is a Nash equilibrium?

A strategy for each player such that no player can gain by changing only their own strategy while the others keep theirs.

Why is the prisoner's dilemma a dilemma?

Defecting is best for each player whatever the other does, yet both defecting gives both a worse result than both cooperating.

Can a game have no pure equilibrium?

Yes. Matching pennies and rock-paper-scissors have none; their only equilibria are mixed, with each strategy played equally often.

What does the best-response diagram show?

For a 2×2 game it plots the probability each player puts on their first strategy. Where the two best-response lines cross are the Nash equilibria.

What is a zero-sum game?

A game where the payoffs in every cell add to zero, so one player's gain is the other's loss. The tool reports the value of such a game.

How many strategies can each player have?

Up to five each. The mixed-equilibrium search checks every possible support, which stays fast at that size.

Guides for this tool

Completely freeNo cost, no sign-up
Files stay privateEverything runs in your browser
Easy in your languageAvailable in many languages