Based on a number of studies, belief in heaven is evidently bad for society. Belief in hell, OTOH, seems to be a deterrent to bad behavior. From the world wide web:
In a 2012 study (Shariff and Rhemtulla) examined national rates of belief in heaven and hell for 67 countries, as measured by five waves of the World Values Surveys and the European Values Surveys between 1981 and 2007. Shariff and Rhemtulla then drew crime statistics from the United Nations Office on Drugs and Crime (UNODC), which provided data on a litany of nasty things people can do to each other: homicides, robbery, rape, kidnapping, assault, theft, drug crime, automobile theft, burglary, and human trafficking.
With other factors controlled for – including national GDP and Gini coefficient, which measures income inequality – countries where more people believed in hell showed significantly lower levels of crime. The effect sizes were big:
Controlling for the effect of belief in heaven, a 1-[standard deviation] increase in belief in hell resulted in an almost 2 SD decrease in national crime rate; conversely, controlling for the effect of hell, a 1 SD increase in belief in heaven resulted in an almost 2 SD increase in national crime rate.
Fearing the imminent wrath of a judging God, it seems, makes you a lot less likely to steal, cheat, or murder – whereas a friendly, forgiving God (apparently) may inspire you to go easy on yourself, and possibly do bad things with the expectation of being forgiven.
Shariff, together with Lara B. Aknin, explored this possibility in a second study, published in 2014 in PLOSOne, in which they looked at the effect of heaven and hell beliefs on personal happiness.
At the societal level, belief in hell seems to perform some important behavioral corralling – by infusing the culture with a sort of generalized ambience of supernatural punishment, it inspires (or frightens) people into shaping up, toeing the line, and playing by the rules. But this fear of God isn’t so great for people at the individual level. Plenty of other research, particularly in religion and mental health, has shown that a loving, forgiving God is psychologically better for you than belief in a punitive and angry one. But that same forgiving God may give people a subconscious license to do less-than-honorable things, because, hey – God forgives!