The Iraqi prime minister, Haider al-Abadi, has said the destruction of the Great Mosque of al-Nuri in Mosul is an admission by the militants that they are losing the fight for the country’s second-largest city.

One of Islam’s most venerated sites, the mosque has been destroyed by explosions as Iraqi forces battled Islamic State fighters who had holed up nearby.

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

“The Daesh [Islamic State] terror gangs committed another historical crime by blowing up the al-Nuri mosque and its historic al-Hadba minaret,” the militarysaid.

The terrorist group said US-led airstrikes had caused the damage.

Images showing the mosque area and aerial photographs provided by the US military depicted scenes of widespread damage, with its renowned leaning minaret no longer standing and the compound largely in ruins.

The Iraqi military later released video footage, which showed the minaret tumbling to the ground after explosives detonated near its base. The blast was indicative of bombs being deliberately placed to bring it down.

Al-Hadba minaret at the Grand Mosque is seen through a building window in the old city of Mosul, Iraq June 1. Photograph: Alaa Al-Marjani/Reuters

The US military denied it had carried out airstrikes in the area.

The destruction came as Iraqi troops edged to within 50 metres of the mosque, in a densely packed neighbourhood of central western Mosul, more than eight months into the battle to free the city.

“As our Iraqi security force [ISF] partners closed in on the al-Nuri mosque, Isis destroyed one of Mosul and Iraq’s great treasures,” said Maj Gen Joseph Martin, commanding general of the US-led coalition fighting Isis.

“This is a crime against the people of Mosul and all of Iraq, and is an example of why this brutal organisation must be annihilated. The responsibility of this devastation is laid firmly at the doorstep of Isis, and we continue to support our Iraqi partners as they bring these terrorists to justice.

“However, the battle for the liberation of Mosul is not yet complete, and we remain focused on supporting the ISF with that objective in mind.”

Isis had vowed to defend the city it seized in July 2014 and had been fiercely resisting advancing forces this summer.

“They blew it up because they did not want the place they announced the caliphate from to be the place where the Iraqi military announces its victory over them,” said Hisham al-Hashimi, an author on extremist groups and a former government adviser.

Isis’s destruction of Palmyra: ‘The heart has been ripped out of the city'

Read more

The loss of the site is another devastating blow to Iraq’s heritage, which has been ravaged by 14 years of war since the US-led invasion to oust Saddam Hussein. The militants’ control over northern Iraq has taken a particularly heavy toll, with globally significant archaeological sites being vandalised and pillaged.

“When I looked out of the window and saw the minaret was no longer there, I felt a part of me had died,” Ahmed Saied, a 54-year-old schoolteacher in Mosul, told Reuters.

“In the early morning, I climbed up to my house roof and was stunned to see the Hadba minaret had gone,” Nashwan, a labourer living in the Khazraj neighbourhood near the mosque, said by phone. “I broke into tears. I felt I had lost a son of mine.”

The mosque was destroyed on the Night of Power, one of the holiest dates in the Islamic calendar, when the Qur’an was revealed to the prophet Muhammad. It was built in the 12th century by Noureddine al-Zanki, a famed commander and a contemporary of Saladin, whose family ruled the provinces of Aleppo and Mosul on behalf of the Abbasid caliph in Baghdad.

The mosque was one of the great monuments in Islam after the grand mosques of Mecca and Medina, al-Aqsa in Jerusalem and the Umayyad mosque in Damascus, rivalling others such as the Amr ibn al-’As mosque in Egypt and other more modern structures built in recent centuries.

Iraqi officials had privately expressed hopes that the mosque could be captured in time for Eid al-Fitr, the festival marking the end of Ramadan, which this year is on 25 June in Iraq. The fall of Mosul would, in effect, mark the end of the Iraqi portion of the “caliphate” even though Isis would continue to control territory west and south of the city.

Baghdadi has left the fighting in Mosul to local commanders and is believed to be hiding in the border area between Iraq and Syria, according to US and Iraqi military sources.