There seems to be a clear correlation between health and employment status among prime-age men (25-to-54 years) in the United States. Those not taking part in the work-force in this age bracket are more often plagued by health issues than their working peers.
According to Bureau of Labor Statistics data quoted by the Brookings Institution, prime-age males out of the workforce are more likely to report that their health is "fair" or "poor" compared to a male in the labor force (37 percent versus 5 percent).
The data doesn't show if in some cases the reason for men being out of work might be his poor health in the first place. However, the authors of the report note that "employment provides structure to life, a source of identity, and an opportunity to engage with other members of society outside of one’s family." Being without this structural frame is very likely to have an adverse effect.
The study also finds that lower work rates among this age group can contribute to declining marriage rates and psychological well-being. And in some cases even lead "to an increase in premature deaths among certain populations." In general, workers between the ages of 25 and 54 tend to be at their most productive. In the United States there has been a steady decline in workforce participation among men of that age.
You will find more statistics at Statista