Voldemort desired to fracture his soul into seven pieces in Harry Potter, and this number was chosen for a particular purpose. The Dark Lord's central goal throughout the series was to make himself immortal, and since no one else in the wizarding world had ever achieved this, he had to get creative to make it happen. He decided to go the Horcrux route, and with the help of the magical study of Arithmancy, Voldemort believed he had found a way to improve the concept of splitting the soul to avoid death. Unfortunately for him, Voldemort made an error in his calculations, leading to his downfall.
In Harry Potter and the Half-Blood Prince, Harry and Dumbledore witnessed a memory in which a young Tom Riddle asked Horace Slughorn what would happen if he split his soul into seven pieces. He stated that seven was "the most powerfully magical number," which led him to believe that this specific number would somehow improve the efficacy of Horcruxes. Still, the Harry Potter books and movies never overtly stated why this was or how the number of Voldemort's Horcruxes benefitted (or hindered) his plans. Still, when diving into the more nuanced aspects of magic in the Harry Potter series, the answer becomes clear.
Wizarding Arithmancy Reveals The Number Seven To Be Magically Powerful
Arithmancy, the study of the magical properties of numbers, was a branch of magic that wasn't often discussed in Harry Potter, but its presence throughout the series was surprisingly profound. One of the most famous Arithmancers mentioned in Harry Potter lore is Bridget Wenlock, a witch who wrote a theorem on the magical and protective properties of the number seven. This is what young Tom Riddle was talking about when he stated that seven soul fragments would surely be more powerful than any other quantity.
Still, there was never any mention in Harry Potter about precisely what the number seven achieves. Wenlock's theorem was never explained in detail, and since Voldemort didn't want Slughorn to know what he was planning, he didn't go into much more detail. Still, given the fact that splitting the soul into so many pieces makes a wizard vulnerable—and ing how confident Voldemort was in his Horcruxes in Harry Potter and the Deathly Hallows—it can be deduced that Voldemort believed that the power of seven would stabilize his mutilated soul.
Seven Soul Fragments (Six Total Horcruxes) Would Have Made Voldemort Invincible
A common misconception among Harry Potter fans is that Voldemort sought to make seven Horcruxes. However, as Dumbledore clarified in Harry Potter and the Half-Blood Prince, the Dark Lord desired to create six Horcruxes, so seven total soul fragments. The seventh piece would, as Dumbledore said, "[reside] inside his regenerated body" and would be "the last that anybody wishing to kill Voldemort must attack."
The idea of Horcruxes is that if a wizard were to split his soul and store it away before his body was killed, the fragment of his soul would be tethered to the world of the living. The implication is that a soul can only move to the afterlife if it is whole. So, if a piece were to stay behind, the rest would be stuck. Having even one Horcrux ensured that Voldemort couldn't be forced to move into the afterlife. However, this wasn't enough for him. The Dark Lord wanted true immortality, and he believed the number seven was the way to achieve this.
What would have happened to Voldemort if he had successfully maintained six Horcruxes is unclear. It's possible that, with the protective power of the number seven, his individual Horcruxes would have been indestructible, even to the Sword of Gryffindor. Or, it could be that with a seven-piece soul, Voldemort's body wouldn't have aged and would have been stronger as well, which was why Voldemort believed himself in Harry Potter to be truly immortal after his regeneration. It's possible that Voldemort himself wasn't sure how the quantity of seven would protect him, and he never found out since he accidentally created one too many Horcruxes.
Voldemort Accidentally Ripped His Soul Into Eight Pieces In Harry Potter
Voldemort made two of his Horcruxes—the diary and Peverell ring—while he was still in school and turned Ravenclaw's diadem, Slytherin's locked, and Hufflepuff's cup into Horcruxes in the years that followed. This meant he had five Horcruxes, so the soul in his body was effectively tethered to earth, but he did not yet have the invincibility that six Horcruxes would give him. However, after he heard the Chosen One prophecy mentioned in Harry Potter, he developed a plan to create his sixth and final Horcrux, therefore finalizing his immortality. Or, at least, this is what Dumbledore hypothesized in Harry Potter and the Half-Blood Prince:
"Voldemort was still at least one Horcrux short of his goal of six when he entered your parents' house with the intention of killing you. He seemed to have reserved the process of making Horcruxes for particularly significant deaths. You would certainly have been that. He believed that in killing you, he was destroying the danger the prophecy had outlined. He believed he was making himself invincible. I am sure that he was intending to make his final Horcrux with your death." - Dumbledore, Harry Potter and the Half-Blood Prince
Voldemort entered the Potter home to murder Harry and used his death to create his sixth Horcrux. Of course, things didn't go to plan. Harry wasn't killed, and Voldemort's vulnerable body was destroyed (and his soul left to a spectral existence thanks to the existing Horcruxes). However, though Voldemort didn't know it, he technically did create his sixth Horcrux that night. The Dark Lord's soul was split, and a part of it was stored within the infant Harry.
If Voldemort had done nothing aside from regenerating his body and getting back to his mission to rule the wizarding world in Harry Potter, he might have found himself to have accidentally achieved immortality. However, after Peter Pettigrew found him in Albania at the end of Harry Potter and the Prisoner of Azkaban, Voldemort hurriedly turned his snake, Nagini, into a Horcrux, believing she was the final step toward his goal. He didn't realize that he had just split his soul into eight pieces—forgoing the protection of seven and setting himself up to be defeated by Harry Potter.
How The Number Seven Was Significant Throughout Harry Potter
Though it wasn't revealed to be powerful until Half-Blood Prince, the number seven was everywhere in Harry Potter. Of course, students attend Hogwarts for seven years (which is reflected by the seven Harry Potter books), and witches and wizards are considered adults at 17 (rather than 18). Magical children are supposed to show signs of their talents by the time they are seven years old, Quidditch teams have seven players (with the Seeker being number 7), and Hogwarts Castle has seven floors (and, no surprise, the seventh floor is the home of the Arithmancy classroom).
Overall, the word "seven" or "seventh" appears in the Harry Potter books 159 times—a little too much to have resulted from luck. It's clear that the series was secretly building up this number to have significance and just as secretly made it a major part of the reason for Harry's victory over Voldemort. Seven soul fragments would have been the Dark Lord's salvation, but seven Horcruxes was exactly what the Boy Who Lived needed in Harry Potter to tip the scales in his favor.