"Why atheism is winning is because when a belief structure has no empirical basis, it only survives by everyone agreeing to maintain the illusion that it makes sense. It is the emperor's new clothes syndrome. But such beliefs are highly prone to sudden collapse as soon as it begins to be pointed out that there is nothing there. Once a tipping point is reached, changes in unsupported beliefs (whether it be god or racism and homophobia) can occur very rapidly.
Religion is more tenacious but even there I think that the switch to largely disbelief will occur within a couple of generations (maybe an extra generation in the Islamic world) as people realize that religion is little more than superstition and lies at the heart of many problems. The communication revolution, in addition to spreading the ideas of modernity to an ever-widening audience, will create a greater awareness, especially among young people, that one's religious beliefs are largely a product of where one is born and brought up, and not because they are self-evidently true.. Once you give up the idea that your own religion is obviously true, it is a short step to not viewing religion as a source of truth at all.
On the level of simply ideas, religion is losing because fewer are converting into religion than are converting out, especially amongst the young. That is the demographic time bomb that is going to doom religion. It is what is also working against racism and anti-gay bigotry. Attitudes that have no empirical basis persist mainly because people 'inherit' it from their parents, in that children learn these things at an early age from their families. It is unlikely that someone who grows up in a family that is accepting of people of other races and gays will turn against those views, while the reverse happens more frequently as modernity expands."
from Dr. Mano Singham's blog on "Why atheism is winning".