Lichess Analysis!

Lichess is a free and open-source internet chess server run by a non-profit of the same name. Lichess and all of its features (chess puzzles, computer analysis, tournaments, and chess variants) are free and ad-free. Lichess has a large community of players; in January 2023, according to their own tweet, they had...

Unlike closed-source alternatives, Lichess publishes all standard rated games from its platform to the Lichess database, making them readily available. By the time of writing this blog post, there are 6,488,488,455 standard rated games, played on lichess.org, in PGN format.

In this blog post, I analyzed lichess Rated Blitz Games from 2024-01 to 2024-05, totatling 201,791,204 PGNs. And I wanted to answer some fun questions about chess. I opted to utilize high rating games (both players above 2,000 ELO) to make the below illustrations.

Riskiest Square

Playing as white, if the white king was under check what is the percentage the king is on a given square?

Deadliest Square

Playing as white, if your piece where to be captured, what is the percentage they met their end on a given square?

Promotion Square

Playing as white, if your pawn where to be promoted, what is the percentage its on a given column?

Motivation

I had fun doing this project and I was using C to read and process the data. It took 38 minutes of compute time to read and process 153 GB of compressed Lichess data (or about 1.09 TB of uncompressed data). The code for this is available on my github.