I already mentioned this as a comment to another post, but it’s worth repeating here: The human brain has evolved some “dedicated hardware” for accelerating certain tasks.
I already mentioned in that other post that one such hardware was for recognizing faces, and that false-positives generated by this hardware caused us have a feeling of hauntedness and ghosts (because the brain receives a subconscious signal indicating the presence of a face, but consciously looking around we see no one around).
Another such hardware (which I only briefly alluded to in the other post) was “agency detection”. I.e. trying to figure out whether a certain event occurred “naturally”, or because another agent (a friend, a foe, or a neutral?) caused it to happen. False positives from this hardware would cause us to “detect agency” where none was, and if the event seems something way out of the capacity for a human to control, and since humans seem to be the most powerful “natural” beings in the universe, the agent in question must be something supernatural, like God.
I don’t have all the details worked out, but it seems plausible that agency-detection could have been naturally selected for, perhaps to be able to integrate better into a society, and to help with knowing when it is appropriate to cooperate and when it is appropriate to defect. It’s a useful skill to be able to differentiate between “something good happened to me, because this person wanted something good to happen to me and made it happen. They cooperated (successfully). I should become their friend.” versus “something good happened to me, despite this person wanting something bad to happen to me, but it backfired on them. They defected (unsuccessfully). I should be wary of them.”
From there, bring in Anna Salamon and Steve Rayhawkideas about tag-along selection, and it seems like religion really may be a tag-along evolutionary attribute.
Anyway, I used to be scared of ghosts and the dark and stuff like that, but once I found out about the face-recognition hardware and its false positives (and other hardware, such as sound-location) this fear has almost completely disappeared almost instantaneously.
I was already atheist or agnostic (depending on what definitions you assign to those words) when I found out about the hardware false-positives, so I can’t say for sure whether had I been religious, this would have converted me.
But if it worked at making me stop “believing”[1] in ghosts, then perhaps it could work at making people stop beliving in God as well.
1: Here I am using the term “believe” in the sense of Yvain’s post on haunted rationalists. Like everyone else, I would assert that ghosts didn’t really exist, and would be willing to make a wager that they didn’t exist. And yet, like everyone else, I was still scared of them.
This might be done by picking an arbitrary genie, and then modifying your judgement criteria to match that genie’s.