Ancient religions had gods that weren’t moral. Their gods were ritualistic and hardly spiritual. A change occured between 500-300 B.C. across Eurasia, Greece and China where religions suddenly began to practice self-restraint and prayer. German philosopher Karl Jaspens calls this the “Axial Age”.
Psychologists have found that the shift was due to increased resources. Fewer resources caused people to focus on the present, whereas more wealth results in the forgoing of instant gratification and looking to the future.
Some historians however are skeptical of the findings. British Columbia University Historian Edward Slingerland believes that the size and complexity of a given society influenced its values and beliefs. He believes that as people find themselves needing to cooperate with more strangers beliefs in a higher god ensue so that morality can smooth new interactions and contribute to the success of the culture.