It looked like many different animals and, at the same time, like no other animal at all.

From afar, you might think it was a large, humpless camel. Tall, stout legs ending in rhino feet carried a body weight potentially equal to that of a small car. Its neck stretched like a giraffe’s before giving way to a face resembling a saiga antelope’s. From this face extended a fleshy protuberance, similar to a mini elephant trunk or a tapir’s proboscis.

When Charles Darwin first found its fossils in southern Patagonia during his Beagle voyage, he was baffled. He sent specimens to Richard Owen, an English paleontologist, who guessed the animal was a gigantic, llamalike beast and named it Macrauchenia, meaning “large llama.”

Since then, many researchers have taken a stab at pinning Macrauchenia to the tree of life. Their speculations differed wildly, grouping the extinct beasts with animals as varied as elephants and aardvarks or camels and hippos.

Now, 180 years after Darwin’s discovery, scientists have confirmed that Macrauchenia were distant relatives of horses, rhinos and tapirs, members of a group known as Perissodactyla. In a study published last week in Nature Communications, the researchers estimated that Macrauchenia diverged from Perissodactyla between 56 million and 78 million years ago.

A group that “was basically homeless has now found its place,” said Michael Hofreiter, a professor of genomics at the University of Potsdam in Germany and an author of the study.

Macrauchenia were herbivores that roamed open, grassy spaces across South America before disappearing with many other megafauna at the end of the last ice age, around 12,000 years ago. Over the years, paleontologists and excavators have found a fair number of Macrauchenia fossils, but studying bones and teeth alone has been misleading because the animals had such a jumble of traits, said Ross MacPhee, a curator at the American Museum of Natural History in Manhattan and another author of the study.

To gain a deeper understanding, Dr. Hofreiter, Dr. MacPhee and their colleagues turned to DNA. The team managed to find one toe bone, from a cave in southern Chile, that had enough Macrauchenia DNA to study.

When reconstructing ancient DNA sequences, scientists typically use the genome of a closely related living relative as a scaffold. But Macrauchenia doesn’t have any close living relatives.

Instead, the researchers compared around 20,000 mitochondrial DNA snippets from their bone sample with the mitochondrial genomes of horses, rhinos, tapirs and wild llamas.

Dr. Hofreiter compared the process to assembling a jigsaw puzzle, under these conditions: You don’t have the final picture you’re constructing, but you have several pictures that are somewhat similar to help you place your pieces.

The researchers reconstructed about 80 percent of Macrauchenia’s mitochondrial genome. Until now, Dr. Hofreiter said, “nobody had reconstructed an ancient DNA sequence where the next closest living relative was so distant.”

By comparing this so-called mitogenome with the mitogenomes of many mammals, his team was able to place Macrauchenia as sister to Perissodactyla on the evolutionary tree.

The new findings largely confirmed those from a 2015 study, in which a group of scientists (including Dr. Hofreiter and Dr. MacPhee) studied Macrauchenia through ancient proteins.

The fact that “two entirely different approaches gave the same story is pretty convincing,” said Matthew Collins, a bioarchaeologist at the University of York in Britain. Dr. Collins, an author of the 2015 study, was not involved in the current research.

In the future, as tools for studying ancient DNA continue to improve, scientists will be able to unlock the genetic sequences of more and more extinct species that inhabited warm climates, where DNA degrades quickly, Dr. MacPhee said.

“That’s going to make a huge difference in how we understand the past,” he said.