What is the longest chess game possible in terms of chess moves? I read somewhere that there is a theoretical maximum of 5949 moves. But I don't see any proof and I don't think it is correct.
Can it be infinite?
Some cleaning up is required, I think:
The number on the website you link to differs from the results published in Bonsdorff et al., Schach und Zahl. Unterhaltsame Schachmathematik. pp. 11–13. There they say that if the 50-move-rule is mandatory the longest possible game (i.e. where both players cooperate to achieve the weird goal of a game of maximal duration) lasts 5899 moves. Possibly, the web site used a simpler upper estimate for the "gaps" between pawn moves and captures that cannot be achieved in all occasions.
However, the 50-move-rule (and also the position-repeated-three-times-rule) is not mandatory, i.e. whether or not a player demands remis by that rule is up to him! The players may decide to ignore the rule and play on, thus allowing for an eventually periodic sequence of moves, i.e. an infinite game.
32*50 = 1600; to lock the pawns up. In this case, White pushes each pawn 1 time until it is stopped by a black pawn.
6*50*8 = 2400; the white pawns are devoured one at a time, and as a black pawn is unblocked, it runs down the board, one square at a time. They promote to Knights.
7*50 = 350; each of the new knights are devoured.
30*50 = 1500; the rest of the pieces are devoured. Kings have to be left standing, so 30 here, not 31.
The sum of these moves is 5899. I don't know if it is the maximum, but it seems plausible.
From Wikipedia (see http://en.wikipedia.org/wiki/Draw_%28chess%29):
"The rules allow for several types of draws: stalemate, the threefold repetition of a position (with the same player to move), if there has been no capture or a pawn being moved in the last fifty moves, if checkmate is impossible, or if the players agree to a draw. In games played under time control, a draw may result under additional conditions. A stalemate is an automatic draw, as is a draw because of insufficient material to checkmate. A draw by threefold repetition or the fifty-move rule may be claimed by one of the players with the arbiter (normally using his score sheet), and claiming it is optional."
So, if none of the players claims a draw, the game can go on forever. If at least one of the players intends to claim a draw when he has the possibility, then the threefold repetition rule and the fifty-move rule garantee that the game will end after a finite time. Maybe this can give the number of 5949 moves though? Considering the vast number of possible positions, the game could go on for much longer than 5949 moves before the threefold repetition rule applies. The fifty-move rule means that every 50 moves one of the players has to either move a pawn or make a capture. Pawn can make 2x8x6=96 moves. There are 32 pieces, so we can never exceed 50x(96+32)=6400 moves. So what is the minimal number of pieces that have to remain on the board to avoid a stalemate?
Ian Stewart discusses in an October 1995 Scientific American column how chess can be played with an infinite number of moves (and thus have a game that never ends).
Anyone who plays chess knows that some games just peter out : neither player seems able to win, nothing constructive can be done and there is no obvious way to end the game. If neither player agrees to a draw, the game might go on indefinitely. Foreseeing such situations, the bodies that frame the laws of chess have proposed many different rules to force games to end. The classic law states that the game shall be drawn if a player proves that 50 moves have been made on each side, checkmate has not been given, no men have been captured and no pawn has been moved.
But recent computer analyses have shown that the rule is not sufficient. There are some endgames in which one player can force a win after 50 moves, when no pieces have been captured and no pawns moved. So the laws of chess must specify certain exceptional situations. Any law that limits the number of moves permitted under particular conditions runs the same risk as the original, and so it would be nice to come up with a different approach altogether. One proposal, made some time ago, was that the game should end if the same sequence of moves, in exactly the same positions, is repeated three times in a row. (Do not confuse this with the standard law that if the same position occurs three times, the player facing it can claim a draw. But note that this law does not oblige them to do so.)
Stewart then proceeds to create a sequence of two symbols that never repeats a pattern thrice. He then shows that this sequence can be used by the two players to play a valid endless game even if the proposal becomes official. (This sequence is called Stewart's choral sequence.)
There is a cap on the length of a game of chess in terms of the number of moves. That's because of the Fifty-Move Rule. Any attempt to draw out a game indefinitely would trigger the fifty-move rule and result in a draw. The reason for this is simple. To carry on the game indefinitely, you have to:
Also, I suggest moving this to Chess.SE.
The other answers have relied on the 50 move rule, and have pointed out the possibility of the game not ending if neither player invokes it.
As it is highly unlikely somebody would want to play a game of chess for thousands of moves in a regular game, it follows that such a game would be contrived solely for the purpose of playing out the longest chess game possible. Furthermore, as nobody would want to spend their entire life playing a game of chess just to hold the record for longest game of chess, this all would be a purely mental exercise.
However, given these constraints and the fact that an unending game of chess is possible if neither player claims a draw from the 50 move rule, it is still unsatisfying to say that a game of chess can go on forever. Since we cannot substitute chess players, eventually one or the other of the players will die of old age or some other cause and will be unable to continue thereby forfeiting the game or at least bringing it to an end. We can therefore calculate an upper limit on the number of moves that can be played before this occurs.
Assuming both players learn to play chess earlier than any person yet, say at 3 years old, and live to be older than the oldest person alive, say 120 years old, and that they play every waking moment, say 16 hours per day on average, and play speed chess averaging one move per second, and take only leap days off to rest, this yields an upper bound of 1 move/second * 86400 seconds/day * 365 days/year * 117 years or 3,689,712,000 moves as the longest chess game possible between two people when neither invokes the 50 move rule to claim a draw.
The answer depends on preference:
See https://wismuth.com/chess/longest-game.html for a detailed demonstration.
If you don't apply either of these, the next hurdle is draw by repetition (at 3 or 5 occurrences). I don't know if anyone has explored this systematically: perhaps a project for someone?
If you reject draw by repetition too, then you can carry on forever. Have a look at https://wismuth.com/chess/statistics-games.html#perft-ratios which argues that the maximum eigenvalue of chess (which will dominate the growth rate in the long run) is about 84.3.
Which approach is right?
Theoretically it can be infinite I think, but practically they say it's a draw when both players have only a King and a Knight left for example.