I personally believe that the basis of the belief in deities of any sort comes from the human desire to have an explanation for everything. In many of the ancient polytheistic religions, if something could not be explained using the current available sciences or technologies, it was assumed to be an act of the gods, hence, we had gods who threw lightning bolts, controlled the weather, pulled the sun across the sky, and determined who got to look pretty and who got beat with the ugly stick. Now that we've figured out that lightning is caused by electric charges, the weather is variant on gravitational pulls and solar energy, that the earth revolves around the sun, and that our appearance is determined by genetics, the only unknowns left are how the universe was created, if there is an afterlife, and how did humans come to be, although Darwin seemed to figure out the last one with convincing evidence. To solve these problems, we have a god who created the universe in seven days, a heaven and a hell, and Adam and Eve. However, what lies to be determined is how God came to be. Even knowing this, many still choose to believe because of "Pascal's wager," which basically says that if a person believes in God, and God exists, then one will go to heaven; if one believes in God, and God doesn't exist, then that person is denied only a few worldly pleasures that they could have had; if one does not believe in God, and God doesn't exist, then that person will simply have led a life of pleasure and enjoyment; if one does not believe in God, and God does exist, then that person is sentenced to eternal damnation. When thought about in this light, the choice seems quite obvious, hence why ninety-something percent of people believe in one religion or the other. The only question left is this: what happens to those who believe in God, but only because they believe in Pascal's wager?