Beatles Database

May 2025

My friend Hrothgar and I watched the excellent three-part Beatles documentary Get Back about the making of the album Let It Be. This inspired him to go through every (non-cover) Beatles song and note whether it was a love song. (Result: The first non-love song, Help!, appeared on their fifth album! See the full list.)

I then wanted to chart this against other attributes of their songs. I figured a comprehensive database of metadata about Beatles songs existed, but I couldn’t find one. Hrothgar and I decided to put one together.

We found five partial databases and wrote scripts to merge them into a single giant four megabyte JSON file. For each song the database includes straightforward things like which album it was on, when it was written and released, who wrote it, and who sang on it. It also includes subjective things like energy, valence, and acousticness, as well as musical things like what key and tempo it’s in. For many songs we have every chord and every section (intro, bridge, etc.) with timestamps, as well as orchestration details, like Across the Universe has three trumpets and three trombones, as well as 18 uncredited violins. If Wikipedia has a page about the song, we include a link to it.

One challenge was normalizing song names. For example, the song Mean Mr. Mustard was, in some databases, listed as Mean Mr Mustard (British spelling) and as Mean Mister Mustard. It’s sometimes not even clear what the definitive title should be!

Hrothgar also wrote a script to import all song lyrics, but we don’t check the lyrics into the GitHub repo for copyright reasons. You can run the script yourself if you need those.

It’s fun to graph various attributes. Early in their careers the songs had to fit on 45s, but later the band felt free to experiment with different durations:

They also seemed to become more perfectionists over time:

More charts here.

The source code is available on GitHub.

~ See all projects ~