Updated

If you've seen a case of pink eye such as the inflamed eyes that NBC sportscaster Bob Costas is sporting during the current Winter Olympics you know it looks even worse than it sounds.

Pink eye, also known as conjunctivitis, develops when the transparent membrane, or conjunctiva, lining the eyelid and the white part of the eyeball gets inflamed. This has three main causes: an allergic reaction, a viral infection or a bacterial infection.

You can get pink eye from someone else if their bacterial or viral infection passes to you, making this a very common and contagious malady. (If your eye suffers an allergic reaction, it is not, of course, contagious.)

The most obvious symptom appears in the form of those reddened whites in your eye. Inflammation or swelling from pink eye makes blood vessels more visible, causing the redness. Pink eye can also cause itchy and watery eyes, discharge that forms a dry crust overnight, swelling of the eyelids, cloudy vision and light sensitivity. [The 14 Oddest Medical Case Reports]

Treatment depends on the cause, though most cases get better on their own: For allergic reactions, remove contact with the allergen (e.g., pet dander). Your doctor may prescribe an antibiotic for the bacterial variety. Antibiotics don't affect viruses, so you just have to wait out viral conjunctivitis: It usually resolves in two or three weeks.

To ease the symptoms of pink eye, apply a cold compress to allergic conjunctivitis and a warm compress to viral or bacterial pink eye. In all cases, eyedrops can help alleviate dryness.

Contact lens wearers with pink eye should stop wearing their contact lenses and consult with an eye care specialist if symptoms don't get better within 24 hours.

A few precautions can help stop the spread of contagious pink eye: Most importantly, wash your hands; don't share pillows, towels or washcloths with people who have pink eye; throw away any eyeliner or other cosmetics that may have been contaminated; and avoid touching your eyes.

Copyright 2014 LiveScience, a TechMediaNetwork company. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.