Walking or cycling to work is better for people's mental health than driving to work, according to a recent study.

Researchers from the University of East Anglia and the Centre for Diet and Activity Research (CEDAR) found that people who stopped driving and started walking or cycling to work benefited from improved wellbeing. In particular, active commuters felt better able to concentrate and were less under strain than if they travelled by car.

These benefits come on top of the physical health benefits of walking and cycling that are already widely documented.

"Our study shows that the longer people spend commuting in cars, the worse their psychological wellbeing. And correspondingly, people feel better when they have a longer walk to work," Adam Martin, lead researcher of the study, said in a statement.

For the study, researchers collected and analyzed 18 years of data on almost 18,000 commuters in Britain between the ages of 18 and 65. The data allowed them to look at multiple aspects of psychological health including feelings of worthlessness, unhappiness, sleepless nights, and being unable to face problems. The researchers also accounted for numerous factors known to affect wellbeing, including income, having children, moving house or job, and relationship changes.

"This research shows that if new projects such as London's proposed segregated cycleways, or public transport schemes such as Crossrail, were to encourage commuters to walk or cycle more regularly, then there could be noticeable mental health benefits," Martin said.

Data from the 2011 Census (England and Wales) shows that 67.1 percent of commuters use cars or vans as their usual main commute mode compared to 17.8 percent who use public transport, 10.9 per cent who walk and just 3.1 percent who cycle.

The findings were published in the journal Preventive Medicine.