All first-years at Hogwarts must take seven subjects: Transfiguration, Charms, Potions, History of Magic, Defence Against the Dark Arts, Astronomy and Herbology. Flying lessons (on broomsticks) are also compulsory.
At the end of their second year at Hogwarts, students are required to choose a minimum of two more subjects from the following list: Arithmancy, Muggle Studies, Divination, Study of Ancient Runes and Care of Magical Creatures.
Very specialised subjects such as Alchemy are sometimes offered in the final two years, if there is sufficient demand.
A slightly different list of school subjects appears in my earliest notes. Herbology is called ‘Herbalism’, Divination is compulsory from the first year, as are Alchemy and a subject called simply ‘Beasts’, whereas Transfiguration is called ‘Transfiguration/Metamorphosis’.