There is plenty to criticise in Islam's view of women. Last year, the Observer told the story of a man in Basra who stamped on, suffocated and then stabbed to death his 17-year-old daughter for becoming infatuated with a British soldier. The relationship apparently amounted to a few conversations, but her father learnt she had been seen in public talking to the soldier. When the Observer talked to Abdel-Qader Ali two weeks later, he said: "Death was the least she deserved. I don't regret it. I had the support of all my friends who are fathers, like me, and know what she did was unacceptable to any Muslim that honours his religion."

This was clearly extreme, but the truth is that the God many people believe in - whether Muslim, Christian or Jewish - hates women. Take America's Southern Baptist Convention, which declares in its faith and mission statement: "A wife is to submit herself graciously to the servant leadership of her husband." That's fair enough, isn't it? After all, he's probably stronger than she is.

Or there's the Catholic church. The Pope put things more suavely in an address in 2008: "Faced with cultural and political trends that seek to eliminate, or at least cloud and confuse, the sexual differences inscribed in human nature, considering them a cultural construct, it is necessary to recall God's design that created the human being masculine and feminine, with a unity and at the same time an original difference." The insistence on difference is the necessary first step to insisting on inequality and subordination and it is a step that popes have been taking at regular intervals for decades.

In November 2006, Nicaragua enacted a ban on all abortion, with no exceptions, even to save the mother's life. The law was ratified by the National Assembly in September 2007. Both the original enactment and the vote in September 2007 were widely attributed to the influence of the Catholic church. In a report this month, the United Nations Committee against torture called Nicaragua's total ban on abortion a violation of human rights.

Then there is Judaism. In one neighbourhood in Jerusalem, religious seminaries flank streets with yellow signs that warn: "If you're a woman and you're not properly dressed - don't pass through our neighbourhood."

So why is it so often women who fill the pews? Is it a form of Stockholm syndrome? Religions do a good job of training people to be obedient and loyal to the authorities and women in particular are raised to be both devout and submissive. Religions are sticky: they are hard to abandon and that is doubly true for women, given that subordination and unshakable fidelity are their chief duties.

The fact that women are defined as different from men ("complementary" is the religious euphemism) and confined to narrower, more monotonous lives as a result, means that they have more need of the excitements and passions of religion. For women, religion often is the heart of a heartless world. All they have to give up in exchange is their right to shape their own lives; as long as they behave themselves, all will go swimmingly.

The intimate and inescapable connection that contemporary liberal believers like to see between God and love, theism and compassion, is largely a modern invention. It's far from universal now and it was vanishingly rare in the past. St Francis was an eccentric, not an exemplar. The painful truth is that still, to this day, most people who believe in a god believe in a god who is often vindictive, punitive and sometimes just plain cruel. The Ryan report on abuse of children in Irish industrial schools, released two weeks ago, provides a mountain of searing evidence for that. For decade after decade, generation upon generation, the religious congregations in charge of the institutions saw nothing wrong.

One survivor of Goldenbridge, the most notorious industrial school for girls, run by the Sisters of Mercy, told the commission: "The screaming of children will stay with me for the rest of my life about Goldenbridge. I still hear it, I still haven't recovered from that. Children crying and screaming, it was just endless, it never, never stopped for years in that place." Many of those children were there simply because their mothers were unmarried or divorced.

The God we have in the Big Three monotheisms is a God who originated in a period when male superiority was absolutely taken for granted. That time has passed, but the superior male God remains and that God holds women in contempt. That God is the one who puts "His" imprimatur on all those tyrannical laws. That God is a product of history, but taken to be eternal, which is a bad combination. That is the God who hates women.

So why do so many women put up with it? Partly because God gives with one hand what "He" takes away with the other - God consoles people for the very harshness that God creates. It's the sad, familiar, heartrending bargain in which the victim embraces the perpetrator, in some complicated, confusing, all-too-human mix of appeasement, need and stubborn loyalty. The fact that the embrace is all on one side is resolutely ignored.

• Does God Hate Women? by Ophelia Benson and Jeremy Stangroom is published by Continuum on June 4