Wearing looser underpants could be a simple way for men to improve their sperm count and the hormones that control it, a US study suggests.
In a study of 656 men, by researchers at Harvard TH Chan School of Public Health, in the US, boxer short wearers had a 25% higher sperm concentration than men in tight-fitting underwear.
Cooler temperatures around the testicles could be the reason.
Experts say this simple lifestyle change could improve men's fertility.
'Brain boosts sperm production'
Sperm production is known to be sensitive to temperatures above 34C (92F), which is why the testicles hang down away from the body.
Some styles of underpants, such as jockey shorts or briefs, bring the scrotum nearer to the body, causing the testicles to warm up, while others, such as boxer shorts, are looser and cooler.
In the largest study of its kind to date, the researchers found men attending a fertility clinic with looser-fitting boxer shorts had higher sperm concentration, a 17% higher total sperm count and 33% more swimming sperm than men with tighter-fitting underwear.
However, the sperm shape wasn't affected and neither was the DNA quality.
Researchers, who took into account other factors that can affect sperm, including age, body mass index (BMI) and habits such as smoking and hot tub use, speculate that the higher heat inside pants is the root of the problem.
The study, published in the journal Human Reproduction, also found that a hormone from the brain that tells the testicle to make sperm, called follicle stimulating hormone (FSH), was 14% lower in wearers of looser underwear.
The findings suggest that this hormone kicks into gear when it needs to compensate for increasing scrotal temperatures and decreasing sperm counts in tight underwear.
Prof Allan Pacey, professor of andrology, from the University of Sheffield, who was not involved in the study, said the different levels of FSH among men with different types of underwear "suggests that the tight-pant wearers have evidence of testicular damage".
'Reproduction is a team sport'
The study is about sperm quantity and quality, however, and not fertility itself.
Regardless of the types of underpants worn, sperm counts were in the normal range.
But Prof Pacey told the BBC: "Potentially switching from tight to loose might help some men who are on the lower edge of sperm production.
"It shows that tight pants have an effect and shows there is a relatively cheap and easy thing that men can attempt to do to try and improve their situation."
The paper's author, Dr Jorge Chaverro, told the BBC: "It takes about three months for an entire population of sperm to change, so plan in advance.
"Infertility is most certainly not just a female problem. Reproduction is a team sport. You need both people to make a baby.
"I think we still have a lot to learn about men's contribution to fertility."
Follow Lucy on Twitter