The swelling of the upper eyelid can be caused by various factors. Common causes include infections such as a stye (an infection of the eyelid gland) or chalazion (blockage of an oil gland causing a lump), allergies to substances like pollen or pet dander, fluid retention due to systemic health conditions, and inflammatory conditions like blepharitis. Other causes may include conjunctivitis (pink eye), injury or trauma to the area, blocked tear ducts, and more serious infections like orbital cellulitis. Sometimes, eyelid swelling can also be linked to underlying systemic conditions such as thyroid disorders like Graves' disease. The swelling can come with other symptoms like redness, pain, tenderness, itchiness, or discharge depending on the cause. If the swelling persists, worsens, or is accompanied by severe pain, vision changes, or fever, it is important to seek medical attention for proper diagnosis and treatment.