Iraqi Prime Minister Haider al-Abadi tweeted early Thursday that the destruction was an admission by the militants that they are losing the fight for Iraq’s second-largest city.

“Daesh’s bombing of the al-Hadba minaret and the al-Nuri Mosque is a formal declaration of their defeat,” al-Abadi said, using the Arabic acronym for the Islamic State group.

The mosque, which is also known as Mosul’s Great Mosque, is where IS leader Abu Bakr al-Baghdadi declared a so-called Islamic caliphate in 2014 shortly after Mosul was overrun by the militants. The minaret that leaned like Italy’s Tower of Pisa had stood for more than 840 years.

An IS statement posted online shortly after the Ministry of Defense reported the mosque’s destruction blamed an airstrike by the United States for the loss of the mosque and minaret.

The U.S.-led coalition rejected the IS claim.

A coalition spokesman, U.S. Army Col. Ryan Dillon, told The Associated Press that coalition aerial surveillance confirmed the mosque was destroyed, but he said a U.S. strike was not the cause.

“We did not conduct strikes in that area at that time,” Dillon said.

IS fighters initially attempted to destroy the minaret in July 2014. The militants said the structure contradicted their fundamentalist interpretation of Islam, but Mosul residents converged on the area and formed a human chain to protect it. IS has demolished dozens of historic and archaeological sites in and around Mosul, saying they promoted idolatry.

“This is a crime against the people of Mosul and all of Iraq, and is an example of why this brutal organization must be annihilated,” U.S. Maj. Gen. Joseph Martin, the commander of coalition ground forces in Iraq, said in a written statement.

“The responsibility of this devastation is laid firmly at the doorstep of ISIS,” he added.

The mosque sat on the southern edge of the Old City, the last IS stronghold inside Mosul. Iraqi forces launched a push into the Old City earlier this week, but have made slow progress as the last IS fighters there are holed up with an estimated 100,000 civilians according to the United Nations.

Earlier this month Mosul residents reported IS fighters began sealing off the area around the mosque. Residents said IS fighters ordered families living in the area to evacuate in preparation for a final stand.

The fight to retake Mosul was launched more than eight months ago and has displaced more than 850,000 people. While Iraqi forces have experienced periods of swift gains, combat inside the city has been grueling and deadly for both Iraqi forces and civilians.