CAIRO — Egypt’s election commission yesterday declared Mohammed Morsi of the Muslim Brotherhood the winner of the country’s first free elections by a narrow margin over Ahmed Shafiq, the last prime minister under deposed leader Hosni Mubarak.

The commission said Morsi won with 51,7% of the vote versus 48,3% for Shafiq.

A huge crowd of Morsi supporters in Cairo’s Tahrir Square erupted in cheers and dancing when the result was read out on live television.