For adults 65 and older, the increased risk is highest in the first year following the infection, but remains elevated for at least a decade — which was the maximum time the researchers followed the patients.
In the first 30 days, the increased risk was substantial — four times greater than that of people of similar ages who had not been hospitalized with pneumonia.
Lead author Dr. Vicente Corrales-Medina of the Ottawa Hospital said the study confirms what doctors have been seeing for years.
"There have been clinical observations of people coming to the hospital with a bad respiratory infection, a bad pneumonia and then developing a cardiovascular event such as a stroke, heart attacks or even heart failure soon after they are diagnosed with this infection," he said in an interview.
"These observations are decades old. But nobody has looked at it in a rigorous way to determine whether this is just a coincidence or there is really an association that would suggest an increased risk or a period of high risk for cardiovascular events after pneumonia."
The study is published Tuesday in the Journal of the American Medical Association.
Corrales-Medina and his co-authors looked at data from two large, long-term and ongoing studies in the United States. One followed nearly 6,000 adults 65 and older while the other tracked nearly 16,000 adults aged 45 to 64 at the time of recruitment to the study. There were 591 and 680 pneumonias respectively in the two study groups.
The researchers looked at people who had been hospitalized with pneumonia and compared them to people who had not had the infection to see if there was an elevated rate of heart disease events in the former after the pneumonia hospitalization.
For the older adults, the risk dropped after 30 days, but was still nearly double that of people who hadn't had pneumonia at two years after the infection. And it remained in the range of 1.6 to 1.9 times higher all the way to 10 years.
For the younger adults, the risk is also elevated but not to the same extent, and it appears to level off after two years. In the first 30 days, people hospitalized with pneumonia were almost 2.4 times more likely to have a heart attack or stroke than people who hadn't been hospitalized with this infection.
Corrales-Medina says there is no way to tell from these data whether people who have pneumonia that isn't severe enough to require hospitalization are also at increased risk of having a cardiovascular event.
He said it's not currently known for sure why pneumonia appears to increase a person's risk of having a heart disease event, though other infections are also thought to increase the risk.
Dr. Liam Smeeth has published a number of studies looking at the possible links between infections and increased risk of heart disease. Smeeth, who heads the department of non-communicable diseases epidemiology at the London School of Hygiene and Tropical Medicine, said this phenomenon has also been seen with influenza, urinary tract infections and even chickenpox.
He said the Corrales-Medina study was a good one, but he disagrees with part of the interpretation of the data.
Smeeth believes the elevated risk seen in the days shortly after a pneumonia hospitalization does signify the infection increases a person's risk of having a heart attack or stroke.
But later on, he believes the increased risk seen in the study is not a signal that the earlier bout of pneumonia continues to stress the cardiovascular system. Instead, he believes what this shows is that the people who develop pneumonia are less healthy than those who don't, and more likely to develop cardiovascular disease.
"I don't think pneumonia necessarily causes an increased risk of heart attacks five years later. But I think people who tend to get pneumonia tend to be at higher risk of heart attacks and strokes," Smeeth said.
Dr. Jacob Udell, a cardiologist who has been studying the effect of influenza on heart disease risk, said the findings should make these patients and their doctors pay more attention to the potential consequences of infections like pneumonia.
"This should be a (wake-up) call and an eye-opener for anybody who thinks that these events are simply short-term things that have no long-lasting implications," said Udell, who was not involved with this study. He works at Toronto's Women's College Hospital.
He also suggested the patients and their doctors should strive to ensure that their cardiovascular disease risk factors that can be controlled — things like blood pressure and cholesterol levels — are well controlled. And steps should be taken to lower their risks of contracting influenza — which can lead to pneumonia — or other bouts of pneumonia.
That can be done by ensuring these individuals get annual flu shots and are vaccinated with the pneumococcal vaccine, which protects against Streptococcus pneumoniae, one of the causes of pneumonia.