This is a trend in all the great apes – the males compete for dominance and to protect the troop and this has driven them to evolve considerable size and strength compared to females.
Human males don’t (usually) fight eachother directly for physical dominance anymore, but the evolutionary history is still there.
You can see it in all the great apes, dominant male gorillas and orangutans are twice the size of the females in their troop. Humans and chimpanzees are somewhat less dimorphic with males only slightly larger than females.
Because in our past, genes that make men taller and women shorter apparently increased the odds of your offspring surviving to adulthood.
This doesn’t mean those specific evolutionary pressures are still in effect.
If they aren’t, you’d expect men and women’s heights to even out over time, but we’re talking tens of thousands of years here, at least. Evolution can work faster, if there is a lot of pressure, but I don’t think that’s the case for height.
It takes more energy to be taller. Nutrients need to be acquired to supply the growth and maintenance of the larger skeleton as well as all other affected organs. Therefore, being taller must confer some evolutionary advantage(s) for males and why this disadvantage makes females typically shorter. Edit: also, the gather role females often played early in our evolution meant being shorter made collecting ground seeds/berries much easier.
The male advantages to being taller despite the nutrient demand:
* Quick and easy way for the choosy female(s) to determine he comes from a strong genetic line that fed their offspring well and so is more likely to feed his offspring well too,
* Taller males are more visually intimidating. Looking up at your opponent immediately instills fear which needs to be overcome by the shorter competitor. This is common throughout Mammalia (is why cats arch their backs, dogs hair raises, bears stand up, police wear those stupid hats…)
* Taller males have greater reach, visibility, and strength if their weight matches their height.
* Prior to tools, taller males had greater access to higher food sources.
Pop-evolution takes without any actual scientific support aside, if you’re asking for the actual physiological mechanism:
When your bones are growing as a child, they have something called a [growth plate](https://en.wikipedia.org/wiki/Epiphyseal_plate) at each of the major joints. That’s where new bone is produced as you grow. But when you’re a teenager and reach your full adult size, those growth plates irreversibly convert to just regular old bone (“fusion”).
This process is triggered in part by estrogen, one of the major hormones that differs between the sexes. Higher estrogen levels in girls cause the bone plates to fuse earlier than men: girls’ bones typically stop growing around 14 or 15, while boys stop a few years later. That means less growth in each bone, and thus a smaller body overall. Estrogen levels in boys rise during puberty too (estrogen in men is mostly produced by an enzyme converting testosterone into estrogen), but by a smaller amount, so their growth plates fuse later on.
Although this isn’t actually true at all ages. Girls typically hit puberty first, so they are actually on average slightly taller than boys for a few years from about ages 10 to 13. But by 14, most girls are very near their adult height, while boys continue to grow for a couple years, reaching their adult height around 16. You can see normal growth charts for [girls](https://cdn.who.int/media/docs/default-source/child-growth/growth-reference-5-19-years/height-for-age-(5-19-years)/cht-hfa-girls-perc-5-19years.pdf?sfvrsn=f90a33cf_4) and [boys](https://cdn.who.int/media/docs/default-source/child-growth/growth-reference-5-19-years/height-for-age-(5-19-years)/cht-hfa-boys-perc-5-19years.pdf?sfvrsn=457ae3f4_4) by following those links.
Latest Answers