The proof of the stability of the solar system has been customarily presented as the solution of a great riddle originated by Newton and completed by Laplace. In this paper, I suggest a different narrative. I argue that Newton considered the stability of the solar system more a theological problem than a physical one and that he never raised the question whether the system is stable or unstable. After the introduction of analytical techniques, astronomers and mathematicians, concerned especially with practical problems such as the behavior of the Moon and with the improvement of perturbation theory, also largely neglected the issue of stability. It was only in 1781, when the cultural and scientific conditions were ripe, that Lagrange, not Laplace, finally set and solved, according to the standard of the time, the stability problem.