The solar system has been in existence for about 4.5 billion years, we believe. But there is NO WAY that a comet can survive for 4.5 billion years if it is diving into the inner solar system every few millennia and boiling off some of its volatile gasses. And yet, we still have comets.
In 1950, the Dutch astronomer Jan Oort proposed the idea that there must be a reservoir of comet-like objects orbiting very far from the Sun, and only occasionally does something perturb a few of these bodies and drop them into the inner solar system as comets. Oort's hypothesis was that there must be a shell or "cloud" of frozen comet nuclei way out beyond the planets, from 2000 to 50,000 AU from the Sun. Occasionally, because of gravitational perturbations between these objects or with the Sun or other stars or other stars in the galaxy, one or a few of these would be nudged into orbits that took them deeper into the solar system.
We do not have any evidence that the Oort Cloud actually exists; it is too far away, and the objects believed to be there are too small and dark to be observed even with the largest telescopes. But the idea makes sense, because if there isn't something like the Oort Cloud around the solar system, why are we still seeing comets?