WASHINGTON—An American couple in Qatar was set to return home on Wednesday after the government agreed to lift the pair’s travel ban, ending a bureaucratic logjam that prevented the couple’s departure even after being cleared of charges related to an adopted daughter’s death.

A Qatari judge ruled on Sunday that Matthew and Grace Huang weren’t responsible for the 2013 death of their 8-year-old daughter, Gloria, and that the married couple was free to return to the U.S. But an earlier travel ban barred travel.

On Tuesday, the Qatari government said the Huangs met the requirements necessary to remove the travel ban and that it wouldn’t file an appeal in the case, U.S. Ambassador to Qatar Dana Shell Smith said on Twitter.

“The United States applauds this decision, and we look forward to seeing the Huangs reunited with their children at home,” Secretary of State John Kerry said in a Tuesday statement.

The lifting of the travel ban ended a two-year legal saga and appeared to reflect a desire on the part of both countries to end the protracted battle. The bureaucratic dust-up was the latest in a longer tussle with the Qatari government over holding the Huangs.

Throughout the legal proceedings against them, the Huangs were subject to a travel ban preventing them from leaving the country. The State Department made repeated requests throughout the court proceedings for Doha to withdraw the travel ban, and raised concerns that the Qatari court didn’t weigh all of the evidence and that cultural misunderstandings might have led to an unfair trial.

Senior Qatari officials have stressed in recent interviews that the Huangs’ case was strictly a judicial matter.

Following Sunday’s verdict, the couple headed to the airport to return to Los Angeles. The U.S. Ambassador to Qatar Dana Shell Smith met the Huangs at the airport, intending to greet them and usher them home.

But the Huangs were stopped at immigration and informed that the ban still applied. The couple’s legal team was suspicious of the additional delay, but U.S. officials said the ban remained, because lifting it required filing additional paperwork. Ms. Shell remained with the couple and their representatives as they sought permission to return home.

The issue was escalated up to Mr. Kerry, who spoke with his Qatari counterpart by telephone on Sunday to ask the government to implement the court’s decision and allow them to return home swiftly.

After filing the additional paperwork Monday, the Huangs’ representatives called on the U.S. to do more to secure the Huangs’ departure, including placing a high-level call to the emir of Qatar to urge their release following Sunday’s decision. A U.S. official said removing the travel ban was a process separate from the judge’s ruling, and required its own evaluation process that could take days.

The U.S. official said the U.S. had faith that the Qatari’s legal process could resolve the situation, and that abiding by Qatar’s legal framework would help to preserve the bilateral relationship.

Had the attorney general’s office decided to file an appeal and drag on the legal proceedings, it would have harmed U.S.-Qatar relations and prompted stronger intervention on the part of the Obama administration, the official said.

“This definitely has not gone the way we’d like to see it go,” the official said.

The tiny gulf emirate is an important ally of the U.S. Qatar is part of the U.S.-led coalition against Islamic State, and its air force has provided surveillance and logistical support to the air campaign. U.S. Central Command has launched large numbers of strikes from Qatar’s Al-Udeid air base west of Doha.

Still, Qatar has joined other critics in calling for the Obama administration to do more to target the regime of Syrian President Bashar al-Assad.

When the Taliban released Sgt. Bowe Bergdahl in exchange for five Taliban officials in May, Qatar served as the interlocutor between the U.S. and the Taliban. But while the U.S. has taken advantage of Qatar’s ties in the region, it has also criticized them. The U.S. Treasury Department has accused Qatar of lax oversight of its financial system and has sanctioned a number of Qatari nationals or identification-card holders for their alleged role in funding al Qaeda and Nusra Front, its Syrian affiliate.

The Huangs were arrested in 2013 after Gloria, who they adopted from Africa, died suddenly. The Huangs initially were charged with murder, but the Qatari court eased that with a charge of child endangerment. The Huangs denied the charges. Adopted from Ghana, Gloria had an eating disorder, the Huangs and their legal team said.

The prosecution accused the Huangs of starving Gloria with the intention of harvesting her organs. The Qatari police also accused the Huangs of human trafficking, indicating in police reports and court testimony that they couldn’t understand why a couple of Asian descent would adopt African children.

In March, the Huangs were sentenced to three years in prison, but an appeals court on Sunday overturned the conviction.

The Huangs are eager to get home, said Eric Volz, managing director of the David House Agency, an international crisis firm the couple hired to help with their case. “All the proper paperwork has been filed and any continued delays are a cause for concern. We ask that the State Department keep up any necessary pressure to ensure Matt and Grace are able to depart tomorrow,” he said.

The Huangs moved to Qatar in summer 2012, when Mr. Huang took a job in Doha to help oversee an infrastructure project related to preparations for the 2022 soccer World Cup.