I have a pgn file containing a game. I want to add a comment into the game (like at move 23. - This is a ok move etc.) using words and not symbols. Is it possible to do this?

[Date "1910.01.07"]
[Result "1/2-1/2"]
[White "Carl Schlechter"]
[Black "Emanuel Lasker"]

1. e4 {Notes by J. R. Capablanca} e5 {This is Black's second move!} 2. Nf3 Nc6 3. Bb5 Nf6 *

This is a sample PGN game. You'll just need { and } to enclose your comments. But you should use a chess program to do it for you. SCID is free and can do it for you.

| improve this answer | |
  • 3
    Why would you need a dedicated chess program if they are standard ASCII text files with a recommended maximum line length of 80? Sounds like any text editor can do the trick. – user4378 Dec 15 '16 at 15:54

Yes, there are two ways to add a text comment to a pgn file.

The first is far more common: simply wrap the comment in {braces}

1. e4 {Best by test!} e5

The second is less common, but also a part of the official pgn spec1. An end of line comment is allowed if it is preceded by a semicolon

1. e4; Best by test!
1... e5

This is far more awkward to read (since there is an extra move number in the file) and not all software supports this.

As an aside, all major annotating software (chessbase, chess.com, lichess.org, SCID) defaults to using the first scheme.

1: The pgn spec file can be found either at https://www.chessclub.com/user/help/PGN-spec or http://www.saremba.de/chessgml/standards/pgn/pgn-complete.htm

| improve this answer | |
  • It's important to note very few softwares support the second format. It's like it's not part of the specification. – SmallChess Oct 12 '16 at 4:41
  • 1
    Unfortunately, many programs just take the standard as a "recommendation". Having written several PGN readers, it's sometimes quite amusing to see what's thrown at you. BTW, the semicolon style comment can be useful when } is part of the comment; I agree, though, it's hardly supported, and common software tends to break. – Eiko Oct 12 '16 at 8:59

Not the answer you're looking for? Browse other questions tagged or ask your own question.