The eyelid contains hair follicles and meibomian glands. The meibomian glands secrete an oil that acts as a barrier to prevent the evaporation of tears. Infection in either a hair follicle or a meibomian gland produces a sty, also called a hordeolum, which is a small abscess that comes to a head.
An uninfected meibomian gland may become plugged, resulting in the development of a nontender swelling on the eyelid called a chalazion. Chalazions tend to occur in older dogs. They remain relatively static and only require treatment if they are getting larger.
Treatment: A dog with a sty should be placed on oral and topical antibiotics, as described for blepharitis. Applying warm compresses to the eyelid three or four times a day is beneficial in bringing the sty to a head. If the sty does not rupture on its own, your veterinarian may puncture it with a sterile needle or a scalpel.
Chalazions are removed surgically. Do not squeeze the chalazion in an attempt to express its contents. If the chalazion ruptures into the eyelid, the oily contents set up a severe inflammatory reaction that is very difficult to treat.