Tear gas heralded the start of the Egyptian security forces’ assault on the al-Fath mosque in central Cairo.
The police say it has now been completely evacuated, but the fate of some 400 people who had sought shelter within is unknown.
Saturday morning began with security forces ringing the building and forcing back angry crowds who wanted to attack the supporters of the Muslim Brotherhood inside. Negotiations then began to try and get them to leave peacefully under escort.
Then the army came under fire from at least one gunman positioned in a minaret, triggering the assault.
The army forced its way into the building, with elements of the crowd surging in behind. The soldiers came face-to-face with barricaded entrances, and were pelted with objects. Sporadic shooting also broke out, and the army responded in a prolonged exchange of fire.