For people that take SSRIs (a specific type of antidepressant medication that affects a compound in the brain called serotonin), they are a great, commonly-prescribed treatment for depression.

But in about half the population, the opposite is true — SSRIs are just as likely to make depression symptoms worse as they are to help alleviate them, according to numerous studies.

Even worse: we have no way of knowing if the drugs will work until the patients try them.

That’s a major flaw in how we handle mental illness.

Luckily, scientists might have just cracked the code to determine if an SSRI will work, before a patient pops a single pill.

As depression symptoms improve, a certain brain region called the anterior cingulate cortex (ACC) becomes more active. The ACC is one of the chunks of our brain that helps us control our emotions and makes us capable of complex thoughts, and we can trace its behavior to tell whether or not a particular antidepressant is going to help a patient. At least, that was the conclusion of a study published yesterday in JAMA Psychiatry.

For years, doctors have known to look at this part of the brain, which is found right behind your forehead, as an indicator of depression. But studies looking at ways to use that analysis in the clinic — experiments often only examined a small number of patients, so the findings might not pertain to more extreme cases. Some didn’t compare the effects of antidepressants vs placebo on the ACC, so they couldn’t actually claim that the antidepressant was doing anything. Plus, no one had looked at how this phenomenon varied among demographics like race and gender. So, yeah, if this was going to get more solid, the science really needed to catch up.

This new research had much more promising methods, adding weight to the study’s findings. It was conducted over four years and included several hundred patients. The researchers found that, after just one week of medication, a change in a patient’s anterior cingulate cortex activity would indicate whether or not an antidepressant was going to work. This was the case regardless of a patient’s demographic, and independent of other variables that had tripped up previous experiments.

Granted, it’s not yet commonplace for psychiatrists and GPs to take brain measurements like these. But if they do become more widely used, patients could waste less time finding the treatment they need. It’s an important step towards the personalized healthcare that people with depression deserve.