It is one of the most effective ways to protect our health: herd immunity. By vaccinating the vast majority of people in a population, we can guard against the spread of potentially deadly infections. When we allow this collective immunity to dissipate, the results can be devastating — sometimes even for people who have been vaccinated. Just ask my patient J.

J.’s ordeal began with a routine dinner at an Italian restaurant in Culver City, Calif., in October. A few days later, his wife called me with the news of a possible measles case at the restaurant the same day. I wasn’t worried because J. had attended Los Angeles public schools, which require vaccinations, and a key vaccine such as MMR (measles/mumps/rubella) would not have slipped through the cracks.

A few days later, J.’s wife called again. He now had a low-grade fever but no rash. It seemed likely that the measles exposure was a coincidence, but we both were concerned.

Measles is rare in clinical practice because well over 90% of the population is immune, either from the MMR vaccine or from childhood disease in the decades before the 1960s, when the vaccination became available. In 30 years of medical practice, I’ve seen only two measles cases and I was far from confident I could recognize a third.

J.’s wife made my job easier by emailing photos that might have come from a medical textbook. J.’s mouth had erupted in white patches known as Koplik spots, a diagnostic feature of measles. A blotchy rash covered his face. His fever spiked to 102.

Worse yet, before he could have known he might be getting measles, J. and his family visited Disneyland, where he gradually became clammy and uncomfortable. The trip to Disneyland was a serious stroke of bad luck. Hundreds if not thousands of people might have been exposed.

The following day, we tested J. for measles, and the results, two days later, confirmed that he was in the grip of this dangerous disease. By then, his temperature had reached 103.8 and was resistant to the medication used to control fevers. His eyes turned yellow (jaundiced) as the measles affected his liver. J. tried to drink fluids, but nausea limited his intake.

J. has slowly recovered, but this health crisis was avoidable. He did his part, as his parents had when he was a child. Blood tests confirmed that he had been vaccinated with MMR. But like about 1% of individuals vaccinated with MMR, J. did not develop protective antibodies. Individuals like J. depend upon herd immunity to protect them.

When communities hit that “sweet spot,” the level of immunity in the population that prevents the virus from finding susceptible individuals, outbreaks spontaneously die out.

But when people who could be safely vaccinated (which is nearly everyone) fail to do so, they weaken the community’s ability to resist the spread of a contagious disease, putting J. and others like him at risk.

Vaccine effectiveness isn’t a matter of opinion. It’s scientific fact. We need to act responsibly. That means getting ourselves and our children vaccinated for flu, measles and other infections to protect ourselves, our families and our communities.

Daniel J. Stone is an internal medicine and geriatric medicine specialist in Los Angeles.