Chess is a game, played by two players. One player plays with the white pieces, and the other player plays with the black pieces. Each player has sixteen pieces in the beginning of the game: one king, one queen, two rooks, two bishops, two knights, and eight pawns.
The game is played on a chessboard, consisting of 64 squares: eight rows and eight columns. The squares are alternately light (white) and dark colored. The board must be laid down such that there is a black square in the lower-left corner. To facilitate notation of moves, all squares are given a name. From the view of the white player, the rows are numbered 1, 2, 3, 4, 5, 6, 7, 8; the lowest row has number 1, and the upper row has number 8. The columns are named, from left to right, a, b, c, d, e, f, g, h. A square gets a name, consisting of the combination of its column-letter and row-number, e.g., the square in the lower left corner (for white) is a1.
Alternately, the players make a move, starting with the white player (the player that plays with the white pieces.) A move consists of moving one of the pieces of the player to a different square, following the rules of movement for that piece - there is one special exception, named castling, where players move two pieces simultaneously.
A player can take a piece of the opponent by moving one of his own pieces to the square that contains a piece of the opponent. The opponents piece then is removed from the board, and out of play for the rest of the game. (Taking is not compulsory.)
At the start of the game, the position of the pieces is as follows.
Thus, at the second row, there are eight white pawns, at the seventh row, there are eight black pawns. At the first row, from left to right, we have a: rook, knight, bishop, queen, king, bishop, knight, and rook. Note that the queens start of squares of their own color, with a dark square in each players left hand corner.
Movement of the pieces
The rook moves in a straight line, horizontally or vertically. The rook may not jump over other pieces, that is: all squares between the square where the rook starts its move and where the rook ends its move must be empty. (As for all pieces, when the square where the rook ends his move contains a piece of the opponent, then this piece is taken. The square where the rook ends his move may not contain a piece of the player owning this rook.)
The bishop moves in a straight diagonal line. The bishop may also not jump over other pieces.
The queen has the combined moves of the rook and the bishop, i.e., the queen may move in any straight line, horizontal, vertical, or diagonal.
The knight makes a move that consists of first one step in a horizontal or vertical direction, and then one step diagonally in an outward direction. The knight jumps: it is allowed that the first square that the knight passes over is occupied by an arbitrary piece. For instance, white can start the game by moving his knight from b1 to c3. The piece that is jumped over is further not affected by the knight: as usual, a knight takes a piece of the opponent by moving to the square that contains that piece.
The pawn moves differently regarding whether it moves to an empty square or whether it takes a piece of the opponent. When a pawn does not take, it moves one square straight forward. When this pawn has not moved at all, i.e., the pawn is still at the second row (from the owning players view), the pawn may make a double step straight forward. For instance, a white pawn on d2 can be moved to d4.
When taking, the pawn goes one square diagonally forward.
There is one special rule, called taking en-passant. When a pawn makes a double step from the second row to the fourth row, and there is an enemy pawn on an adjacent square on the fourth row, then this enemy pawn inthe next move may move diagonally to the square that was passed over by the double-stepping pawn, which is on the third row. In this same move, the double-stepping pawn is taken. This taking en-passant must be done directly: if the player who could take en-passant does not do this in the first move after the double step, this pawn cannot be taken anymore by an en-passant move.
A double pawn step, and a following en-passant capture
Pawns that reach the last row of the board promote. When a player moves a pawn to the last row of the board, he replaces the pawn by a queen, rook, knight, or bishop (of the same color). Usually, players will promote the pawn to a queen, but the other types of pieces are also allowed. (It is not required that the pawn is promoted to a piece taken. Thus, it is for instance possible that a player has at a certain moment two queens.)
The king moves one square in any direction, horizontally, vertically, or diagonally. There is one special type of move, made by a king and rook simultaneously, called castling: see below.
The king is the most important piece of the game, and moves must be made in such a way that the king is never in check: see below.
Under certain, special rules, a king and rook can move simultaneously in a castling move.
The following conditions must be met:
When castling, the king moves two squares towards the rook, and the rook moves over the king to the next square, i.e., black's king on e8 and rook on a8 move to: king c8, rook d8 (long castling), white's king on e1 and rook on h1 move to: king g1, rook f1 (short castling).
Check, mate, and stalemate
When the king of a player can be taken by a piece of the opponent, one says that the king is in check. For instance, the white player moves his rook to a position such that it attacks the black king, i.e., if black doesn't do anything about it, the rook could take the black king in the next move: we say that the white rook gives check. It is considered good manners to say check when one checks ones opponent.
It is not allowed to make a move, such that ones king is in check after the move. If a player accidently tries to make such a move, he must take the move back and make another move (following the rules that one must move with the piece one has touched, see below.)
When a player is in check, and he cannot make a move such that after the move, the king is not in check, then he is mated. The player that is mated lost the game, and the player that mated him won the game.
Note that there are three different possible ways to remove a check:
When a player cannot make any legal move, but he is not in check, then the player is said to be stalemated. In a case of a stalemate, the game is a draw.
When black must move, the game is a stalemate
Resign and draw proposals
A player can resign the game, which means that he has lost and his opponent has won.
After making a move, a player can propose a draw: his opponent can accept the proposal (in which case the game ends and is a draw) or refuse the proposal (in which case the game continues).
Repetition of moves
If the same position with the same player to move is repeated three times in the game, the player to move can claim a draw. (When the right to make a certain castling move is lost by one of the players between positions, then the positions are considered to be different.)
One case where the repetition of move occurs is when a player continues to give check forever. See an explanation with animated gif.
50 moves rules
If there are have been 50 consecutive moves of white and of black without
then a player can claim a draw.
When a player touches one of his own pieces, he must, if possible, make a legal move with this piece. When a player touches a piece of the opponent, he must, if possible, take this piece.
Chess clocks and time
Often, players play the game with chess clocks. These clocks count the time that each player separately takes for making his own moves. Additional rules are then used, saying how many (possibly all) moves must be made before a player has used a certain time for his moves.
There are other rules, telling what should happen in special occasions, like that players started the game with a wrong setup, etc. These are not so important for friendly games; for details, again see the official rules of chess.