FEN

documentation of de facto standards for chess variants

FEN

Standard fields

1. Piece placement

2. Color

The color field is denoted as w or b as for standard chess FENs.

3. Castling

In chess variants the FEN castling field retains its original role, but might be extendend with additional information.

4. En passant

The en passant field can naturally be generalized by using the respective crossed square of any pawn double step, irrespective of its rank. Note that in the CECP/xboard protocol, for FENs of variants with 10 ranks the en passant square uses a zero-based rank counting, just like the moves. For berolina pawns the en passant field contains both the crossed square and the target square of the berolina double step, e.g., e3d4, in order to disambiguate between two pawns that might both have crossed the same square via a double step, e.g., moves f2-d4 and d2-f4 for the e3 square.

For variants with endgame counting rules and where there is no en passant, such as Makruk, the en passant field is instead used in order to specify the counting limit in ply, e.g., 128 for 64 moves. In case no counting rule is active the field is 0 or -.

4.5. Check count (optional)

Usually after the en passant field follows the halfmove clock. However, for variants with check counting, such as 3check, the check counts are an additional field inbetween. This does not apply for variants where the first check wins, since the counts are the same for all non-final positions. In order to be able to represent arbitrary check counting variants, the check counting field specifies the number of remaining checks for the winning condition, separated by a +, e.g., rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 3+3 0 1 for the 3check starting position.

Note that lichess uses a different format incompatible with this standard. Instead of adding the remaining checks, it specifies the count of given checks for each side after a +. E.g., the 3check starting position looks like rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1 +0+0. Therefore it is recommended to support this non-standard notation as input, but it is discouraged to follow this when outputting FENs.

5. Halfmove clock

For variants with endgame counting rules, such as Makruk, the halfmove clock is used to specify the current count in ply. In case no counting rule is active the field specifies the usual halfmove clock as for all other variants.

6. Fullmove clock

The fullmove clock is the same as for standard chess FENs.