If you have HIV/AIDS and are plagued with chronic headaches, researchers offer this remedy: Take your HIV meds—every dose, every time.

Well, it’s not quite that simple. But a recent study of women and men with HIV—74 percent of them African American—concluded that people whose virus is uncontrolled experience more headaches, especially migraines, than those whose HIV is well-controlled. In the study, 88 percent of the participants were on HIV meds, so researchers think people who got headaches probably missed doses or used an ineffective regimen.

The people with lower CD4 cell counts (averaging 327 compared with 586) had more severe, frequent and disabling headaches—but had been positive a shorter period of time—than those with higher CD4 counts. As Todd Smitherman, PhD, a lead researcher, told Real Health, “Strict adherence to prescribed HIV regimens is critical, as is keeping regular follow-up visits with physicians to monitor [health] status.”

If you are an HIV-positive headache sufferer and you smoke, here’s another remedy: Stop. As Smitherman explains, “For some, smoking may act as a [trigger] of migraine.”