Eye infections are common. They can be caused by bacteria, fungi, viruses or parasites. They may affect different parts of the eye. One eye or both may become infected.