The murder of their family by Muzan Kibutsuji, the King of Demons, and the subsequent abandonment of Nezuko to become a demon, eternally altered the lives of Tanjiro and Nezuko Kamado. As Demon Slayer progresses, it becomes evident that Muzan's objective is to overcome his sensitivity to sunlight, one of the few disadvantages a demon possesses, in order to become the greatest demon. But why Muzan transformed Nezuko into a demon is still a mystery to lots of admirers.
It is obvious to everyone who comes into contact with her that Nezuko is not your typical demon, but did Muzan have any way of knowing this when he decided to change her? Was his attack motivated by the Kamados' connections to Yoriichi Tsukiguni, or was it just pure coincidence that misfortune befell the Kamados and Nezuko would later develop into such a terrible foe?
Nezuko: How Did She Become a Demon?
Readers of the Demon Slayer manga might assume that Nezuko's transformation into a demon is due to the relationship between the Kamados and Yoriichi Tsugikuni. The Sun Breathing style was created by Yoriichi, who was also the mastermind behind the other Breathing Styles employed by Demon Slayers. With the technique, he came dangerously close to killing Muzan, prompting the latter to spend years tracking down anyone who had encountered the method so that it could never again be used against him.
The manga leads fans to believe there might be a familial connection to Yoriichi, only to show that he had just spent time with the Kamado ancestors during his travels. While the Kamados had no demon slayers in their family, through Tanjiro's memories it's shown how the Hinokami Kagura dance that his father passed down evolved from the basic tenets of the Sun Breathing style. However, Muzan may have tracked them down; it seems possible that his fear of Yoriichi's legacy would drive him to eventually kill the Kamados -- but would not necessarily explain why Nezuko, or any Kamado, would be turned into a demon.
Becoming a demon is no accident and -- outside of Lady Tamayo -- only Muzan has the power capable of creating demons. Because each new demon born is a deliberate act on his part, what made Nezuko stand out as a candidate? So far, the Demon Slayer anime has made no allusions as to a reason, but the answer is ultimately revealed at the end of the manga's "Swordsmith Village Arc," and again in its final arc.
It might've appeared random that Nezuko would be turned into a demon, as she's nothing more than a child in a poor family in the mountains. While such a tragic circumstance could drive her to willingly accept the transformation -- as has been shown by demons like Rui, Daki and Gyutaro -- her becoming a demon is surprisingly coincidental. Muzan simply creates demons in the hopes that one will be created with the power that he seeks: immunity to the sun.
Even the most resilient demons that manage to survive and join the Twelve Kizuki lack the talent that would grant Muzan absolute power if he were to consume them. There is no evidence that Muzan had any means of knowing if Nezuko would live, much less develop into the special demon that she is. Nezuko was ultimately nothing more than a random casualty in Muzan's quest for dominance. Every demon he creates is effectively an experiment for him, and even those that succeed but lack immunity to the light still represent a setback in terms of his ultimate objective.
Since Nezuko was another one of Muzan's experiments, her transformation into a demon was theoretically planned, but everyone was shocked at the kind of monster she would become. Nezuko's will powers her development into an outstanding demon, much to how Tanjiro has continued to overcome obstacles in his career as a demon slayer via pure willpower. One of Muzan's worst errors is his choice to use her transformation into a demon for his own gain.