Little is known of his early life, but he succeeded in winning the favor of Al-Hajjaj bin Yousef, the governor of Iraq. Already famous for his verse, he became more widely known by his feud with rival poets Farazdaq and Akhtal. Later he went to Damascus and visited the court of the caliphAbd al-Malik and that of his successor, Al-Walid I. From neither of these did he receive a warm welcome. He was, however, more successful with Umar II, and was the only poet received by the pious caliph.
His verse, like that of his contemporaries, is largely satire and eulogy.