Hogwarts Legacy takes place in the late 1800s, specifically in 1890, which is a century before the events chronicled in the Harry Potter novels. This means that the game is set 90 years before Harry Potter is born. The player controls a student enrolled in the Hogwarts School of Witchcraft and Wizardry who learns to wield an array of magical abilities and objects. The game takes place in several Wizarding World locations such as Hogwarts castle, Hogsmeade, and the Scottish Highlands. The player character possesses the power to control a mysterious ancient magic and holds the key to an "ancient secret" that threatens the stability of the wizarding world.