3,3A Nash equilibrium is a combination of strategies — one for each player — such that no player can increase their own payoff by unilaterally changing strategy while the others keep theirs fixed. Everyone is playing a best response to everyone else.
A best response is the strategy that gives a player the highest payoff given what the other players are doing. A Nash equilibrium is exactly a profile where every player's strategy is simultaneously a best response to the others.
A payoff matrix lists the payoffs to each player for every combination of strategies. In a 2x2 game each cell holds two numbers: the row player's payoff and the column player's payoff.
A pure-strategy equilibrium is one where each player commits to a single strategy with certainty. On the matrix it is a cell where both players are best-responding — the row payoff is best down its column and the column payoff is best across its row.
A mixed strategy assigns probabilities to each pure strategy. In a mixed equilibrium each player randomises so that the opponent is indifferent between their own options, making the opponent willing to randomise too.
Yes. Nash's theorem (1950) proves that every finite game with a finite number of players and strategies has at least one equilibrium, possibly in mixed strategies. It may have several.
Best-response dynamics is a process where players take turns switching to whatever is currently their best response. In many games it converges to a pure equilibrium; in games like Matching Pennies it cycles forever.
In the Prisoner's Dilemma, Defect strictly dominates Cooperate for both players, so the unique Nash equilibrium is mutual defection — even though mutual cooperation would pay both more. The equilibrium is individually rational but collectively poor.
A Nash equilibrium is stable against unilateral deviation. A Pareto-optimal outcome is one no one can improve without hurting someone else. They need not coincide — the Prisoner's Dilemma equilibrium is not Pareto optimal.
John Forbes Nash Jr. (1928–2015) was an American mathematician who introduced the equilibrium concept in his 1950 PhD thesis. He shared the 1994 Nobel Memorial Prize in Economic Sciences for this work.
This tool lets you build a 2×2 payoff matrix (a table listing each player's reward for every pair of strategy choices) for two players and watches the game play out. It underlines each player's best response (the strategy that maximises their payoff given the opponent's choice) in every cell, boxes any cell where both players are simultaneously best-responding — a pure-strategy Nash equilibrium — and solves the indifference equations for the mixed-strategy equilibrium, where each player randomises between strategies with a specific probability. An animated token then runs best-response dynamics: players alternate switching to whatever is currently their best move, so you can watch play converge on an equilibrium or cycle forever.
A 2x2 payoff matrix with the row player's payoff shown top-left (green when it is a best response) and the column player's payoff shown bottom-right (blue when it is a best response) in every cell. Boxed cells are pure Nash equilibria. A second "Best-response correspondence" view plots both players' best-response curves in (p, q) probability space, marking where they cross.
Pick a classic game from the preset dropdown (Prisoner's Dilemma, Stag Hunt, Battle of the Sexes, Chicken, Matching Pennies) or type your own payoffs into the four "row,col" boxes — you can also click a cell on the canvas to edit it directly. The Speed slider controls how fast the best-response token moves; View switches between the matrix and the correspondence plot; Pause/Play, Step and Reset control the animation.
John Nash's 1950 existence proof, barely a page long, relies on Kakutani's fixed-point theorem to show every finite game has at least one equilibrium (possibly mixed). Matching Pennies, included as a preset here, has no pure equilibrium at all — only a mixed one at p = q = 0.5, which is exactly why the best-response token never settles down and instead cycles.
For each column the code compares the row player's two payoffs in that column and marks the larger one (rowBRset); for each row it compares the column player's two payoffs in that row (colBRset). If both numbers in a comparison are equal it treats both strategies as tied best responses. A cell is boxed as a pure Nash equilibrium only when the row payoff is a best response down its column AND the column payoff is a best response across its row at the same time.
The simulation solves the indifference conditions directly from the payoff numbers. It finds p (the probability the row player plays their first strategy) so that the column player is indifferent between their two options, and q (the probability the column player plays their first strategy) so that the row player is indifferent. Algebraically p = (d22-d21)/(d11-d12-d21+d22) using the column player's payoffs, and q is the mirror formula using the row player's payoffs. If either denominator is zero, or the result falls outside [0,1], no valid mixed equilibrium exists and the stat shows a dash.
Best-response dynamics in this simulation is a fixed alternating process: on every step the row player (or column player, alternating by turn) jumps to their current best response, regardless of whether the resulting cell is an equilibrium. Once the token lands on a boxed cell, both players' best responses point back at that same cell, so the token simply keeps landing there step after step — it looks stationary because it genuinely is, but the loop never explicitly "stops."
In Matching Pennies every cell has exactly one player wanting to switch, so there is no pure Nash equilibrium at all in this preset. Best-response dynamics therefore cycles through all four cells (Heads,Heads) → (Heads,Tails) → (Tails,Tails) → (Tails,Heads) → back to start, forever. The only equilibrium is the mixed one at p = q = 0.5, visible as the yellow dot at the centre of the correspondence view, which the alternating pure-strategy dynamics can never actually land on.
It draws p (probability row plays their first strategy) against q (probability column plays their first strategy) on a unit square. The green curve is the row player's best response p*(q) for every possible q, and the blue curve is the column player's best response q*(p) for every possible p, each computed directly from the expected-payoff formulas in the code. Blue dots mark the pure equilibria at the square's corners; a yellow dot marks the mixed equilibrium wherever the two curves genuinely intersect inside the square.
This tool lets you build and edit a 2×2 payoff matrix for two players. It highlights each player's best responses, marks the cells that are pure-strategy Nash equilibria (where both players best-respond), computes the mixed-strategy equilibrium from the indifference conditions, and animates best-response dynamics so you can watch play converge to — or cycle around — an equilibrium.
Best response: BR_i(s_-i) = argmax_{s_i} u_i(s_i, s_-i). Equilibrium: u_i(s_i*, s_-i*) ≥ u_i(s_i, s_-i*) ∀ s_i, ∀ i. Mixed (Row plays A w.p. p, Col plays A w.p. q): Col indifferent ⇒ p = (d22−d21)/(d11−d12−d21+d22) using Col payoffs; Row indifferent gives q from Row payoffs.
John Nash's existence proof is barely a page long and relies on Brouwer's (later Kakutani's) fixed-point theorem. The film A Beautiful Mind dramatised his life, though its bar scene actually describes a different concept, not a true Nash equilibrium.