Scientists say their research reveals the underlying genetic change that caused Charles Byrne, known as the Irish Giant, to grow to 7ft 7in tall.
DNA from two of his teeth uncovered a mutation believed to be about 1,500 years old that causes uncontrolled body growth.
It is the same abnormality affecting as many as 300 people living today with conditions known as gigantism and acromegaly.
Byrne, from Northern Ireland, was born in 1761 and came to London in the 1780s where he became famous exhibiting himself as a curiosity or "freak". He died aged 22 after developing a drink problem but his body was acquired by a surgeon and his skeleton remains on display today at the Hunterian Museum at the Royal College of Surgeons in London.
The gene variant triggers tumour growth in the pituitary gland at the base of the brain. Among its many functions, the gland releases hormones that regulate growth.
Pituitary tumours can cause tissue to grow abnormally, which may lead to gigantism – as suffered by Byrne – or acromegaly which leads to thickened skin, enlarged hands and feet, distorted facial features and overgrown organs.
In her research, Professor Mrta Korbonits, who led the work at Barts and The London School of Medicine and Dentistry, noticed a particular abnormality in a number of living patients of Irish descent with familial acromegaly, also carried by Byrne.
By looking at genetic differences near the gene, they worked out that he and other Irish families had inherited their mutated gene from the same common ancestor around 66 generations ago.
Some 200 to 300 living people might be carrying the abnormality today who could be identified and treated earlier thanks to the discovery through a simple blood test.
Prof Korbonits said: "The idea initially looked quite bizarre but as we gained more data and identified new families affected by the mutation, our findings confirmed our theory. The most important clinical aspect of our study is that it is now possible to trace down carriers of this gene in time and treat patients before they grow to be a giant."
Co-author Prof Mark Thomas, of University College London, added: "The striking thing about this research is that with modern genetic techniques we can say so much about somebody who died so long ago and use that information to identify and treat people at risk today."
The research, published in the New England Journal of Medicine, also involved scientists from Leeds, Exeter and Leicester universities, Royal Victoria Hospital and Queen's University, Belfast, Mainz University in Germany and the Natural History Museum.