Nash Equilibrium Calculator

Solve a 2x2 two-player game by entering payoffs in the form Player 1 payoff, Player 2 payoff.

About the Author: Created by Fotios Angelakis, MSc in Mechanical Engineering, with experience in data analytics, optimization, and applied calculator development. Learn more about the author's qualifications and experience.

Example cell format: 3,2 means Player 1 receives 3 and Player 2 receives 2.
C, Player 2 D, Player 2
A, Player 1
B, Player 1
Enter payoffs, then click calculate.

What a Nash Equilibrium Means

A Nash equilibrium is a strategy pair where each player is choosing a best response to the other player. Once the game reaches that strategy pair, neither player can improve their own payoff by changing strategy alone.

Nash equilibrium payoff matrix illustration
Nash equilibrium payoff matrix illustration used on Domycalculations.com.

How the Calculator Checks Pure Strategies

The calculator checks each cell of the payoff matrix. A cell is a pure strategy Nash equilibrium if:

  • Player 1 is choosing the best row against Player 2's chosen column.
  • Player 2 is choosing the best column against Player 1's chosen row.
Nash equilibrium = mutual best responses

How Mixed Strategy Probabilities Are Calculated

In a mixed strategy equilibrium, Player 1 randomizes between A and B, and Player 2 randomizes between C and D. The probabilities are chosen so that the other player is indifferent between their two strategies.

Let Player 1 payoffs be:

        C      D
A       a      b
B       c      d

If Player 2 plays C with probability q, Player 1 is indifferent when:

q·a + (1 − q)·b = q·c + (1 − q)·d

Let Player 2 payoffs be:

        C      D
A       e      f
B       g      h

If Player 1 plays A with probability p, Player 2 is indifferent when:

p·e + (1 − p)·g = p·f + (1 − p)·h

Common Mistakes

  • Typing only one payoff in a cell instead of two payoffs.
  • Mixing up Player 1 and Player 2 payoffs.
  • Assuming every 2x2 game has a valid interior mixed equilibrium.
  • Forgetting that pure equilibria can be multiple.
  • Assuming Nash equilibrium means the best total outcome for both players.

Example: Prisoner's Dilemma

        C       D
A     (3,3)   (0,5)
B     (5,0)   (1,1)

In this setup, the pure strategy Nash equilibrium is usually (B, D), because both players have an incentive to choose the defection-style strategy.

Nash equilibrium does not always mean the socially best or highest total payoff outcome. It means no player can improve by changing alone.

Frequently Asked Questions

Can a game have more than one Nash equilibrium?

Yes. Some games have multiple pure strategy Nash equilibria. Some also have mixed strategy equilibria.

Can a game have no pure strategy Nash equilibrium?

Yes. Some games, such as matching pennies, have no pure strategy equilibrium but do have a mixed strategy equilibrium.

Does this solve larger games?

This page is for 2x2 two-player games. Larger games require more general algorithms and support enumeration.

What does mixed strategy mean?

A mixed strategy means a player chooses between available strategies using probabilities instead of always choosing one fixed strategy.