Herd immunity occurs when a significant portion of the population becomes immune to a disease, either through vaccination or prior infection, thereby reducing the likelihood of disease spread. This form of indirect protection is crucial for protecting vulnerable individuals who cannot be vaccinated.