Researchers at the University of Edinburgh analysed genetic information from more than 13,000 heterosexual couples.
They found that 89 per cent of the genetic variation that determines a person's height also influences their height preference in a mate.
"How we choose our partners has important biological implications for human populations," said Albert Tenesa from the University of Edinburgh.
"This study brings us closer to understanding the complex nature of sexual attraction and the mechanisms that drive human variation," she added.
It also explains why people choose partners of similar height to themselves, researchers said.
The findings were published in the journal Genome Biology.