Al-Maʿarri

He was a controversial rationalist of his time, attacking the dogmas of religion and rejecting the claim that Islam possessed any monopoly on truth.

Al-Maʿarri was skeptic in his beliefs and denounced superstition and dogmatism in religion.

Al-Maʿarri taught that religion was a "fable invented by the ancients", worthless except for those who exploit the credulous masses.
Do not suppose the statements of the prophets to be true; they are all fabrications. Men lived comfortably till they came and spoiled life. The sacred books are only such a set of idle tales as any age could have and indeed did actually produce.

Al-Maʿarri criticized many of the dogmas of Islam, such as the Hajj, which he called, "a heathen’s journey."
He rejected claims of any divine revelation. His creed was that of a philosopher and ascetic, for whom reason provides a moral guide, and virtue is its own reward.

Al-Maarri's fundamental pessimism is expressed in his recommendation that no children should be begotten, so as to spare them the pains of life. In an elegy composed by him over the loss of a relative, he combines his grief with observations on the ephemerality of this life:
Soften your tread. Methinks the earth’s surface is but bodies of the dead,
Walk slowly in the air, so you do not trample on the remains of God’s servants.

His religious skepticism and positively antireligious views are expressed in a poem which states "The inhabitants of the earth are of two sorts: those with brains, but no religion, and those with religion, but no brains."

He was equally sarcastic towards the religion of Islam as he was towards Judaism and Christianity. Al-Ma'arri remarked that monks in their cloisters or devotees in their mosques were blindly following the beliefs of their locality: if they were born among Magians or Sabians they would have become Magians or Sabians.

Sources:

1.) Freethought Traditions in the Islamic World by Fred Whitehead; also quoted in Cyril Glasse, (2001), The New Encyclopedia of Islam, p. 278. Rowman Altamira.