Food allergies occur when the immune system reacts abnormally to specific proteins in certain foods, treating them as harmful invaders. This immune response can lead to a wide range of symptoms, some of which can be severe or life-threatening, often called anaphylaxis, that may involve respiratory problems and shock.