While Sahil Juneja's answer is great (I think it's an awesome look at some of the most powerful enchanted objects throughout the series!), I don't think it's necessarily the best answer to this question. The questioner asked for the most powerful "piece of magic performed" by anyone in the books, not the most powerful magic that exists in the books, so with that in mind, here's my suggestion as to the most powerful spell any character performs.
First, see Sahil's preface, since I think it's well written and still applies — it is hard to quantifiably say what is the "most powerful" of any magic performed, so I figured I'd list the most powerful spells cast that I can think of for each of the seven books (spoilers FYI).
Quirrell Jinxing Harry's Broom: During the first Quidditch game of the season, Quirinus Quirrell casts a powerful jinx on Harry's broom. In Hagrid's words, "Can't nothing interfere with a broomstick except powerful Dark magic - no kid could do that to a Nimbus Two Thousand. . ."
Lockhart's Memory Charm: Though its effects were perhaps not what was intended, Gilderoy Lockhart casts a memory charm upon himself so powerful that three years later, he still does not recall anything about himself or his life. Help is even apparently beyond the abilities of the best healers in the country (though he is at least starting to regain some of his lovely vain personality).
Expeeecto... Patroonuuuum!: Even by adult wizarding standards, the Patronus charm is considered an unusually difficult spell to perform, let alone master and use successfully against a swarm of dementors. Needless to say, Harry's fully-corporeal Patronus at the end of the third book is an undoubtedly powerful piece of magic. Not only does it have full effect from across a large lake ("time and space matter in magic," remember? but it successfully drives off a large swarm of dementors, saving Harry, Hermione, and Sirius' lives (well, souls).
Wormtail Reviving Voldemort: In the climactic semi-finale of the fourth book, Wormtail (Peter Pettigrew) performs an "old piece of Dark Magic" (Voldemort's words) to return his "Voldy" to a body.
I've got two here.
Hermione's Protean Charm: In order for [Dumbledore's Army] to be able to covertly communicate the times of future meetings, Hermione performs a Protean Charm on a set of fake galleons, causing them to all mimic the state of one "master" coin that Harry possesses. In the words of Ravenclaw Terry Boot, "That's N.E.W.T. standard, that is. . ."
Anything During the Voldemort/Dumbledore Duel: I figured I'd throw this one in there as well. During the insanely impressive duel between Voldemort and Dumbledore in the Ministry of Magic atrium, both wizards cast non-verbal spells the likes of which are rarely seen throughout the rest of the series. These guys are seriously good!
I've got a few for this one too.
Harry's Sectumsempra: During Harry and Draco's "bathroom duel" (snigger), Harry un-knowingly uses some very Dark Magic in an attempt to defend himself. The Sectumsempra spell, which Harry came across in the Half-Blood Prince's copy of Advanced Potion Making, inflicts serious, near-fatal wounds in anyone it is cast upon.
Dumbledore's Highly Intuitive Cave-Magic: While finding their way into the cave where Voldemort has hidden one of his Horcruxes, Dumbledore again shows his powerful knowledge of obscure and subtle magics, by finding first the doorway in and then the chain to draw the boat within the Horcrux cave, both without the use of his wand. Very little of this sort of magic is seen throughout the books.
Again, I ended up thinking of a few for this one.
Hermione's Undetectable Extension Charm: In preparation for their journey in search of the Horcruxes, Hermione casts this 'Mary-Poppin'-ish charm on her beaded bag, so as to allow the trio to easily travel with everything they need.
Professor McGonagall's Piertotum Locomotor: During the Battle of Hogwarts, Professor Minerva McGonagall casts a rather impressive piece of transfiguration upon the entire castle, causing all the statues, carvings, suits of armor and so forth to come to life and defend their castle ("I've always wanted to use that spell!")
Crabbe's Fiendfyre: Vincent Crabbe, showing a greater than expected level of spellcasting ability (though a true to character level of intelligence) tries to use the Dark, wildly dangerous Fiendfyre curse to smoke Harry, Ron, and Hermione out of the Room of Hidden Things. Needless to say, it does not work out well for him.
Bonus — The Unforgivables
Without a doubt some of the most powerful magic performed throughout the books are the three Unforgivable Curses:
Imperio: Controls people at your will.
Crucio: Inflicts unbearable pain on the person on which it is cast.
Avada Kedavra: The Killing Curse.
Bonus Bonus — Magic Cast Outside of the Books' Timeline
Voldemort Cursing the Defense Against the Dark Arts Job: As noted by the original questioner. This is an unknown and surprisingly powerful piece of magic which prevents anyone, throughout the entirety of time, from being able to even hold the position of Defense Against the Dark Arts teacher for longer than a year.
Death Creating the Hallows?: This one is sorta pushing it. The Deathly Hallows were theoretically created at some point in time by Death him(her?)self, though they just as likely were created by the exceptionally clever Peverell brothers instead. Either way, the spells required to make such objects are undoubtedly very powerful. This somewhat crosses the line into Sahil's answer, as it is partially referring to powerful enchanted objects as well as the spells used to create them.
Dumbledore's Gubraithian Fire: This one is sort of outside the books' timeline, as it takes place within the fifth book, but is never seen from a primary perspective within the story. Dumbledore creates a branch of Everlasting flames as a gift to the Gurg (chief) of the giants, which "isn' somethin' any wizard could do," according to Hagrid.
As a final addition to Sahil's awesome list of powerful enchanted objects, I figured I'd mention the Marauder's Map. It's an undoubtedly clever, powerful, and trickily enchanted magical object, and throughout wizarding history appears to be completely unique!
— Quora user Fateh Khalsa