In two separate studies published Wednesday in Nature, researchers used ancient DNA from dogs and wolves to press the timeline for when dogs emerged and to narrow the geographic story of how that relationship formed. The studies focused on genetic material that can be difficult to recover because ancient canine DNA is often contaminated and hard to extract, and both teams reported progress by isolating the genetic fragments they were looking for.

The findings, drawn from remains of more than 200 ancient dogs and wolves, identified some of the oldest genetic data analyzed to date. In the work, the oldest dated back to about 15,800 years ago, which the researchers said effectively pushed the origin of dogs back by at least 5,000 years. University of Michigan dog genomics expert Jeffrey Kidd, who was not involved with the research, said the relationship between people and dogs had been lasting far longer than recorded history can show.

The studies also mapped how dog-related genes were distributed across regions. The scientists reported that the genetic evidence indicated dogs were spread across Western Europe and Asia by about 14,200 years ago—an era that the researchers described as preceding the development of agriculture and farming. They characterized the human groups associated with that period as hunter-gatherers who moved frequently.

One part of the researchers’ interpretation centered on what they expected to see if domestication had been driven primarily by the agricultural era and later population movements. According to the studies, the dog genes sampled across locations from the United Kingdom to Turkey stayed more consistent than the human genetic patterns that emerged as new populations moved into Europe from southwest Asia during agriculture. Instead, the researchers said the dog genetic signals reflected interactions between different hunter-gatherer groups and their dogs thousands of years earlier.

The teams also drew distinctions between regions, saying that dog genes in Asia and the Americas appeared to reflect the movement patterns of their owners more closely. While the new genetic results help clarify timing and spread, the researchers said they do not yet know exactly what the earliest dogs looked like. One study co-author, Lachie Scarsbrook of Ludwig Maximilian University of Munich, said the researchers were “suspecting they would have resembled smaller wolves.”

Beyond appearance, the studies did not settle the question of how the ancient dogs lived alongside humans. The researchers said the animals could have stood guard or helped hunt, and they also suggested that the dogs likely played with children. Scarsbrook added that the bond has persisted, saying in remarks included with the reporting that dogs are “humanity’s best friend, alongside our societies for the last 16,000 years and will continue to in the future.”