Nonfiction Essays

How Many Different Games of Chess Are Possible?

Originally published on October 12, 2009.

Q: Is it true that the number of possible different games of chess is larger than the number of atoms in the universe?

Indeed. It is true. Hard to believe, yes, but true nevertheless. I shall endeavor to explain the phenomenon in a clear and concise fashion. I shall fail. I shall then lower my standards and settle for clear. If you want concise, then I’m going to need more money.

To avoid burdensome repetition of a long and unwieldy phrase, the number of possible different games of chess shall henceforth be designated by “c#.” This symbol will be used a little further in this discussion. Don’t be alarmed when it does.

Portrait of mathematician and information theorist Claude Shannon

Photograph courtesy Tekniska Museet of Sweden Licence

Claude Shannon. Computer pioneer and true master of understatement.

Discussions of the number of possible chess games inevitably include “Shannon’s number,” named after the information theorist Claude Shannon who published an influential 1950 paper titled Programming a Computer for Playing Chess, the subject of which was, one hopes, self-evident. (1) This number is 10120. Contrary to popular misconception (2), c# is almost inconceivably larger than Shannon’s number, which estimates a lower bound for chess games of no more than 40 moves. Just so we’re clear: standard convention defines a “move” as one move on each side, so when we say “40 moves” that means 40 moves on each side. (One move on a side is called a “ply” for some unfathomable reason.)

While most games that people actually play are finished within 40 moves, a game could, in theory, last much longer. But let’s just take a look at what a mammoth beast Shannon’s number is before we try to show it up with even bigger numbers.

The number of atoms in the observable universe is about 1080. Shannon’s number is, therefore, 1040 times bigger than this. In other words, for every atom in the universe, you could associate 10,000,000,000,000,000,000,000,000,000,000,000,000,000 separate and distinct possible chess games. Why you would want to do this is beyond me, but you could, in theory. In practice, you would constantly be dropping the atoms and losing count. It would get old so fast.

Here’s how Shannon calculated this estimation: He (3) looked at a large number of master games and determined the total number of legal moves in each position of the game. In any one of those many positions, there were probably no more than two or three moves that the masters were even considering, but there were, on average, about 30 legal moves (4). So from any given position, on average, I can make any one of thirty different moves. You can make any of thirty different replies. That’s 900 right there (30 x 30). Then I have thirty more choices and you have thirty replies. That’s 810,000. (30 x 30) x (30 x 30). By the third move we’re at (30 x 30) x (30 x 30) x (30 x 30) or, if you prefer 306, or, more dramatically, which I prefer: 729,000,000. 3080 (an average of 30 possible moves for 40 moves for each player, or 30 multiplied by itself 80 times) works out to 1.47 x 10118 which we can just round up to 10120. That’s big. As noted: much bigger than the number of atoms in the universe. But the true c# is even bigger. Much much bigger.


Draw, pardner!

Without certain rules, chess would have not merely a mind-bogglingly large number of possible move sequences, but it would actually be infinite. (5)

a lemniscate, or infinity symbol
Not just infinite, but uncountably infinite
see Chess and Infinity

These rules are as follows:

  1. When a board position has repeated 3 times, the game is a draw.
  2. When 50 moves have been made on each side without the exchange of a piece or the advancement of a pawn, the game is a draw.

Without these rules, any individual game could last an infinite number of moves and thus there would be an infinite number of possible different games. Using these rules, we can determine a reasonably low number for the longest possible game: 5,899 moves (6). No chess game that has ever actually been played by two players who were both trying to win and not set some sort of stupid record has ever lasted anywhere remotely close to this long for the simple reason that one of them would have slashed his wrists with a sharpened bishop to escape from the mind-numbing tedium.

An unreasonable but useful asumption

Assuming (7) that there are an average of 30 possible moves on each side at any given position, then 30(2 × 5899) = approximately 1017,000. This number is frakking huge.

Our actual universe has about 1080 atoms. If every one of those atoms had a sub-universe with 1080 atoms, that’s 10160 atoms. (We’re only counting the atoms at the bottom. The original 1080 atoms in the real universe are negligible compared to the 10160 atoms in all the sub-universes.) If every one of those 10160 atoms had a sub-sub-universe with 1080 atoms, that’s 10240 atoms. If every one of these had a sub-sub-sub-universe with 1080 atoms in it, that’s 10320, and so forth. You need over 200 levels to get to 1017,000.

Storing all these universes is going to be highly problematic. There is no room in my basement, so don’t even ask.


Plausible vs Nonsense Games

Not only would nobody ever play any of the many possible 5,899-move games that theoretically “exist,” the vast overwhelming majority of all possible games of any arbitrary length will be “nonsense games.” Games no real players would ever actually play.

Consider a game that has gotten to the point where you have a mate in one. You simply have to move a piece into position and end it, and any reasonable person would. But you could just move a piece on the other side of the board instead. And your opponent could do the same. Then you could forego the mate that is sitting right there, and make another silly move with different piece. This can continue for up to fifty moves before a draw is declared or until you get punched. Billions and trillions and quadrillions of different paths are available, all from a position that is a mate in one. Of course, any reasonable player is just going to take the mate and end it and start a new game, because life is short.

Since there are, on average, only about two moves that any intelligent chess player would consider making (sometimes it's more, but often there's just one obvious move), and since most games do not last more than 40 moves, we can calculate a very rough estimation of the number of “plausible” chess games at 280 which works out to about 1025. A tiny sliver of c#, or even Shannon's number. But it's still bigger than, say the U.S. national debt, measured in pennies, multiplied by the number of people who ever lived, which would be much less than 1% of this number.


Big numbers

A digression to illustrate what numbers can do when you aren’t paying attention and they multiply themselves together:

What is the largest number expressible in 3 digits?

Think it is 999? Afraid not, but let’s take a closer look at that number anyway. There are 1000 whole numbers from 0 to 999. 1000 different numbers can be expressed by the use of 10 digits in 3 fields. The reason that there is such a large number expressible with such small numbers is that there are 10 choices of a digit for the first field, and for every one of them there are 10 choices for second field, and for every one of them there are ten choices for the third field. 103 = 1000. Every additional digit increases the number by an order of magnitude, in precisely the same manner as every additional move increases the total number of possible chess games.

999 is pretty big, considering the small numbers that are used to construct it. But the biggest number expressible with 3 digits is 999. 99 = 387,420,489. Now raise 9 to this power. You get a number with about 300 million digits. The number of atoms in the universe has about 80 digits. Shannon’s number has 120. c# has a few thousand digits. This baby has 300 million.

Note that a number that is 300 million digits long is 10299,999,920 times bigger than a number with 80 digits. Pay close attention there: It’s not 300 million times bigger. It’s almost 10 to the power of 300 million times as big.

Incidentally, a googol is a one followed by a hundred zeros. 10100. Thus Shannon’s number, 10120, is a mere 100,000,000,000,000,000,000 (just 100 quintillion!) times larger than the famous googol. It is a paltry embarrassment next to the perhaps more famous googolplex. A googolplex is a 1 followed by a googol of zeros. In other words it is 10googol. Or 1010102. Even 999, which has no fancy name though it deserves one, can’t hold a candle to that monstrosity.

Take me to the bridge

I’ve played chess for years and I’ve only recently developed an interest in bridge. One could make estimations about the number of possible bridge games that could be played (let’s call it b#. No one will stop us.), and this has undoubtedly been done, though I have yet to look it up because that would take the fun out of it. The numbers are certainly humongous, or possibly ginormous, whichever is bigger. Your first step in calculating this would be to determine how many different ways an ordinary deck could be shuffled, and then figure out how many different ways four different players could play with each different distribution of cards.

The deck could be shuffled in 1067 different ways. You can confirm this by multiplying 52 x 51 x 50 x 49 . . . x 3 x 2 x 1. (8) This is known as 52 factorial, and is written: 52! You don’t have to shout when you read it or use special emphasis and it’s considered gauche if you do.

When you deal the cards out to North, East, South and West, it doesn't matter in what order they get the cards, just which 13 cards each player gets.

So what you are dealing with are combinations, not permutations. The number of opening bridge hands is thus a lot less than 52! Since there are four distinct players, each getting 13 cards, the math is pretty straoghtforward:

52! (13!) 4 5.36 × 1028

That's just the number of opening positions. As compared to chess where there is 1. To estimate the number of total possible bridge games, you'd have to consider each of those starting hands. From each of these, the first player has 13 choices. Then the next player has a number (not necessarily 13) of replies, then the next player has numerous choices, then the fourth. And so forth.

Nobody has calculated the number of possible ways any given deal could be played, but it's in the neighborhood of 10100. Multiply that by the 5.36×1028 and you get something in the neighborhood 10128 possible bridge games.

That's nowhere near as big as the number of possible chess games. But still much much more than the number of atoms in the universe.

Googols, googolplexes and factorials of numbers in the range of 52 or higher aren't useful to describe countable things. There just aren’t enough things to count. They are used only in describing abstract number theory or in describing possible combinations of things, such as chess moves or card positions.


But enough abstraction. It’s my move. King’s pawn. Good old e4. It’s your turn now. This is a game with perfect information, so you can, in theory, determine exactly the best course of action. Just think about each of your twenty possible replies, and my possible replies to every one of those, and your possible replies to that and so on.

Get back to me in 1090 years.

Notes

  1. It was about programming a computer to play chess.
  2. Not all that popular, actually, as most people outside math geek circles have never heard of it, and would have no interest in it whatsoever. Sad.
  3. To give credit where credit is due: it was some guy named De Groot who did this part of the analysis. I know that neither you nor he cares, but I’m a stickler for accurate attribution.
  4. On the first move, there are twenty legal openings for white and twenty legal replies by black, so there are 400 possible ways the two players can play the first move. As the game develops, there are more legal moves available on average, most of them very bad moves.
  5. As one commenter pointed out, the official rules do not require a game to be drawn by repetition or after 50 moves have occurred without a capture or pawn advance. So there is no theoretical longest game, and any game could last an infinite number of moves. Not only that, but c# would not merely be infinite, but an entirely higher level of infinity. Bigger than the infinity you are probably thinking of. This is the subject of a new essay, Chess and Infinity, which is better than this one if for no other reason than it has a lot of pictures.

    Update (2026): This is no longer true. Draws are now automatic, after enough repetition or moves without capture or pawn advance. So now the longest possible game is not infinite, and the number of different games is not uncountably or even countably infinite. It's just 10 to the power of a 5 digit number.

  6. More precisely, the longest possible game under these assumptions is 5,898.5 moves: White makes 5,899 moves and Black makes 5,898. This assumes that a draw is claimed as soon as one becomes available under the 50-move or threefold-repetition rule. The figure was first obtained by Karl Fabel in 1947 and has since been confirmed by explicit constructions, i.e. very boring games.

    Update (2026): As noted in an earleir foodnote, the fickle FIDE changed drawing rules after this essay was originally written, and allows 75, not 50 "quiet" moves, which bumps the longest game from 5,898.5 to 8,849. The analysis here uses the old rules, because I never signed on for the rules change and think it is stupid.

    You can see one of the many maximum game moves that theoretically could be played in this article But don't expect it be as exciting as Kasparov vs Deep Blue.

  7. This is a reckless, irresponsible, and unfounded assumption. We're going to make it anyway. A follow-up article, which hasn't been written yet, but is, at the time of this writing, rattling around obnoxiously in my head, will focus on this in more detail. In a nutshell, though, there are not 30 move choices, on average, in a 5,899.5-move-long game, as there were in Shanon's analyis. There are fewer, which brings down our c# estimate. On the other hand, we still have to consider all the 5,899 move games, all the 5,898.5 moves games, etc., which brings it up again.
  8. I bet that was fun. Why didn’t you just take my word for it?

Return to essays