In 630, the Battle of Hunayn took place at Hunayn, close to this city. Shortly after that, the failed Siege of Ta'if took place. The city was attacked by Banu Daws, but it survived and repelled the attacks. The Battle of Tabouk in 631 left Tā'if completely saperated from the other ares so members of Thaqīf arrived in Mecca to negotiate the conversion of the city to Islam. The idol of al-lāt and other signs of the city's previously pagan past were destroyed.