I've never been into religion, and don't believe in it, but I understand the basis and principles of where it comes from. Here is my 2 cents: (this is my opinion, and although I might sound like Im confident of the following theory (because I am), you are of course entitled to believe and express a difference in opinion, and I will respect it).
In the ancient times mankind was notoriously brutal, greedy and sinful (we know this by looking into Medieval times, Roman era, Egyptian, etc.). The good people who existed sought peace, and hope to live through life without such violence and crimes. So, religion was created, as a way to "moderate" society and give hope to the people.
In most religions two forms of an afterlife generally exist, from that most of us know as heaven and hell. The depiction of hell was so engraved in teachings and church as the worst place anyone could ever imagine, for example the book Dante's Inferno, that it set concrete morals in the mind of people to rid themselves of committing sins and to behave in society. Heaven was described as purely paradise, but could only be accessed after death if one was pure and ridden of evil sins, so this controlled society to be less criminal as well.
That's my perception on religion, mainly just a way to control society from immoral criminal actions, and give people faith and hope of a successful life if they do no sins and acknowledge god.
Of course today we don't have a perfect world ridden from immoralities, but as religion progressed and spread throughout the course of history, society has become much more civilized.
So those of us who don't believe in religion, we do have reason to be thankful for its existence, and not living in a corrupted world like the Dark Ages.
Now, though, I believe society is to an extent where we can back off from religious affiliations due to our well adaptation of principles and good morals brought by religion, but this wont take into effect for who knows how long, if ever.
Sorry if this seems lengthy, I get into debates all too well, being we have very mature debates (on politics, etc.) held at my forum all the time, just filled with lengthy opinions.