All work and no play may be bad news for your brain.

While regular exercise is known to help ward off dementia, a new study found that frequently engaging in one type of physical activity is associated with a 20% higher risk of being diagnosed.

But the workout raising eyebrows isn’t taking place at the gym — it’s happening on the clock.

In the analysis, researchers at the University of Southern California looked at data from 74 studies involving more than 4.2 million people between the ages of 45 and 93 across 30 countries.

The participants reported how physically active they were, including how much time they spent exercising for fun, doing manual labor, tackling household chores and commuting to work.

The researchers then followed the participants for a median of 10 years, tracking diagnoses of all-cause dementia, Alzheimer’s disease and vascular dementia — a type of cognitive decline caused by conditions that disrupt blood flow to the brain.

The findings revealed a surprising divide between those who broke a sweat for fun and those who did it for a living.

People who engaged in higher levels of leisure-time exercise — including walking, cycling, running, swimming and playing sports — had a 24% lower risk of developing dementia than those who were least active.

But those who did more physically demanding work on the job had a 20% higher risk of developing the memory-robbing illness.

Think: construction crews digging ditches, hauling away debris and operating heavy machinery, or warehouse employees lugging heavy boxes, restocking shelves and logging long shifts on their feet.

Active commuting, such as biking to work, was also associated with a modest increase in dementia risk, though those findings were based on just two studies.

Household chores, meanwhile, appeared to have the opposite effect. Activities such as cooking, cleaning, making home repairs and gardening were associated with potential benefits, though that evidence came from just one study.

“The findings challenge the long-held assumption that ‘every move counts’ for brain health,” Natan Feter, the study’s first author, said in a press release.

But this isn’t the first time researchers have questioned whether physical labor offers the same health benefits as a voluntary workout.

Previous research into heart health has suggested that physically demanding jobs may not provide the same cardiovascular benefits as recreational exercise — and could even increase the risk of disease.

In one meta-analysis of 23 studies, researchers found that high levels of physical activity on the job were associated with a 24% higher risk of cardiovascular disease. Leisure-time exercise, meanwhile, was associated with a 34% lower risk.

The latest University of Southern California study is the first to investigate whether this so-called “physical activity paradox” also applies to dementia.

Researchers suspect the difference may have less to do with the movement itself and more to do with the conditions surrounding it.

Unlike recreational exercise, which people can typically do at their own pace and intensity, physically demanding jobs often involve long hours of repetitive exertion and limited breaks.

They can also come with psychosocial stress, hazardous environments and greater exposure to air and noise pollution — all factors that have independently been linked to dementia risk.

People who spend their workdays doing strenuous physical labor may have less time or energy to exercise recreationally as well, thanks to exhaustion or demanding schedules.

But don’t go handing in your resignation just yet.

The researchers cautioned that their findings don’t prove physically demanding work causes dementia, since the studies they analyzed were observational and can only show associations, not establish a direct link.

The analysis also had several limitations, including that participants self-reported their activity levels, meaning some details may not have been entirely accurate.

Still, the findings suggest that dementia prevention efforts should take into account not just how much exercise people get, but where, why and under what conditions they’re doing it.

“When it comes to protecting the brain, the context of physical activity may matter just as much as movement itself,” said Dr. David Raichlen, a professor of biological sciences and anthropology who led the research team.

The stakes are high: An estimated 42% of Americans over age 55 will eventually develop some form of dementia, which currently affects more than 6 million people nationwide.

But there’s reason for hope. Research suggests that nearly 45% of dementia cases worldwide could be prevented or delayed by addressing up to 14 modifiable risk factors.

Those include treating hearing impairment, keeping cholesterol, blood pressure and blood sugar levels in check and avoiding smoking.

Share.