An Afghan baby who had been missing for nearly five months after his father handed him to a uniformed official during the evacuation of Afghanistan has been reunited with his family. 

The baby, Sohail Ahmadi, was two months old when he went missing on Aug. 19 as thousands of people converged at the airport in Kabul looking to evacuate the nation as the Taliban regained control, Reuters reported.

The boy’s parents feared their son would get crushed by the crowd, and the father, Mirza Ali Ahmadi, handed him to a uniformed soldier he believed was an American over a fence at the airport. Ahamdi, who worked as a security guard at the U.S. embassy, recounted to Reuters that he believed he would be reunited with his son soon after he, his wife and their other children made it through the airport’s gate.

BABY LOST IN CHAOS OF AFGHANISTAN AIRLIFT FOUND, RETURNED TO FAMILY AFTER LONG ORDEAL

This image made available to AFP on August 20, 2021 by Human Rights Activist Omar Haidari, shows a US Marine grabbing an infant over a fence of barbed wire during an evacuation at Hamid Karzai International Airport in Kabul on August 19, 2021. - A Pentagon official confirmed Friday that US evacuation operations from Kabul's airport have been stalling because the receiving base in Qatar is overflowing and could not receive evacuees. "There has been a considerable amount of time today where there haven't been departures," Brigadier General Dan DeVoe of the US Air Mobility Command told reporters

This image made available to AFP on August 20, 2021 by Human Rights Activist Omar Haidari, shows a US Marine grabbing an infant over a fence of barbed wire during an evacuation at Hamid Karzai International Airport in Kabul on August 19, 2021.  (Courtesy of Omar Haidiri/AFP via Getty Images)

The Taliban, however, pushed the crowd back that day, causing the parents and their four other kids to wait an additional 30 minutes before they made it to the gate. 

By that time, the child had disappeared. 

Officials told Ahmadi the child had likely already been evacuated and the family would be reunited later. The family ultimately evacuated to the U.S., but the child was still in Kabul. 

Baby Sohail Ahmadi sits inside the house of Hamid Safi, a taxi driver who had found Sohail in the airport, in Kabul, Afghanistan, January 7, 2022. Picture taken January 7, 2022. REUTERS/Ali Khara

Baby Sohail Ahmadi sits inside the house of Hamid Safi, a taxi driver who had found Sohail in the airport, in Kabul, Afghanistan, January 7, 2022. Picture taken January 7, 2022. REUTERS/Ali Khara (Reuters)

For months, the parents of the boy had no idea where their son was. 

Unbeknownst to them, a 29-year-old cab driver named Hamid Safi found him at the airport. He tried to locate the parents at the airport, but ultimately took the boy home to his wife and their own children, Reuters reported.

Hamid Safi, a 29-year-old taxi driver who had found baby Sohail Ahmadi in the airport, cries as he holds Sohail before handing him over to his grandfather Mohammad Qasem Razawi in Kabul, Afghanistan, January 8, 2022. Picture taken January 8, 2022. REUTERS/Ali Khara

Hamid Safi, a 29-year-old taxi driver who had found baby Sohail Ahmadi in the airport, cries as he holds Sohail before handing him over to his grandfather Mohammad Qasem Razawi in Kabul, Afghanistan, January 8, 2022. Picture taken January 8, 2022. REUTERS/Ali Khara (Reuters)

"I am keeping this baby. If his family is found, I will give him to them. If not, I will raise him myself," he told the outlet in an interview in late November.

Some of Safi's neighbors saw Reuters’ November article and posted online where the boy was located. The boy’s grandfather traveled to where the child was located, but Safi refused to give him up, saying he wanted his family to also be evacuated from the country. 

MARINE DISCHARGED FOR CRITICIZING AFGHANISTAN WITHDRAWAL SAYS TOP GENERAL SHOULD BE HELD ACCOUNTABLE

The grandfather, Mohammad Qasem Razawi, eventually contacted Taliban police. 

Mohammad Qasem Razawi, grandfather of baby Sohail Ahmadi, holds him at the house of Hamid Safi, a 29-year-old taxi driver who had found the baby in the airport, in Kabul, Afghanistan, January 8, 2022. Picture taken January 8, 2022. REUTERS/Ali Khara

Mohammad Qasem Razawi, grandfather of baby Sohail Ahmadi, holds him at the house of Hamid Safi, a 29-year-old taxi driver who had found the baby in the airport, in Kabul, Afghanistan, January 8, 2022. Picture taken January 8, 2022. REUTERS/Ali Khara (Reuters)

"The grandfather of the baby complained to us and we found Hamid and based on the evidence we had, we recognized the baby," said Hamid Malang, the chief area controller of the local police station. "With both sides in agreement, the baby will be handed over to his grandfather," he said on Saturday.

Safi finally gave the boy back to his grandfather this weekend after seven weeks of negotiations and a short Taliban detention. He was compensated about $950 for watching over him for the last five months. 

CLICK HERE TO GET THE FOX NEWS APP

The family said they are now working to get the boy to his parents and siblings who are in the United States. 

"We need to get the baby back to his mother and father. This is my only responsibility," his grandfather said. "My wish is that he should return to them."