Note: we won’t be counting Dolores Umbridge’s several Educational Decrees, because those were just ridiculous.
The International Statute of Secrecy must be abided
The main law of magic in the wizarding world is the obvious one: don’t perform it in front of the Muggles! It’s sad that things came to this, but the International Statute of Secrecy is steeped in a chequered history - with events such as the Salem Witch Trials and various other hostile acts leading to this golden rule being decreed in 1692. Naturally, it’s been breached several times in the ensuing centuries - with various degrees of seriousness.

While Harry and Ron flying a car across the UK (in clear view of Muggles) had them losing house points and receiving detentions and Howlers, adult wizards and witches risk getting arrested, depending on the severity of the exposure. In Fantastic Beasts and Where to Find Them, Newt had to help MACUSA erase the memories of the whole of New York City following the devastation caused by Credence’s Obscurus.
In fact, America’s secrecy laws were all the more severe in general – with Rappaport’s Law stating that magical people couldn’t marry No Majs. In Europe, mixed-magical relationships are legal, albeit subject to prejudice from more close-minded people.
You can’t use magic outside of Hogwarts until you come of age
Any witches or wizards under the age of 17 must live with the uncharted frustration of not being able to perform magic outside of school, unless there are extenuating circumstances. If you’re with a grown-up witch or wizard, you can sometimes piggy-back off their magic – such as if you need to Apparate somewhere, but ultimately, it’s a dull life of washing the dishes by hand until that special birthday comes about.
Harry nearly getting expelled by the Ministry of Magic in his fifth year for using the Patronus Charm in front of Dudley doesn’t really count – seeing as there was meddling behind the scenes going on there.
You can’t magically create food

He’s been providing us with food, because for some reason, that’s the one thing the Room doesn’t really do.’ ‘Yeah, well, food’s one of the five exceptions to Gamp’s Law of Elemental Transfiguration,’ said Ron, to general astonishment.
Harry Potter and the Deathly Hallows
Probably the most frustrating magical rule of all: you can’t conjure up food from scratch. Sure, you can summon it to you, or Apparate to the nearest greasy spoon, but you can’t make it from thin air, sadly. This is the first of the five Principal Exceptions to Gamp’s Law of Elemental Transfiguration, as Hermione would tell you.
This means the Room of Requirement can’t suddenly turn into a restaurant – no matter how much you require it. The closest we came to seeing food magically appear were the enchanted plates from the Yule Ball, but we can assume some sort of fancy Summoning Charm was put on those.
Playing with life and death will warrant dark consequences
You all should know this one well by now – death and magic is not a pleasant mix. Please note the entire arc of Lord Voldemort for further details. Early on, Harry learns that ‘no spell can reawaken the dead’, although there are many loopholes – such as ghosts, Inferi, the Philosopher’s Stone and the Resurrection Stone, and being able to live on through a version of yourself inside paintings.
But Lord Voldemort goes beyond this – delving into the most despicable ways of magically extending your life – such as drinking unicorn blood and making Horcruxes through murder. Voldemort pays the ultimate price for his actions – and it goes far beyond being locked up in Azkaban.
If you become an Animagus, you have to get a license

Transforming into an animal is perhaps one of the most enviable magical skills out there – but it’s very hard, and you have to be registered if you can do it. Imagine if everyone just became an Animagus without people knowing – there’d be a lot of funny-behaving cats and dogs hanging around.
Upon discovering Rita Skeeter is an unregistered Animagus, Hermione was able to blackmail her, as she was getting her Daily Prophet stories by illegal means (ie: eavesdropping on people as a beetle) As for the Marauders, Sirius Black, James Potter and Peter Pettigrew were all unregistered Animagi too – as they did it to secretly help accompany Remus Lupin during his werewolf transformations. Of course, Peter Pettigrew ended up becoming a rat for other reasons later on in life...
PS: If you've ever wondered how to become an Animagus, you can discover so here.
And if you’re American, you would’ve needed a wand permit

At the end of the nineteenth century, American witches and wizards were required to carry wand permits, so magical activity could be tracked. And the American wizarding laws at the time were pretty dire: while European wizards went to Azkaban, American wizardkind could risk execution.
The Unforgivable Curses are illegal, obviously

We’re sure you probably knew this, but yep. Avada Kedavra, (the Killing Curse) Crucio (the Cruciatus Curse) and Imperio (the Imperius Curse) are very illegal and would lead to a life sentence in Azkaban if caught using one against another. So Mad-Eye Moody (or should we say, Barty Crouch Jr.) teaching a class of fourth-years (with an engorged spider of all things!) about them was obviously pretty troubling to say the least.
During the wizarding wars, this rule became hazy, with Aurors permitted to use them against Dark forces, and during Voldemort’s ascent, legalised once he had taken over the Ministry. Thankfully, that era didn’t last too long.
And looking after certain fantastic beasts is also... frowned upon

Of course, spells aren’t the only dangerous things to keep an eye on. Think of Newt Scamander, who has seen his fair share of trouble for carrying around perilous magical creatures – or Hagrid, who was expelled (wrongly) for keeping Aragog the Acromantula on school grounds.
You’d think Hagrid would’ve learnt his lesson, but of course he didn’t – he still thought it was a great idea to keep an illegal dragon (Norbert the Norwegian Ridgeback) in a wooden hut many years later. Oh Hagrid, we still love you.