Because Sufism, fairly or unfairly, has often been associated with fringe or esoteric elements of Islam, it has faced criticism throughout history, especially from some branches of mainstream Sunnism. In addition to reservations about the use of musical instruments, dancing, and poetry in ritual practice, opponents of what some would call "extreme Sufi practices" have criticized Sufi cosmology. A belief in the possibility of union with God, or of actually seeing the face of the Divine, is not found in mainstream Islam. These kinds of visions or experiences are generally reserved for the afterlife, and even then only if one has been deemed to merit entry into heaven and the vision of God.
On the one hand, there was nothing explicit about Sufism that took it clearly outside the bounds of orthodox Islamic theology. Sufis root their practice and theology in basic, mainstream Islamic principles. On the other hand, its history has been peppered with famous incidents of persecution of and opposition to Sufism.
One of the most famous cases of the execution of a mystic at the hands of the Muslim authorities is that of Al-Mansur al-Hallaj (b. 857), a mystic who was tortured and crucified in 922. Crucifixion was a common punishment in the ancient world for many centuries before the lifetime of Al-Hallaj. In this case, it included being tied to a cross-like structure and bound at the hands and feet, and as an additional torture, his hands were chopped off. One particularly graphic detail of his execution noted in the medieval sources is that, fearing that his face would appear pale with fright in the face of his persecutors, Al-Hallaj rubbed the bloody stumps of his arms onto his cheeks, to make them appear rosy. This type of detail, while gory to contemporary understandings, was quite common for medieval martyrdom narratives. The manner and brutality of his death have led some commentators to compare the martyrdom of Al-Hallaj with the crucifixion of Jesus and with the assassination of Muhammad's grandson Husayn. All three of these figures were seen by their various groups of follwers as martyrs who died willingly at the hands of opponents who persecuted them.
Al-Mansur al-Hallaj joined a circle of Sufis in Basra at the age of 20. After he made a pilgrimage to Mecca, he vowed to stay in that city for one year, fasting and praying. Afterward, having moved to Baghdad, he began preaching about his way of life and he amassed a following of disciples. Al-Hallaj proclaimed that each person was to find God in their own heart, a concept that did not endear him to many. The Abbasid authorities accused him of false miracles and deception. He made a second pilgrimage, then spent a period of his life outside of the Islamic realm, in India and Turkistan. When he returned to Mecca a third time, his asceticism was more pronounced, and he is reported to have prayed that God reduce him to nothingness. After returning to Baghdad, he reportedly built a home shaped to resemble the Kaaba, the sanctuary at Mecca. His preaching became provocative, centering on the theme of self-annihilation. He claimed to have attained mystical union with God, a charge for which he was sent to trial. He was eventually killed, under the official charge of sedition, though hagiographical accounts written by his devotees assert that it was for having reportedly said, "I am the Truth," meaning that he had been joined mystically with God (known as Al-Haq, the Truth). The utterance was meant to imply that al-Hallaj had been sublimated, that he was no longer existent, that there was "no I left," only God. In a way, he was claiming to be God, which tremendously offended the orthodox authorities. For this perceived blasphemy, he was publicly tortured and crucified. Al-Hallaj's preaching and spectacular death represent a moment of social upheaval in the history of Sufism. Other famous Sufis who shaped the tradition encountered opposition on more intellectual grounds.
Sufism was impacted by elements of the Classical world, most especially by Neoplatonism, which had become known to the Islamic world through translations since the beginning of the 9th century. Neoplatonism is a term for a concept attributed to Plotinus (a Greek philosopher of the 3rd century C.E.) that holds God to be the source and goal of everything. Sufism was most impacted by this concept in its own conception of the body and soul, good and evil, and the purpose of Creation. Because Neoplatonism was perceived as a foreign Greek concept, Sufi intellectuals of a slightly later period were often criticized for having allowed non-Islamic elements, especially Greek philosophy, to unduly influence their ideas. Ibn al-'Arabi (d. 1240) devised his own Neoplatonic system for how to achieve religious knowledge, central to which is the concept of unity of all beings. That is, everything is part of the One God and everything only exists insofar as it reflects the existence of the Divine. This type of religious consciousness is sometimes defined as monism, and flourished in the period called post-classical Sufism. It is chiefly characterized by the concept that God is One, and is the One who exists all alone, a doctrine called wahdat al-wujud. God's existence, according to this line of thought, is solitary and unique.