Your puppy has an ancestor in deadly wolf!

The pretty dog at your home was domesticated among wolf-like ancestors - and not early farmers - between 9,000 and 34,000 years ago, a new research has found.

"Dog domestication is more complex than we originally thought," said Adam Freedman, a postdoctoral fellow at the University of California, Los Angeles (UCLA) and the lead author of the study.

The team generated the highest-quality genome sequences to date from three gray wolves - one each from China, Croatia and Israel - representing three regions where dogs are believed to have originated.

They also produced genomes for two dog breeds - basenji, a hunting breed originated in central Africa, and dingo from Australia - both areas that have been historically isolated from modern wolf populations.

The analysis showed that dogs seem to have descended from an older, wolf-like ancestor - common to both species.

The study debunks the popular story that early farmers adopted a few docile, friendly wolves that later became our beloved, modern-day companions.

"Instead, the earliest dogs may have first lived among hunter-gatherer societies and adapted to agricultural life later," said John Novembre, associate professor at University of Chicago and a senior author on the study.

But regardless of geographic origin, dogs are more closely related to one another than wolves, said the study published in the journal PLoS Genetics.

According to the research, domestication resulted in significant reduction in historical population sizes of both early dogs and wolves.

"Now we have a much more detailed picture than existed before, and it's a somewhat surprising picture," said Novembre.