Tooth decay is caused by bacteria that live in the plaque in your mouth which react with sugary and starchy deposits from food you eat. This reaction produces acid which damages the enamel over time and weakens the tooth. Eventually, these acid-producing bacteria can cause a hole in the tooth and even cause nerve damage.
The best way to prevent tooth decay is by following recommended oral hygiene practices and following through with regular, 6-month checkups.