NEW YORK — For families who have searched years for missing loved ones, donating a sample of their DNA is often a last, desperate act to confirm their worst fears.

New York City’s medical examiner is leading a nationwide effort to collect genetic material and match it with unidentified human remains. It’s a way to finally give family members some answers and maybe some solace.

“People will not rest without answers, at least some answers,” said Dr. Barbara Sampson, the city’s chief medical examiner.

Over the last decade, thousands of DNA samples have been donated to the city’s medical examiner’s office. Most include swabs of saliva from close relatives, but also DNA taken from items used by the missing persons themselves, including toothbrushes, combs, razor blades and, once, even a sanitary napkin.

They’ve led to the identification of about 50 missing people each year, all of whom had been found dead. But for many who have submitted samples, the wait continues.

“Part of you hopes they never call you, because if they call, that means it’s over,” said Rose Cobo, who submitted DNA to the program after her adult niece vanished in 2016 after being treated at a Brooklyn hospital for postpartum depression following the birth of a son. Chelsea Cobo’s whereabouts are still unknown.

The program helped end Luis Merchan’s quest to find his younger brother, Manuel, who was reported missing in 2015 after he left his native Ecuador and crossed the U.S. border from Mexico. DNA matched with the remains of a 35-year-old “John Doe” who succumbed to exposure and dehydration in the Texas desert.

“It’s sad,” Merchan said. “We hoped Manuel would call one day. But we at least know what happened.”

On any given day, there are as many as 100,000 active missing-persons cases in the U.S., according to the FBI’s National Crime Information Center. Most of those people are eventually found safe. The medical examiner’s office program is open to people whose loved ones have been missing 60 days or more.