Nobody knows. What we do know is that the tradition can be traced back to 18th-century Germany, where a child's birthday party (called a Kinderfest) resembled a modern one.
Putting candles in cakes started as birthday offerings for the Goddess Artemis in ancient Greece. It's believed that blowing them out sends your wish to the heavens.
The Germans placed large candles in their cakes to represent the light of life and believed the smoke from blowing it out carried their wishes to the gods
The 18th century in Germany is where the Western tradition of adding birthday candles to a birthday cake began. But the mixing of cakes and birthday celebrations dates back to the Ancient Romans.