Castling in Chess
How to castle kingside and queenside, the six rules that decide when you can, the cases that catch strong players out, and nine positions to solve.
How to castle kingside and queenside, the six rules that decide when you can, the cases that catch strong players out, and nine positions to solve.

Castling is a special move in chess that lets you move your king and one of your rooks in a single turn. The king moves two squares towards the rook, and the rook jumps over the king to land on the square right next to it. It is the only move in chess in which two pieces move at once, and it is the quickest way to tuck the king into a safe corner and bring a rook into the game. Each player can castle at most once a game, and only if the king and that rook have never moved, nothing stands between them, and the king is not in check and does not pass through or land on an attacked square.
This page explains how to castle on both sides of the board, every castling rule, the cases that confuse even strong players, and how to write castling down. The free castling trainer below has nine positions to test yourself. For the rest of the rules, see how to play chess.
Nine positions, each reached by real moves, so the castling rights are genuine. In three of them you have to castle: tap the king, then the square it moves to (tapping the rook works too). In the other six, decide whether castling is allowed. The last move played is highlighted.

There are two ways to castle, one towards each rook:
| King | Rook | Must be empty | |
|---|---|---|---|
| White 0-0 | e1 → g1 | h1 → f1 | f1, g1 |
| White 0-0-0 | e1 → c1 | a1 → d1 | b1, c1, d1 |
| Black 0-0 | e8 → g8 | h8 → f8 | f8, g8 |
| Black 0-0-0 | e8 → c8 | a8 → d8 | b8, c8, d8 |
In both cases the king always moves exactly two squares, and the rook always ends up on the square the king passed over. On the queenside the rook travels three squares and on the kingside two.
Under the FIDE Laws of Chess you can castle only when all of these are true:
Rules 1 and 2 remove the right to castle permanently. Rules 3 to 6 only stop you castling for now: once the pieces are moved out of the way, or the attack or check is gone, you can castle on a later move.
| Situation | Can you castle? | Why |
|---|---|---|
| Your king is in check | No | Castling out of check is not allowed. Deal with the check first. |
| The king would cross an attacked square | No | The king may not pass through check. |
| The king would land on an attacked square | No | No move may leave your king in check. |
| Your rook is attacked | Yes | Only the king’s squares matter. |
| The rook passes over an attacked square (b1 or b8) | Yes | The king never touches b1, so it does not count. |
| You have been in check earlier in the game | Yes | As long as the king did not move to escape it. |
| The king moved and came back | No | Moving the king loses castling for the rest of the game. |
| One rook has moved | Only with the other rook | The right is lost only on the side of the rook that moved. |
| A pawn has just been promoted to a rook | No | Castling is only with a rook on its original square. |
| You have already castled | No | Castling moves the king, so you can only do it once. |
These cases trip up even grandmasters. Viktor Korchnoi, in his 1974 Candidates final against Anatoly Karpov, asked the arbiter whether he could castle while his rook was under attack. The answer was yes, he castled, and Karpov resigned shortly afterwards. Top players have also castled illegally in serious games after forgetting that the king or rook had already moved and returned home, and the opponent did not always notice.
Castling counts as a king move, so in a tournament game you must touch the king first. Under FIDE’s touch-move rules, if you touch your king and a rook you must castle on that side if it is legal. If you deliberately touch the rook first, you are not allowed to castle on that side on that move and must move the rook instead. Move the king two squares, then lift the rook over it, all with one hand. In friendly games these rules are rarely enforced, but it is a good habit.
Castling has its own symbols. 0-0 means kingside castling and 0-0-0 means queenside castling, in both algebraic and descriptive notation. Many books, apps and PGN files write the same moves with the letter O: O-O and O-O-O. The number of zeros matches the number of squares between the king and the rook: two on the kingside, three on the queenside.
It is common for both players to castle kingside, less common for them to castle on opposite sides, and uncommon for both to castle queenside. Kingside castling needs only two pieces, the knight and the bishop, to leave the back rank, so it can be done in as few as four moves, and the king ends up close to the corner behind three pawns. Queenside castling takes longer, because the queen has to move as well, and it leaves the king one square further from the corner, so the a-pawn is often left unprotected. In return the rook lands straight on the d-file, ready to join the game.
The choice is a trade-off between king safety and rook activity. When the players castle on opposite sides, each is free to push the pawns in front of the enemy king without weakening their own, which usually leads to a sharp race of attacks.
Castling grew out of the medieval king’s leap, a two-square king move added to European chess in the 14th and 15th centuries. As the queen and bishop became long-range pieces, keeping the king safe mattered more, and various forms of castling appeared. The modern rule was settled in France in 1620 and in England in 1640, but local versions lasted much longer: in Italy, different castling rules were used until the late 19th century.
Castling still divides opinion. In 2021, former world champion Viswanathan Anand beat Vladimir Kramnik 2½–1½ in an exhibition match of chess without castling, a variant Kramnik had proposed. And in Chess960, where the pieces start in a shuffled order, the king can move anywhere from zero to six squares when it castles.
Castling is one of the three special moves in chess, with en passant and pawn promotion. To learn how every piece moves, see chess pieces names and moves, and for the complete rules, including check, checkmate and stalemate, plus a free game against the computer, see how to play chess. For other board games, try checkers.
After going through several successful experiences with several industry pioneers, Fadi Hayek has managed to excel in the world of content for online gaming by providing unique content for several projects that allowed him to obtain the necessary experience to launch his career. Last but not least, Fadi also holds several certificates, including but not limited to content marketing and iGaming.