Bacterial and viral infections have many things in common. Both types of infections are caused by microbes — bacteria and viruses, respectively — and spread by things such as: Coughing and sneezing. Contact with infected people, especially through kissing and sex. Contact with contaminated surfaces, food, and water. Contact with infected creatures, including pets, livestock, and insects such as fleas and ticks. Microbes can also cause: Acute infections, which are short-lived. Chronic infections, which can last for weeks, months, or a lifetime. Latent infections, which may not cause symptoms at first but can reactivate over a period of months and years. Most importantly, bacterial and viral infections, can cause mild, moderate, and severe diseases.