Average height in the UK rose by 3.9in (10cm) during the 20th Century, and up to 7.8in in other countries, as nutritional health improved.
But exactly how this happens has never been understood.
The discovery could lead to drugs to improve muscle mass and treat delayed growth, UK researchers say.
Scientists have known for a long time that humans with good diets and reliable access to food tend to grow taller, and mature more quickly.
In South Korea, for example, adult height has rocketed as the nation transformed from a poor country to a developed society. Yet in parts of South Asia and Africa, people are only slightly taller than 100 years ago.
'Make lots of babies'
It's known that signals from food reach a part of the brain called the hypothalamus, telling it about the body's nutritional health, and triggering growth.
This new study, published in Nature, and led by researchers from the University of Cambridge alongside teams from Queen Mary University of London, University of Bristol, University of Michigan and Vanderbilt University, has discovered the brain receptor behind that process.
It's called MC3R and is the crucial link between food and sex development and growth.
"It tells the body we're great here, we've got lots of food, so grow quickly, have puberty soon and make lots of babies," said Prof Sir Stephen O'Rahilly, study author, from Cambridge.
"It's not just magic - we have the complete wiring diagram for how it happens."
When the brain receptor doesn't work normally in humans, the researchers found people tended to be shorter in height, and started puberty later than other people.
The team searched through the genetic make-up of half a million volunteers signed up to the UK Biobank - a huge database of genetic and health information - to confirm this was true.
Children found to have gene mutations which disrupt the brain receptor, were all shorter and weighed less than other children, which shows the effect starts early in life.
The research team found one person who had mutations in both copies of the gene for MC3R, which is extremely rare and damaging. This person was very short, and started puberty after the age of 20.
Drugs for the future
But humans are not alone in this - researchers studied mice to confirm that the same pathway is at work in animals.
The discovery could help children with serious delays in growth and puberty, as well as those who become frail with chronic diseases and need to build up muscle.
"Future research should investigate if drugs that selectively activate the MC3R might help redirect calories into muscle and other lean tissues, with the prospect of improving the physical functionality of such patients," Prof O'Rahilly said.
Scientists had already identified a brain receptor which controls appetite, called MC4R, and those who lack it are usually obese.
Can people keep growing taller?
There is a ceiling for height and it's reached when people achieve their genetic potential.
Factors such as health and diet have a huge impact on whether that happens.
When children from poorer families get enough food and calories, they can grow to the height they inherit from their parents and grandparents.
Taller people generally live longer and are less likely to suffer from heart problems, and may also end up earning more.
But humans can't keep on growing forever.
Like many other countries in Europe, average height in the UK shot up during the last century - but there are signs in the last 10 years that it's flattening.
Elsewhere, the largest height rises over the past century have been in South Korean women and Iranian men.
The tallest people in the world are men born in the Netherlands (71.8in), while the shortest are women born in Guatemala (55.1in).