The fictional sport played by Harry Potter and his classmates is Quidditch.
Quidditch is a broomstick sport in J.K. Rowling’s wizarding world. Two teams of seven players compete while flying around a pitch, trying to score with the Quaffle and prevent the opposing team from scoring. Three different kinds of balls are used: the Quaffle, two Bludgers and the Golden Snitch.
Each team has three Chasers, two Beaters, one Keeper and one Seeker. The Seeker’s main task is to catch the Golden Snitch, which traditionally ends the match and awards 150 points. Because catching the Snitch is so valuable, a team can catch it and still lose if its opponent has built a large enough lead.
Quidditch appears throughout the Harry Potter books and films, beginning with Harry’s first school match in Harry Potter and the Philosopher’s Stone. Rowling has said the game was partly inspired by ideas she developed after an argument with a boyfriend, although the sport’s rules and magical setting are fictional.