The rule: count the opponent's moves
Stalemate does not come from nowhere. It appears when the opponent has very few moves left and we take away the last one. So before every move in a won endgame, when the opponent has a lone king or a king and blocked pawns, it is worth asking one question: how many legal moves will they have after my move?
- If zero and I am not giving check, it is stalemate. I look for another move.
- If zero and I am giving check, it is mate.
- If one or two, I check that after their reply I will not give stalemate on the next move.
The counting takes a few seconds, because with a lone king there are at most eight squares to check. You only have to remember pieces that look dead: a pawn blocked on the seventh rank is also a piece with no moves.
The queen in the corner
For queen mates the popular method is “a knight's move away”: the queen stands a knight's move from the enemy king and takes squares away from it. We describe it on the page King and queen checkmate. In the corner the same distance gives stalemate.
Position composed for this article: king and queen against king near the corner.
The queen on d7 stands a knight's move from the king on b8. The black king has one free square: a8.
The queen stays where it is, and the White king moves forward.
2. Qc7?? The queen again stands a knight's move from the king. Black is not in check and has no move: stalemate.
The White king takes away the a7 and b7 squares. The black king still has the b8 square, so this is not stalemate.
After 1...Ka8 the move 2.Qc7 looks natural, because the queen again stands a knight's move from the king. But the black king has no square at all and the game ends in a draw. Correctly the queen stays on d7 and holds the king between a8 and b8, while the White king goes to work. After five king moves the queen mates on b7. The tablebase confirms: 2.Qc7 draws, and the calm 2.Ke2 wins.
Conclusion: when the enemy king reaches the corner, the queen stops moving. Your own king moves.
Greedy capture of the last pawn
The second situation: the opponent has a king locked in the corner and one movable pawn. That pawn is their only move. Capturing it looks like a pure gain, and ends the game in a draw.
Position composed for this article: the rook can capture the pawn or give mate.
The black king has not a single square: the king on f7 guards g8 and g7, and the g6 pawn covers h7. Black's only movable piece is the b4 pawn.
Check along the h-file and mate.
1. Rxb4?? White takes the last movable pawn. Black has no move and is not in check: stalemate.
1. Rb3?? The rook blocks the pawn. That is stalemate too.
After 1.Rxb4 Black has no move, so it is stalemate. 1.Rb3, which only blocks the pawn, works the same way. White wins at once with 1.Rh1, because it is check and the king has no squares. In this position both mistakes take away the opponent's last move, while the mate takes it away with check. We write more about the rook mate on the page King and rook checkmate.
The queen against a pawn one step from promotion
A pawn one step from promotion does not save the defender against a queen if it is a central pawn. The exceptions are the rook pawn and the bishop pawn, when the stronger side's king stands far away. The defender then saves the game with stalemate.
The rook pawn
Position composed for this article: queen against the a2 pawn, White's king far away.
The black a2 pawn is one step from promotion, and the White king stands far away.
The only move that draws. After 1...Kc1 White wins.
2. Kf4?? Every White king move is stalemate: the black king has no squares, and the a2 pawn is blocked by its own king.
2. Qc2?? Stalemate too.
The position repeats. White has no time to bring the king over.
After 1.Qb3+ Black plays 1...Ka1. The king itself blocks its own pawn's path, so Black has no move. White has to move the queen and free the square, because every king move is stalemate. The queen keeps checking, the king returns to the corner and the position repeats. The tablebase rates this position as a draw. We write more about the exceptions for a pawn on the edge on the page The rook pawn.
The bishop pawn
With a pawn on the c-file or f-file the defense is similar, but works differently. The king does not stand in front of the pawn but runs to the corner and leaves the pawn undefended:
Position composed for this article: queen against the c2 pawn, White's king far away.
The black c2 pawn is one step from promotion.
Black to move and save the draw. Where should the king go?
Show solution
The king runs to the corner and leaves the pawn undefended. After 1...Kc1 White wins.
Stalemate. The c2 pawn was Black's only movable piece. After 1...Ka1 the tablebase rates every White move as a draw.
More positions like this: Lesson “Don't stalemate”
Explanation of the solution
After 1...Ka1 the c2 pawn hangs, but capturing it is stalemate. If White does not capture it, Black threatens to promote on c1. The tablebase rates every White move as a draw. For comparison: with a d2 pawn, in the same setup of the king and White's queen, the tablebase gives White a win. A central pawn does not give the defender such an escape.
When the king is in time
Everything changes when the stronger side's king is close. Here is the same position with the black king in the corner, only the White king stands on d2 and guards the promotion square:
Position composed for this article: pawn on c2, White's king on d2.
The same position as after 1...Ka1 in the previous example, but White's king stands on d2 and guards the c1 square.
A calm queen move. The black king gets the a2 square, so there is no stalemate.
1. Qxc2?? Stalemate.
1. Kxc2?? Stalemate too.
Both 1.Qxc2 and 1.Kxc2 are stalemate. The calm 1.Qb4 wins. The black king gets the a2 square, that is a move, and White meanwhile takes the pawn with the king. After 1...Ka2 2.Kxc2 Ka1 the queen gives mate on b1. The engine and the tablebase point to the same plan: mate in three.
The mad rook
Stalemate can also be the defender's weapon. If their king has no move and their only movable piece is a rook, the rook can check without end. Capturing it is stalemate, and escaping the checks is sometimes impossible. Such a rook is called a mad rook.
Position composed for this article: Black has a rook against a queen.
White has a queen for a rook. The black king has no squares: the queen on a2 guards g8, and the g6 pawn guards h7. The g7 pawn is blocked. Apart from the rook, Black has no move at all.
1… Rh3? 2. Qa8# An ordinary rook move loses.
2. Kxf1 Stalemate.
Not 2...Rf2+, because 3.Qxf2 captures the rook without stalemate.
Not 3...Rf1+, because after 4.Ke3 the White king escapes the checks.
Stalemate. Moving the king to f2, e4 or f4 also gives a draw, because the rook keeps checking.
White has a queen for a rook, and yet the tablebase rates the position as a draw. An ordinary rook move loses, for example after 1...Rh3 comes 2.Qa8 mate. So Black checks at once: 1...Rf1+. What matters is where the checks come from. After 2.Kg2 the check 2...Rf2+ loses, because the queen captures the rook on f2 and there is no stalemate. After 3.Kf3 the check 3...Rf1+ also loses, because the king escapes to e3. In this position the rook must check in such a way that the king can capture it and the queen cannot.
The conclusion for the stronger side is the same as before. Before the opponent is left with a lone king and one piece, you have to check whether their king has any move at all. If not, that last piece will not defend but attack.
The typical mistake: a move on autopilot
One thing links all the positions in this article. Stalemate comes after the move that looked most natural: the queen closer to the king, capturing a free pawn, capturing a rook that is checking. In a won endgame it is easy to stop counting, because the result seems settled. We describe this drop in attention after the pieces are traded on the page Endgame collapse.
Two rules are enough to avoid it. First: before every move, count the opponent's legal moves after it. Second: when the opponent has one or two squares left, look for a move that leaves them a square, and only then close the net. That is how White won in the corner and with the c2 pawn. Note: a king move can also give stalemate, like 1.Kxc2 in the position with the king on d2.
We describe the same situation from the defender's point of view, that is, checking a fortress and the chance of stalemate, in the knowledge library on the page Fortress and stalemate safety. The other endgames worth knowing are collected in the section Chess endgames.
Frequently asked questions
What is stalemate in chess?
A situation in which the side to move is not in check and has no legal move. The game then ends in a draw, no matter how much material the opponent has.
How do you avoid stalemate in a won endgame?
Before every move, count the opponent's legal moves after it. If there are none and you are not giving check, it is stalemate. When the opponent has one or two squares left, look for a move that leaves them a square.
What is a mad rook?
The rook of a defender whose king has no move. The rook checks without end, because capturing it gives stalemate, and escaping the checks does not end the game.
