A stye forms when bacteria, almost always Staphylococcus aureus, infect one of the tiny oil glands along your eyelid margin. These glands normally produce a thin layer of oil that keeps your tears from evaporating too quickly. When one gets clogged, the trapped oil becomes a breeding ground for bacteria that already live on your skin, and the result is that painful, red bump you’re dealing with now.
The good news: styes are extremely common and usually resolve on their own within one to two weeks. But understanding what triggered yours can help you prevent the next one.
What Actually Happens Inside Your Eyelid
Your eyelids contain dozens of oil-producing glands. The smaller ones sit right at the base of your eyelashes, while larger ones called meibomian glands line the inner eyelid. When one of these glands gets blocked, its secretions thicken and stagnate. Bacteria that normally coexist harmlessly on your skin then move in and multiply, triggering the infection and inflammation you see as a stye.
An external stye, the more common type, forms at the root of an eyelash where the smaller glands are located. An internal stye develops deeper in the eyelid when a meibomian gland gets infected. Internal styes tend to be more painful because they press against the eyeball, but both types follow the same basic process: blocked oil, bacterial overgrowth, swelling.
The Most Likely Reasons You Got One
Several everyday habits and conditions make stye development more likely. You may recognize more than one of these in your own routine.
Touching Your Eyes
This is the single easiest way to introduce bacteria to your eyelids. Rubbing your eyes with unwashed hands, adjusting contact lenses without cleaning your fingers first, or even resting your face in your palms can transfer Staph bacteria directly to the gland openings along your lash line.
Old or Shared Eye Makeup
Mascara wands and eyeliner pencils collect bacteria every time they touch your lashes and lid margin. The FDA notes that eye-area cosmetics have a more limited safe shelf life than other products, and industry experts recommend replacing mascara every three months. Sleeping in eye makeup is another common trigger because it blocks gland openings overnight, giving bacteria hours to multiply in trapped oil.
Chronic Eyelid Inflammation
If you get styes repeatedly, the underlying issue is often a condition called meibomian gland dysfunction. This happens when the oil glands in your eyelids don’t produce enough oil or produce oil of poor quality. The glands become chronically blocked, which sets the stage for repeated infections. Left untreated, meibomian gland dysfunction can also cause dry eye syndrome and ongoing eyelid inflammation known as blepharitis.
Stress and Poor Sleep
There’s no clinical study definitively proving that stress causes styes, but many eye specialists report seeing the connection in their patients. The likely explanation is indirect: stress hormones suppress your immune system, making your body less effective at keeping normal skin bacteria in check. Sleep deprivation has a similar effect. Research shows that poor sleep specifically reduces the ability of certain immune cells (T cells) to fight off infections. One 2017 study found that stress hormones can be converted into compounds that actually help bacteria colonize vulnerable areas of the body.
Microscopic Eyelash Mites
This one sounds alarming, but tiny mites called Demodex live in the hair follicles of most adults without causing any problems. In some people, though, their populations grow large enough to contribute to chronic eyelid inflammation and recurring styes. Research has shown that Demodex plays a significant role in treatment-resistant blepharitis. If you keep getting styes despite good hygiene, your eye doctor can check for elevated mite counts by examining a few eyelashes under a microscope.
Stye vs. Chalazion
Not every eyelid bump is a stye. A chalazion looks similar at first, and during the first two days the two can be impossible to tell apart. The key difference is that a stye stays painful and sits right at the eyelid margin, while a chalazion gradually becomes a painless, firm nodule closer to the center of the eyelid. A chalazion is caused by a blocked gland without active bacterial infection, so it’s essentially a cyst rather than an abscess. Chalazia often develop when a stye doesn’t fully drain.
How to Treat a Stye at Home
Warm compresses are the cornerstone of stye treatment. Soak a clean washcloth in warm water, wring it out, and hold it gently against your closed eyelid for five minutes. Do this several times a day. The heat softens the hardened oil plug and encourages the gland to drain on its own. You can reheat the washcloth as it cools.
Resist the urge to squeeze or pop a stye. Forcing it open can spread the infection into surrounding tissue. Let it come to a head and drain naturally. While it heals, avoid wearing eye makeup and contact lenses if possible. Keep the area clean, but don’t scrub aggressively.
Most styes resolve within one to two weeks with nothing more than warm compresses and patience.
Signs That Need Medical Attention
Rarely, a stye can progress to a more serious infection called preseptal cellulitis, where bacteria spread into the soft tissue surrounding the eye. Warning signs include redness and swelling that spread well beyond the bump itself, a fever, increasing pain, vision changes, or any bulging of the eye. If the infection crosses deeper into the eye socket (orbital cellulitis), it becomes a medical emergency. These complications are uncommon, but if swelling is getting worse rather than better after a few days of warm compresses, it’s worth having an eye doctor take a look.
Preventing the Next One
Once you’ve had a stye, you’re somewhat more likely to get another, especially if the underlying gland dysfunction hasn’t been addressed. A few practical habits lower your risk significantly:
- Wash your hands before touching your face or handling contact lenses.
- Replace mascara every three months and never share eye makeup.
- Remove all eye makeup before bed, every night.
- Clean your eyelids regularly if you’re prone to oily or flaky lids. A gentle wipe with a warm, damp washcloth along the lash line each morning can keep gland openings clear.
- Manage dry eye or blepharitis if you’ve been diagnosed with either. Treating the underlying gland dysfunction is the most effective way to stop styes from recurring.

