Given a position for just one player, how can I check to see if there is a standard opening that leads to that position?

For example, how could I find if there is an opening that leads (or may lead, if the line is followed by black) to a position like this for white?

[FEN "8/8/8/8/3PP3/2P2P2/PP4PP/RNBQKBNR w KQ - 0 1"]
  • 2
    While this looks like after the fourth move, in theory this could be further into the game after e.g. a Four Knights Game Apr 14, 2021 at 6:19
  • @HagenvonEitzen True! (I would also be interested in ways to find games based on the position of one player, which I guess both generalises and solves my original question on finding openings.)
    – badroit
    Apr 14, 2021 at 6:33
  • I don't know why you'd want to do such a thing but this doesn't look to me like any well known opening. Perhaps some setup against a fianchetto defense by Black, but definitely not the best option to counter it.
    – David
    Apr 14, 2021 at 7:01
  • 2
    Unsurprisingly, the more passive your wish structure (Hippo against all :-), the more probable you can play it against most answers of your opponent. Apr 14, 2021 at 7:16
  • I suspect you have just left the pieces on the original squares because you are looking for openings that make this pawn structure. It is much less likely that you will achieve this position on the first four moves than that you will achieve this pawn structure with some of the pieces moved. If that is really what you want you should improve the question. Apr 15, 2021 at 3:16

2 Answers 2


Using my free, open source pgn-extract program you can specify a grep-like FEN pattern to be searched for in a PGN file of games. The program comes with a file of opening lines (eco.pgn) so a search such as:

pgn-extract --fenpattern "*/*/*/*/3PP3/2P2P2/PP4PP/RNBQKBNR" eco.pgn

would output any matches along with the associated ECO information in the tags. I didn't find anything for this particular pattern.


As kentdjb already noted, there is no variation with that exact position which has an ECO entry.

But it happened in sub lines of some ECO codes. I did a search on this database (only contains GM games and games before 1900).

Both pgn-extract and this CQL query ...

cql() Ra1 Nb1 Bc1 Qd1 Ke1 Bf1 Ng1 Rh1 Pa2 Pb2 Pc3 Pd4 Pe4 Pf3 Pg2 Ph2

... find 40 results.

Most often the position appears in:

  • B07e: Pirc, 3.f3 (1.e4 d6 2.d4 Nf6 3.f3 and now 3...c5 4.c3)
  • B22e: Sicilian, Alapin, 2...d6 (1.e4 c5 2.c3 d6 and now 3.d4 Nf6 4.f3)
  • B12d: Caro-Kann, Fantasy Variation (1.e4 c6 2.d4 d5 3.f3 and now 3... g6 4.c3)

The positions reached via Pirc and Alapin are the same, they are reached via transposition.

It also appears in one game starting with B00f: Owen (1.e4 b6 2.d4 Bb7 and now 3.f3 g6 4.c3) and in two games starting with B06g: Modern, 3.c3 (1.d4 g6 2.e4 Bg7 3.c3 and now 3...d5 4.f3 and 3...d6 4.f3).

The oldest game is this one (Owen move order):

[FEN ""]
[StartPly "7"]
[Event "Sixth American Chess Congress"]
[Site "New York NY USA"]
[Date "1889"]
[Round "24"]
[White "Judd, Max"]
[Black "Gunsberg, Isidor"]
[Result "1-0"]
[ECO "B00"]

1.e4 b6 2.d4 Bb7 3.f3 g6 4.c3 Bg7 5.Bd3 e5 6.d5 Nf6 7.Be3 O-O 8.Ne2 d6 9.
Nd2 Nbd7 10.Nf1 a5 11.Rc1 Nc5 12.g4 Nxd3+ 13.Qxd3 Nd7 14.Rc2 Nc5 15.Qd2 
Qf6 16.Bxc5 Qxf3 17.Qe3 Qxg4 18.Ba3 f5 19.c4 fxe4 20.Rg1 Qf3 21.b3 Rf7 22.
Bc1 Bc8 23.Nc3 Bf5 24.Rf2 Qh5 25.Ng3 Qh4 26.Qg5 Qh3 27.Ncxe4 Bxe4 28.Nxe4 
Rxf2 29.Nxf2 Qc3+ 30.Qd2 Qf3 31.Qe3 Qf5 32.Qe4 Qf7 33.Be3 Rf8 34.h4 Kh8 
35.Nh3 h6 36.Qxg6 Qxg6 37.Rxg6 Rf3 38.Bxh6 Rxh3 39.Bxg7+ Kh7 40.Rg4 Rh1+ 
41.Kd2 Rh2+ 42.Kc3 Rxa2 43.Bf6 Rf2 44.Bd8 Rf7 45.Kd3 Rd7 46.Bg5 Kg6 47.Ke4
Rf7 48.Bd8+ Kh7 49.Rg3 Rf4+ 50.Ke3 a4 51.bxa4 Rxc4 52.Rg2 Kh6 53.Ra2 Kh5 
54.a5 bxa5 55.Rxa5 c6 56.dxc6 Rxc6 57.Ke4 Rc4+ 58.Kf5 Rf4+ 59.Ke6 Rd4 60.
Bf6 Kg6 61.Ra7 Rf4 62.Rg7+ Kh5 63.Bg5 Rf1 64.Kxd6 e4 65.Re7 Re1 66.Kd5 
Rd1+ 67.Kxe4 Re1+ 68.Kf5 Rf1+ 69.Bf4 1-0

The highest rated games in the Pirc/Alapin move orders are these:

(Pirc move order):

[FEN ""]
[StartPly "7"]
[Event "FIDE World Blitz 2014"]
[Site "Dubai UAE"]
[Date "2014.06.20"]
[Round "18.36"]
[White "Moiseenko, Alexander"]
[Black "Jobava, Baadur"]
[Result "1/2-1/2"]
[WhiteElo "2707"]
[BlackElo "2713"]
[ECO "B07"]

1.d4 d6 2.e4 Nf6 3.f3 c5 4.c3 e6 5.Be3 Nc6 6.Bd3 Qb6 7.Qd2 Bd7 8.dxc5 dxc5
9.Na3 Qc7 10.Ne2 Ne5 11.O-O O-O-O 12.Nc4 Nxd3 13.Qxd3 Bb5 14.Nd6+ Bxd6 15.
Qxb5 a6 16.Qc4 b5 17.Qb3 c4 18.Qc2 Bxh2+ 19.Kf2 Bd6 20.a4 Bc5 21.Bd4 e5 
22.Bxc5 Qxc5+ 23.Kg3 Kb7 24.axb5 axb5 25.Ra5 Ra8 26.Rfa1 Rxa5 27.Rxa5 Ra8 
28.Rxa8 Kxa8 29.Qd2 h6 30.Qd8+ Kb7 31.Kh2 Qe3 32.Qe7+ Kc6 33.Ng3 Qf4 34.
Kh3 Nh7 35.Qe8+ Kd6 36.Nf5+ Kc7 37.Qe7+ Kb6 38.Qd8+ Ka7 39.Qa5+ Kb7 40.
Qxb5+ Ka7 41.Qd7+ Kb6 42.Qd6+ Ka7 43.Qc7+ Ka8 44.Qc6+ Ka7 45.Qc5+ Kb8 46.
Qb5+ Ka7 47.Qa4+ Kb6 48.Qb4+ Ka7 49.Qc5+ Kb8 50.Qb6+ Ka8 1/2-1/2

One month later Jobava had this position with white (Alapin move order):

[FEN ""]
[StartPly "7"]
[Event "ACP Golden Classic 2014"]
[Site "Bergamo ITA"]
[Date "2014.07.14"]
[Round "3.2"]
[White "Jobava, Baadur"]
[Black "Nepomniachtchi, Ian"]
[Result "1-0"]
[WhiteElo "2713"]
[BlackElo "2730"]
[ECO "B22"]

1.e4 c5 2.c3 d6 3.d4 Nf6 4.f3 Nbd7 5.Be3 g6 6.Bd3 Bg7 7.Ne2 O-O 8.O-O a6 
9.Nd2 b5 10.a4 Rb8 11.axb5 axb5 12.b4 c4 13.Bc2 e5 14.h3 Re8 15.f4 exd4 
16.Bxd4 Bb7 17.Ng3 Ra8 18.Re1 Rxa1 19.Qxa1 Nb8 20.Qd1 Nc6 21.Bf2 Nd7 22.
Ne2 Nf6 23.g4 Qa8 24.Ng3 Nd7 25.e5 dxe5 26.f5 Nf6 27.Nde4 Rd8 28.Nxf6+ 
Bxf6 29.Qc1 Bg7 30.Bb6 Rc8 31.Rf1 Qa6 32.Bc5 Nb8 33.Qd2 Re8 34.Ne4 gxf5 
35.Nd6 Rd8 36.Qg5 Rxd6 37.Qxf5 Bd5 38.Qxh7+ Kf8 39.Qg6 Ke7 40.Qxg7 Nd7 41.
Qg5+ Ke8 42.Be4 f6 43.Qh5+ Bf7 44.Qh8+ Ke7 45.g5 Nxc5 46.bxc5 Qa7 47.gxf6+

Highest rated game in the Caro-Kann Fantasy move order:

[FEN ""]
[StartPly "7"]
[Event "World Blitz"]
[Site "Moscow RUS"]
[Date "2009.11.17"]
[Round "27"]
[White "Ivanchuk, Vassily"]
[Black "Leko, Peter"]
[Result "0-1"]
[WhiteElo "2739"]
[BlackElo "2752"]
[ECO "B12"]

1.e4 c6 2.d4 d5 3.f3 g6 4.c3 Qb6 5.Qb3 Nf6 6.e5 Ng8 7.f4 h5 8.Nf3 Nh6 9.
Be3 Bf5 10.Nbd2 e6 11.a4 Nd7 12.a5 Qxb3 13.Nxb3 Be7 14.Be2 Kf8 15.O-O Kg7 
16.Rfc1 Rhc8 17.h3 c5 18.Bb5 cxd4 19.Bxd7 Rd8 20.Bxd4 Rxd7 21.Bc5 Be4 22.
Nfd4 Nf5 23.Bxe7 Rxe7 24.Kf2 Rc7 25.g4 hxg4 26.hxg4 Ne7 27.Nb5 Rd7 28.Nc5 
Rdd8 29.Nxb7 Rh8 30.Kg3 Rh7 31.a6 Rah8 32.Rf1 Rh2 33.f5 g5 34.f6+ Kg6 35.
fxe7 R8h3# 0-1

Other CQL queries you may try:

// exact position, including flipped positions
cql() flipcolor { Ra1 Nb1 Bc1 Qd1 Ke1 Bf1 Ng1 Rh1 Pa2 Pb2 Pc3 Pd4 Pe4 Pf3 Pg2 Ph2 }

// Exact pawn structure
cql() Pa2 Pb2 Pc3 Pd4 Pe4 Pf3 Pg2 Ph2

// Exact pawn structure, including flipped positions
cql() flipcolor { Pa2 Pb2 Pc3 Pd4 Pe4 Pf3 Pg2 Ph2 }

// Exact pawn structure, but pawn on c2
cql() Pa2 Pb2 Pc2 Pd4 Pe4 Pf3 Pg2 Ph2

// Exact pawn structure, but pawn on f2
cql() Pa2 Pb2 Pc3 Pd4 Pe4 Pf2 Pg2 Ph2

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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