When a sharp chest pain woke me up around 3 A.M., I had the obvious question: Was this truly panic-worthy? This had never happened to me before, and I'm in fairly good health—but I had lost one parent to a sudden, early death that may have been a cardiac event (we never learned for sure).

I may have the word “doctor” in my title, but I'm not that kind of doctor. I thought about dialing 911, but then I noticed that ... well, the pain was on the right side of my chest rather than the left. My breathing wasn't labored. My heart wasn't pounding. So like millions before me, I Googled my symptoms. On top of the screen was an article entitled “16 Causes of Right Side Chest Pain.” Bingo, I thought—except it was an ad. I moved on to the actual search results, which were headlined “17 Causes of Pain in the Right Side of the Chest” and “26 Causes of Chest Pain & Tightness.” When I got to “3 Types of Chest Pain That Won't Kill You,” I started wondering: What were all these bizarre articles?

Suddenly, my medically useless doctorate seemed to be more and more relevant. The titles were about gaming Google's search algorithm to grab people's attention at their vulnerable moments. This is called search-engine optimization, or SEO: the art and science of engineering for higher placement in Google search results and getting people to click on the links.

Unlike a lot of “medical information” online, SEO itself is steeped in the scientific method, which shows that this number-heavy format plays to a human cognitive bias called stand-out. We notice things that stand out—like oddly precise numbers. When I was a child in Turkey, my grandmother loved various over-the-counter remedies for maladies from the most minor to the serious, and many of them contained menthol. Menthol may not always have been the active ingredient, but it gave a soothing, medicinal aura to the lotions and rubs that filled her cupboard. Similarly, these odd, specific numbers add a scientific aura to the headlines.

I still needed information, though, so I clicked on a result from WebMD. I had seen that site before, and it didn't seem like it was quackery. I was barely a paragraph or two in when I noticed links about lung cancer symptoms. Huh? Lung cancer often causes no pain until its later stages. Then I realized that the information about lung cancer was an ad, but the “ad” notation was barely noticeable. During an emergency is obviously not the best time to scare people into clicking links for unlikely diseases. Indeed, if you clicked on these “lung cancer symptoms,” the browser took you eventually to a site advertising a lung cancer medication from Merck. Ugh.

Using inappropriate screenings and symptoms to advertise for drugs is not new at all. As early as 2010, WebMD had gotten in hot water for a depression screener consisting of 10 questions that, no matter how you answered, spat out the same answer: “You may be at risk for major depression.” You can almost smell the legalese: we all may be at risk for major depression anyway. No need for a quiz sponsored by Eli Lilly, a company that just happens to manufacture the antidepressant Cymbalta.

Having medical information online be financed by advertisers or pharmaceutical companies—or supplement manufacturers—is certainly not healthy. They often have an incentive to scare us. It's a lose-lose situation. Sometimes we do need to be worried and seek medical care. Other times it's just fearmongering for clicks. But who can tell when one is in crisis?

Finally, I looked up whether my own university had a health information site. Sure enough, there was a site with precise answers for exactly my question, the first statement being that “pinpointed chest pain” like mine was unlikely to be heart-related. Just then I remembered that I'd had a glass of carbonated water right before going to bed—a common cause of random but pinpointed chest and abdominal pain. My own “emergency” faded away, but the state of health information online remains dire.