The mourning event on Friday came after Mahdi's body arrived at Khartoum airport earlier in the day, where the head of Sudan’s ruling sovereign council, the prime minister and other top officials attended an official reception.
The coffin of Mahdi, who was 84 years old, was then transferred to Omdurman, the capital's twin city across the river Nile, for the funeral, according to local media reports.
His body was laid to rest alongside his great-grandfather, the Mahdi (messiah) who had led a popular uprising against British colonial rule in the late 1800s. He contracted COVID-19 last month and was being treated in the United Arab Emirates.
Mourners in traditional white garments, mostly wearing masks, wept and waved national flags ahead of prayers for the two-time prime minister, who was a central figure in Sudan's political and spiritual life for over 50 years.
Stewards moved through the crowds of mourners, who gathered around the domed shrine where he was to be buried, offering hand sanitizer as a precaution against COVID-19 after Mahdi's Umma Party had called on mourners Thursday to follow all health procedures.
His passing came shortly after Khartoum entered a normalization deal with the Israeli regime under intense pressure from the outgoing administration of hawkish US President Donald Trump.
Lebanon’s Hezbollah resistance movement issued a message of condolence marking al-Mahdi’s passing, saying he was a staunch supporter of Palestine who opposed any form of normalization with the Tel Aviv regime.