Guide

How to Read Chess FEN Strings

FEN is the standard format for saving a chess position in a single line of text. Every chess engine, database, and tool uses it. Here's exactly how to read, write, and use FEN strings — with free tools to visualize positions instantly.

·7 min read·by chess.lc

What is a FEN string?

FEN stands for Forsyth–Edwards Notation, named after journalist David Forsyth (1883) and extended by Steven Edwards for computer use. It encodes a complete chess position in one line of text — 6 fields separated by spaces.

You'll encounter FEN everywhere: copying a position from Lichess, pasting into Stockfish, sharing a puzzle, or importing into a database. Understanding FEN lets you move positions between any chess tool instantly.

Starting position FEN:

rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1

The 6 fields of a FEN string

Every FEN has exactly six space-separated fields. Let's break down the starting position: rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1

1. Piece placementrnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR

Describes every rank from rank 8 (Black's back rank) to rank 1 (White's back rank), separated by slashes. Uppercase = White pieces. Lowercase = Black pieces. Numbers = consecutive empty squares.

2. Active colorw

'w' means White to move. 'b' means Black to move. This single character tells any engine whose turn it is.

3. Castling availabilityKQkq

Which castling moves are still legal. K = White kingside, Q = White queenside, k = Black kingside, q = Black queenside. A dash (-) means no castling is available.

4. En passant target square-

If a pawn just moved two squares, this is the square it passed through (e.g., 'e3'). A dash means no en passant is possible this turn.

5. Halfmove clock0

Counts moves since the last pawn move or capture. Used to enforce the 50-move draw rule. Resets to 0 after any pawn move or capture.

6. Fullmove number1

The current move number. Starts at 1 and increments after Black's move. A game on move 20 with White to play shows '20'.

How to read the piece placement field

The first field is the most complex. Each character represents a square, reading left to right across each rank, starting from rank 8 (top of board) down to rank 1 (bottom).

Piece letters

K / kKing
Q / qQueen
R / rRook
B / bBishop
N / nKnight
P / pPawn

Uppercase = White. Lowercase = Black.

Numbers = empty squares

A digit represents that many consecutive empty squares on the same rank. For example, 8 means an entire empty rank. 3p4 means 3 empty squares, then a Black pawn, then 4 empty squares.

Example

r3k2r/8/8/8/8/8/8/R3K2R

Rooks on a1/h1 (White) and a8/h8 (Black), kings on e1 and e8. All pawns and minor pieces gone — a rook endgame starting position.

Useful FEN positions to know

These positions come up constantly in study and analysis. Paste any of them into the Board Editor to visualize instantly.

Starting position

rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1

Lucena position (rook endgame)

1K1k4/1P6/8/8/8/8/r7/2R5 w - - 0 1

Philidor position

4k3/8/8/3KPp2/8/8/8/4R3 w - - 0 1

Scholar's Mate threat (move 3)

rnbqkb1r/pppp1ppp/5n2/4p3/2B1P3/8/PPPP1PPP/RNBQK1NR w KQkq - 2 3

King & pawn vs king (opposition)

8/8/8/4k3/8/4K3/4P3/8 w - - 0 1

Using FEN with free chess tools

Board Editor — visualize any FEN

Paste any FEN string into the Chess.lc Board Editor to see the position on an interactive board. You can also build positions by placing pieces manually — it auto-generates the FEN as you go.

  • ✓ Paste FEN → instant board visualization
  • ✓ Click to place pieces → generates FEN
  • ✓ 8 built-in preset positions (Lucena, Philidor…)
  • ✓ Copy FEN button for sharing

PGN Viewer — copy FEN mid-game

The Chess.lc PGN Viewer shows the current position's FEN at every move. Click any move, then use "Copy FEN" to grab that exact position. Useful for jumping into analysis from a specific moment in a game.

  • ✓ Replay games move by move
  • ✓ Copy FEN at any move
  • ✓ Paste PGN from Chess.com or Lichess

Run Stockfish on any FEN — free, no account

Once you have a FEN, paste it into chess.rodeo to run full Stockfish engine analysis — no account, no paywall, unlimited depth. The Board Editor's "Analyze with Stockfish" button passes the FEN directly.

How to copy a FEN from Chess.com and Lichess

From Lichess

  1. 1. Open any game in the board viewer
  2. 2. Navigate to the move you want
  3. 3. Click the share icon (↗) below the board
  4. 4. Select "FEN" from the dialog
  5. 5. Copy and paste anywhere

From Chess.com

  1. 1. Open a game in Analysis mode
  2. 2. Navigate to the position you want
  3. 3. Click "Share & Export"
  4. 4. Select "Copy FEN"

Writing a FEN string manually

You rarely need to write FEN from scratch — tools generate it for you. But understanding the format helps you edit FEN strings when you need a specific tweak (e.g., changing whose turn it is, or removing castling rights to test a position).

Quick reference for writing FEN

Rank order: Rank 8 first (Black side), rank 1 last (White side), left to right (a–h)

Empty squares: Count consecutive empty squares, write the number (1–8)

Rank separator: Forward slash / between ranks

Piece letters: K Q R B N P (White), k q r b n p (Black)

Active color: w or b

Castling: KQkq (all rights), or any subset, or - (none)

En passant: Square like e3 or f6, or - if not applicable

Clocks: 0 1 for a fresh position, or actual values from a game

Frequently asked questions

Can a FEN string represent any chess position?

Almost any. FEN covers all standard positions including castling, en passant, and the 50-move clock. It cannot encode the full game history (that's what PGN is for), but it captures everything needed to continue play from that exact moment.

Why do some FEN strings end with '0 1' and others with different numbers?

The last two numbers are the halfmove clock (moves since last pawn move/capture) and fullmove number. A fresh position or one right after a pawn move will show '0', while a long endgame position might show '47 62'. These affect the 50-move draw rule but not the actual piece positions.

Is FEN the same as PGN?

No. FEN describes a single position (one moment in a game). PGN (Portable Game Notation) records an entire game — all the moves from start to finish, plus headers. You can include a FEN inside a PGN file as the '[FEN]' header to start a game from a non-standard position.

What's the difference between FEN and EPD?

EPD (Extended Position Description) is a superset of FEN used for position analysis and puzzle databases. It uses the same first four fields as FEN but replaces the halfmove/fullmove clocks with operation codes. For normal use, FEN is what you want.

Try it now — paste a FEN string

Use the free Board Editor to visualize any position. No account needed, no paywall.

Related guides