Why Was Jesus Represented as Being Born in a Cave? I'm wondering why Jesus's birth/Nativity started being represented as occurring in a cave, as opposed to some structure having a manger in it (Luke) or the family home (Matthew). 

This first occurred in the Protoevangelium of James, and the motif then appeared in Justin Martyr (Trypho 78) and Origen (Celsus 1.51). Inevitably a cave in Bethlehem was found, over which the Empress Helena with Constantine then built the Church of the Nativity ca. 327 CE. The cave became the standard Nativity site in Orthodox Christianity, while in the West the cave motif stood alongside Luke's and Matthew's accounts and was often depicted in art. 

My question is why did this motif arise in the first place? 

The possibilities include: Competition with Mithraism or with other mystery religions in which rites were conducted in cavelike structures, or with other pagan deities/heroes born in caves? Simple reliance on Isaiah 33:15-16 (Septuagint version) as per Justin? Prefiguring Jesus's eventual entombment (also descent to hell)? An allusion to Christians using caves and catacombs? Simple assumption since in Palestine caves were sometimes used as stables and so could contain a manger (but funny that Luke didn't mention the cave, and why overtly contradict Matthew)? Or is it just general symbolism for caves found in myths (dark primordial state where creation including light occurs (here that of the new era), the womb, place of transformation, etc.)? Something else?
Some scholars argue that it was common for a house at the time to have a basement-cave serving as stables
This interpretation would say that Jesus was always represented as being born in a cave because it being part of a house was the typical arrangement at the time, and so we assume that's what actually happened. Thus there is no conflict with an interpretation of Matthew 2:11 saying that it refers to the house Jesus was born in (although he was likely moved from the cave to the living area of the house by the time the Magi arrived) or Luke's description of a manger but not a cave since he didn't see the need to comment on something that was commonplace.
Nazareth Village is a historical reenactment site in Israel that includes &quot;a carefully researched re-creation of Jesus hometown&quot; as it appeared in his time, including houses with this arrangement. Claire Pfann, Assistant Dean for Academic Affairs at the University of the Holy Land, talked about the Nativity while going through the village with a reporter. After Pfann argues that Mary and Joseph would have been expected to stay with family and that the word for &quot;inn&quot; can also be translated as &quot;guest room&quot;, the reporter summarizes her explanations of the cave as follows:

Downstairs, the courtyard led to a room in the basement, which was really a 'cave' dug out of soft limestone. That room was used for storage. Nearby outside the housewife would be sieving grain. The families kept large jars of olive oil and wine in the cave. There were stacks of wheat and grain, too. [...]
The family would bring their prized animals inside for protection and lead them into the basement cave where they would eat from the feeding trough-a manger.
Jesus could have been born in a room like the basement 'cave', then wrapped in swaddling clothes and placed in the manger, as is written in the gospel of Luke. The animals would have been moved out, and clean hay laid down. Some of the women, midwives who were experienced in delivering babies would have come down here to help Mary.

In other words, Pfann's argument is that with a house full of family in town for the census, the only place to have enough space to deliver a baby was the basement-cave where animals, and the manger where they ate from, would have been.
It's worth noting that even in the modern era, there are still people who live in caves in Palestine and other areas of the Middle East and also use part of it for livestock.
So from this argument, some scholars would say that the answer to &quot;why was Jesus represented as being born in a cave?&quot; is that he actually was, although not the sort of cave we might think of today.
There is also scholarly support for the cave of Jesus' birth being the same cave below the Church of the Nativity
Professor Qustandi Shomali of Bethlehem University states that the cave that is now under the Church of the Nativity was recognized shortly after Jesus' ministry as his birthplace:

&quot;We do know that the identification of the site where Jesus was born already traditionally goes back to the middle of the first century at least,&quot; Shomali said.

Stephen Pfann, also of the University of the Holy Land (and I assume some relation to Claire Pfann above), corroborates Shomali's statement.

&quot;Around what was left of the house which was only a cave where the virgin gave birth to the Child,&quot; said Stephen Pfann of the University of the Holy Land. &quot;People remembered this. People within 15 years were already going back to that site to visit it.&quot;

Naturally, the news article with these quotes doesn't cite the historical sources that led the professors to this conclusion (that's not what the article is about), but I'll give them the benefit of the doubt that they came to this conclusion through research and not unfounded speculation. Still, it may be worth looking up their work or contacting them directly if you'd like to know more about how they came to that understanding.