We know from science that space and time had a beginning. Specifically, red shift, cosmic background radiation, Friedmann's solutions to Einstein's field equations, quantum mechanics, the First Law of Thermodynamics, the Second Law of Thermodynamics and Inflation Theory. If the universe is expanding then it must have a beginning. If you follow it backwards in time, then any object must come to a boundary of space time. You cannot continue that history indefinitely. This is still true even if a universe has periods of contraction. It still has to have a beginning if expansion over weights the contraction. Physicists have been uncomfortable with the idea of a beginning since the work of Friedman which showed that the solutions of Einstein's equation showed that the universe had a beginning.
Inflation Theory, the First Law of Thermodynamics and quantum mechanics tells us that it is possible for matter to have a beginning. In a closed universe the gravitational energy which is always negative exactly compensates the positive energy of matter. So the energy of a closed universe is always zero. So nothing prevents this universe from being spontaneously created. Because the net energy is always zero. The positive energy of matter is balanced by the negative energy of the gravity of that matter which is the space time curvature of that matter. There is no conservation law that prevents the formation of such a universe. In quantum mechanics if something is not forbidden by conservation laws, then it necessarily happens with some non-zero probability. So a closed universe can spontaneously appear - through the laws of quantum mechanics - out of nothing. And in fact there is an elegant mathematical description which describes this process and shows that a tiny closed universe having very high energy can spontaneously pop into existence and immediately start to expand and cool. In this description, the same laws that describe the evolution of the universe also describe the appearance of the universe which means that the laws were in place before the universe itself.