We spend a large percentage of our lives at the office, engaged in the drudgery of work. Although we obsess over the medical benefits of various leisure activities - should I do yoga? take long walks? not watch television? – the amount of time we might spend in downward facing dog pose pales in comparison to the amount of time we spend seated in our chair, staring at the computer screen, surrounded by co-workers.

A new study led by Arie Shirom at Tel Aviv University reveals the powerful impact of the workplace on longevity. The researchers tracked 820 adults for twenty years, starting with a routine health examination in 1988. The subjects worked in various professions, from finance to manufacturing to health care. They were interviewed repeatedly about conditions at their workplace, from the behavior of the boss to the niceness of their colleagues. Over the ensuing decades, their health was closely monitored, allowing the scientists to control for various medical conditions, such as high blood pressure, smoking and depression.

The first thing the researchers discovered is that office conditions matter. A lot. In particular, the risk of death seemed to be correlated with the perceived niceness of co-workers, as less friendly colleagues were associated with a higher risk of dying. (What's troubling is that such workplaces seem incredibly common.) While this correlation might not be surprising - friendly people help reduce stress, and stress is deadly - the magnitude of the "friendly colleague effect" is a bit unsettling: people with little or no "peer social support" in the workplace were 2.4 times more likely to die during the study, especially if they began the study between the ages of 38 and 43. In contrast, the niceness of the boss had little impact on mortality.

What's driving this effect? Why are caustic co-workers so unhealthy? One interesting factor influencing the correlation between peer social support and mortality was the perception of control. This makes sense: the only thing worse than an office full of assholes is an office full of assholes telling us what to do. Furthermore, this model of workplace stress being driven by the absence of control has plenty of empirical support. The most impressive support comes from the Whitehall study, an exhaustive longitudinal survey launched in 1967 that tracked some 28,000 British men and women working in central London. What makes the study so compelling is its uniformity. Every subject is a British civil servant, a cog in the vast governmental bureaucracy. They all have access to the same health care system, don’t have to worry about getting laid off, and spend most of their workdays shuffling papers.

The British civil service comes with one other feature that makes it ideal for studying the health effects of stress: It’s hierarchical, with a precise classification scheme for ranking employees. This hierarchy comes with dramatic health consequences. After tracking thousands of civil servants for decades, the Whitehall data revealed that between the ages of 40 and 64, workers at the bottom of the hierarchy had a mortality rate four times higher than that of people at the top. Even after accounting for genetic risks and behaviors like smoking and binge drinking, civil servants at the bottom of the pecking order still had nearly double the mortality rate.

Why were people in the lower ranks of Whitehall dying at a younger age? The Whitehall researchers, led by Michael Marmot, eventually concluded that the significant majority of health variation was caused by psychosocial factors, most notably stress. People of lower status in the Whitehall study experienced more negative stress, and this stress was deadly. (To take but one data point: Fully two-thirds of an individual’s risk of stroke was attributable to the person’s socioeconomic status.) However, the Whitehall results aren’t a straightforward analysis of stress, at least not as it’s usually defined. After all, people in leadership positions often describe their jobs as extremely stressful. They work longer hours and have more responsibilities than those at the bottom of the bureaucratic hierarchy. Consider the self-report of Nigel, a high-status administrator: “There were 2,000 people, and I was responsible for all the personnel aspects, contracts, and all the common services … It had every sort of challenge that you could ever wish to meet. A very active job and a lot of stress, but a very enjoyable job, and you got a tremendous amount of satisfaction from doing a good job.”

Notice the reference to stress; undoubtedly Nigel thought of himself as a person under lots of pressure. In contrast, here’s the self-report of Marjorie, a lowly typist: “I went to the typing pool and sat there typing documents. Which was absolutely soul-destroying … The fact that we could eat sweets and smoke was absolute heaven, but we were not allowed to talk.”

The recurring theme in the self-reports of people like Marjorie isn’t the sheer amount of stress - it’s the total absence of control. This led to the “demand-control” model of stress, in which the damage caused by chronic stress depends not just on the demands of the job but on the extent to which we can control our response to those demands. “The man or woman with all the emails, the city lawyer who works through the night has high demands,” Marmot writes. “But if he or she has a high degree of control over work, it is less stressful and will have less impact on health.” The Whitehall data backs up this model of workplace stress: While a relentlessly intense job like a senior executive position leads to a slightly increased risk of heart disease and death, a job with no control is significantly more dangerous.

And this brings us back to the Israeli data. In this latest research, the "demand-control" model undergoes a fascinating, if quite disturbing, twist. While men in unfriendly workplaces fared worse when they had little control, women actually seemed to fare better. In other words, their health status was improved when they had no say over their work day. One possibility cited by the researchers is that having a modicum of control at the office exacerbated the tensions between the office and home. Because many of the women were also mothers, having control left them with an extremely stressful series of choices. Should they stay late at work? Or go home and take care of the kids? This freedom, it turns out, compounded the stress of the unfriendly workplace. Control without support was even worse than having no control at all.

Obviously, this relatively small longitudinal study is just a first draft. It remains unclear if these dismal correlations generalize to other countries, or if the gender differences will fade with time. Nevertheless, the research is a stark reminder that our workplace matters, that these people we spend forty hours a week with help determine the length of our lives.