Richard Dawkins has contacted the Guardian to strongly deny that he compared Roman Catholics to Nazis, rather he said that Hitler was a Roman Catholic. Here is a longer version of his speech, which has been edited by the Guardian subject to normal editorial constraints.

Should Joseph Ratzinger have been welcomed with all the pomp and ceremony due to a head of state? No. As Geoffrey Robertson has shown in The Case of the Pope, the Holy See's claim to statehood is founded on a Faustian deal in which Benito Mussolini handed over 1.2 square miles of central Rome in exchange for church support of his fascist regime. Our government chose the occasion of the pope's visit to announce their intention to "do God". As a friend remarked to me, presumably we should expect the imminent handover of Hyde Park to the Vatican, to clinch the deal?

Should Ratzinger, then, be welcomed as the head of a church? By all means, if individual Catholics wish to overlook his many transgressions and lay out the red carpet for his designer red shoes, let them do so. But don't ask the rest of us to pay. Don't ask the British taxpayer to subsidise the propaganda mission of an institution whose wealth is measured in the tens of billions: wealth for which the phrase "ill-gotten" might have been specifically coined. And spare us the nauseating spectacle of the Queen, the Duke of Edinburgh and assorted lord lieutenants and other dignitaries cringing and fawning sycophantically all over him as though he were somebody we should respect.

Benedict's predecessor, John Paul II, was respected by some as a saintly man. But nobody could call Benedict XVI saintly and keep a straight face. Whatever this leering old fixer may be, he is not saintly. Is he intellectual? Scholarly? That is often claimed, although it is far from clear what there is in theology to be scholarly about. Surely nothing to respect.

The unfortunate little fact that Ratzinger was in the Hitler Youth has been the subject of a widely observed moratorium. I've respected it myself, hitherto. But after the pope's outrageous speech in Edinburgh, blaming atheism for Adolf Hitler, one can't help feeling the gloves are off. Did you hear what he said?

"Even in our own lifetime, we can recall how Britain and her leaders stood against a Nazi tyranny that wished to eradicate God from society and denied our common humanity to many, especially the Jews … As we reflect on the sobering lessons of the atheist extremism of the 20th century …

You have to wonder about the PR skills of the advisers who let that paragraph through. Oh but of course, I was forgetting, his senior advisor is that cardinal who takes one look at the immigration officials at Heathrow and concludes that he must have landed in the third world. The poor man was no doubt prescribed a bushel of Hail Marys, on top of his swift attack of diplomatic gout – and one can't help wondering whether the afflicted foot was the one he puts in his mouth.

At first I was annoyed by the pope's disgraceful attack on atheists and secularists, but then I saw it as reassuring. It suggests that we have rattled them so much that they have to resort to insulting us, in a desperate attempt to divert attention from the child abuse scandal.

It probably is too harsh to expect the 14-year-old Ratzinger to have seen through the Nazis. As a devout Catholic, he would have had dinned into him, along with the Catechism, the obnoxious idea that all Jews are to be held responsible for killing Jesus – the "Christ-killer" libel – not repudiated until the Second Vatican Council (1962-1965). The German Roman Catholic psyche of the time was still shot through with the antisemitism of centuries.

Hitler was a Roman Catholic. Or at least he was as much a Roman Catholic as the 5 million so-called Roman Catholics in this country today. For Hitler never renounced his baptismal Catholicism, which was doubtless the criterion for counting the 5 million alleged British Catholics today. You cannot have it both ways. Either you have 5 million British Catholics, in which case you have to have Hitler, too. Or Hitler was not a Catholic, in which case you have to give us an honest figure for the number of genuine Catholics in Britain today – the number who really believe Jesus turns himself into a wafer, as the former Professor Ratzinger presumably does.

In any case, Hitler certainly was not an atheist. In 1933 he claimed to have "stamped atheism out", having banned most of Germany's atheist organisations, including the German Freethinkers League whose building was then turned into an information bureau for church affairs.

At very least, Hitler believed in a personified "Providence", presumably akin to the Divine Providence invoked by the Cardinal Archbishop of Munich in 1939, when Hitler escaped assassination and the cardinal ordered a special Te Deum in Munich Cathedral: "To thank Divine Providence in the name of the archdiocese for the Führer's fortunate escape."

We may never know whether Hitler identified his "Providence" with the cardinal's God. But he certainly knew his overwhelmingly Christian constituency, the millions of good Christian Germans with Gott mit uns on their belt buckles, who actually did his dirty work for him. He knew his support base. Hitler most certainly did "do God". Here's part of a speech he made in Munich, the heart of Catholic Bavaria, in 1922:

"My feeling as a Christian points me to my Lord and Saviour as a fighter. It points me to the man who once in loneliness, surrounded by a few followers, recognised these Jews for what they were and summoned men to fight against them and who – God's truth! – was greatest not as a sufferer but as a fighter. In boundless love as a Christian and as a man I read through the passage which tells us how the Lord at last rose in His might and seized the scourge to drive out of the temple the brood of vipers and adders. How terrific was his fight against the Jewish poison. Today, after 2,000 years, with deepest emotion I recognise more profoundly than ever before the fact that it was for this that He had to shed his blood upon the Cross."

That is just one of numerous speeches, and passages in Mein Kampf, where Hitler invoked his Christianity. No wonder he received such warm support from within the Catholic hierarchy of Germany. And Benedict's predecessor, Pius XII, is not guiltless, as the Catholic writer John Cornwell devastatingly showed, in his book Hitler's Pope.

It would be unkind to prolong this point, but Ratzinger's speech in Edinburgh on Thursday was so disgraceful, so hypocritical, so redolent of the sound of stones hurled from within a glass house, I felt that I had to reply.

Even if Hitler had been an atheist – as Joseph Stalin more surely was – how dare Ratzinger suggest that atheism has any connection whatsoever with their horrific deeds? Any more than Hitler and Stalin's non-belief in leprechauns or unicorns. Any more than their sporting of a moustache – along with Francisco Franco and Saddam Hussein. There is no logical pathway from atheism to wickedness.

Unless, that is, you are steeped in the vile obscenity at the heart of Catholic theology. I refer (and I am indebted to Paula Kirby for the point) to the doctrine of original sin. These people believe – and they teach this to tiny children, at the same time as they teach them the terrifying falsehood of hell – that every baby is "born in sin". That would be Adam's sin, by the way: Adam who, as they themselves now admit, never existed.

Original sin means that, from the moment we are born, we are wicked, corrupt, damned. Unless we believe in their God. Or unless we fall for the carrot of heaven and the stick of hell. That, ladies and gentleman, is the disgusting theory that leads them to presume that it was godlessness that made Hitler and Stalin the monsters that they were. We are all monsters unless redeemed by Jesus. What a vile, depraved, inhuman theory to base your life on.

Ratzinger is an enemy of humanity.

He is an enemy of children, whose bodies he has allowed to be abused and whose minds he has encouraged to be infected with guilt. It is embarrassingly clear that the church is less concerned with saving child bodies from abusers than with saving priestly souls from hell: and most concerned with saving the long-term reputation of the church itself.

He is an enemy of gay people, bestowing on them the sort of bigotry that his church used to reserve for Jews.

He is an enemy of women – barring them from the priesthood as though a penis were an essential tool for pastoral duties. What other employer is allowed to discriminate on grounds of sex, when filling a job that manifestly doesn't require physical strength or some other quality that only males might be thought to have?

He is an enemy of truth, promoting barefaced lies about condoms not protecting against Aids, especially in Africa.

He is an enemy of the poorest people on the planet, condemning them to inflated families that they cannot feed, and so keeping them in the bondage of perpetual poverty. A poverty that sits ill with the obscene riches of the Vatican.

He is an enemy of science, obstructing vital stem cell research, on grounds not of morality but of pre-scientific superstition.

Less seriously, from my point of view, Ratzinger is even an enemy of the Queen's own church, arrogantly endorsing a predecessor's dissing of Anglican Orders as "absolutely null and utterly void", while shamelessly trying to poach Anglican vicars to shore up his own pitifully declining priesthood.

Finally, perhaps of most personal concern to me, he is an enemy of education. Quite apart from the lifelong psychological damage caused by the guilt and fear that have made Catholic education infamous throughout the world, he and his church foster the educationally pernicious doctrine that evidence is a less reliable basis for belief than faith, tradition, revelation and authority – his authority.