Joke chess problems are puzzles in chess which use humor as a primary or secondary element. Although most chess problems, like other creative forms, are appreciated for serious artistic themes (Grimshaw, Novotny, and Lacny), joke chess problems are enjoyed for some twist. In some cases the composer plays a trick to prevent a solver from succeeding with typical analysis. In other cases, the humor derives from an unusual final position. Unlike in ordinary chess puzzles, joke problems can involve a solution which violates the inner logic or rules of the game.
Some chess puzzles are not really puzzles at all. In the diagram at right, White is asked to checkmate Black in six moves. The joke in this case is that, by the rules of chess, White has no choice but to checkmate Black in six moves: the only legal moves available lead directly to the "solution." The solution is 1. d4 b5 2. d5 b4 3. axb4 a3 4. b5 a2 5. b6 a1=any 6. b7#. Tim Krabbé provides other examples on his chess website.
The rules of chess are fairly simple and clearly defined. Nevertheless, some composers have relied on ambiguities in the rules to create humorous puzzles. A typical example would be the position shown in the diagram on the left. According to chess legend, a composer stipulated "White mates in one move." It appears to be impossible, but formerly the color of the promoted piece was not specified, and the 'solution' was for White to promote to a Black knight on b8, thus depriving the Black king of his only escape square.
A more sophisticated example was composed by Tim Krabbé and relies on a loophole that existed in the definition of castling. In the diagram on the right, White must mate in three moves. The main variations are 1. e7 Kd3 2. e8=Q gxf3 (other moves allow Qe2#) 3. 0-0-0#, 1. e7 Kxf3 2. e8=R! (an underpromotion) d4 3. 0-0#, and 1. e7 Kxf3 2. e8=R! Kg2 3. 0-0-0-0!#. In the last variation, White castles with his newly promoted rook, moving his king to e3 and the rook to e2. Under the rules of chess at the time, this move was legal because the rook had not moved yet. Afterward, FIDE amended the rules to require that the castling rook must occupy the same rank as the king.