Richard Mbulu scored the all important goal as Malawi stunned Uganda Cranes at Kamuzu Stadium 1-0 to progress to the Africa Cup of Nations finals due in Cameroon next year.
It will be only their 3rd time in history after qualifying for the 1984 and 2010 editions.
Uganda only need a draw to make it to the continental showpiece for a third consecutive time while a win for Malawi flames was enough to second them through.
Mbulu gave the hosts an early lead with a superb diving header off a perfect Stanley Sanudi cross in the 15th minute.
The Cranes’ best chance in the first period fell to Emmanuel Okwi but his effort was saved by Malawi custodian Ernest Kakhobwe and hit the post.
In the second period, Interim coach Abdallah Mubiru introduced on Allan Okello, Tadeo Lwanga and Yunus Sentamu for Farouk Miya, Mike Azira and Ibrahim Orit respectively.
The Cranes were however not good enough to breakdown a resilient Malawi defence and at fulltime it was jubilation for the hosts.
Malawi had previously featured at the final tournament in 1984 and 2010. They finished the qualification campaign second of group B with 10 points while Uganda were third on eight.
During the qualification campaign, the Cranes have failed to score away from home, only collecting a single point off Burkina Faso.
The Stallions and Malawi are the 2 teams that made the grade out group B to Cameroon 2021