What Causes Cavities in Teeth: Bacteria, Plaque & More

Cavities form when acids produced by bacteria in your mouth dissolve the hard mineral surface of your teeth. This process isn’t instant. It’s the result of a repeating cycle where bacterial acid attacks outpace your mouth’s natural ability to repair itself. Roughly 27.5% of the global population has untreated cavities in their permanent teeth, making dental decay one of the most common chronic conditions in the world.

How Bacteria Turn Sugar Into Acid

Your mouth is home to hundreds of species of bacteria, but one group in particular drives most cavities. These bacteria thrive in dental plaque, the sticky film that coats your teeth throughout the day. When you eat or drink something containing sugar or refined carbohydrates, these bacteria break down the sugars through a rapid fermentation process, producing large amounts of acid as a byproduct.

That acid lowers the pH inside the plaque sitting on your teeth. Tooth enamel, the hardest substance in your body, starts to dissolve when the pH at its surface drops below about 5.5. For context, a healthy mouth normally sits around pH 6.7 to 7.4. Every time you eat something sugary, the pH in plaque can drop below that critical 5.5 threshold within minutes, and it stays there for 20 to 30 minutes before your saliva can bring it back up. During that window, calcium and phosphate minerals leach out of the enamel in a process called demineralization. One acid attack won’t cause a cavity. But dozens of them, day after day, eventually weaken the enamel enough to create a hole.

Why Frequency of Sugar Matters More Than Amount

The total amount of sugar you eat matters less than how often you eat it. Each time sugar enters your mouth, it triggers a fresh acid attack lasting roughly half an hour. If you eat a candy bar in one sitting, your teeth endure one prolonged acid exposure. But if you sip a sugary coffee over three hours, or snack on crackers every 30 minutes, you’re resetting the acid clock over and over, giving your teeth almost no recovery time between attacks.

The sugars most strongly linked to cavities are what the World Health Organization calls “free sugars”: any sugar added to food or drinks during preparation, plus sugars naturally present in honey, syrups, fruit juices, and fruit juice concentrates. Table sugar, high-fructose corn syrup, and glucose all qualify. Starchy refined carbohydrates like white bread and chips also break down into sugars in the mouth, though more slowly. Whole fruits, by contrast, pose much less risk because their sugars are locked inside fiber and require more chewing, which stimulates saliva.

How Plaque Builds Up on Your Teeth

Within seconds of brushing, a thin protein layer from your saliva coats every tooth surface. This film, called the pellicle, is harmless on its own, but it acts as a landing pad for bacteria. Within 24 hours, bacteria have colonized that film and begun forming structured communities known as biofilm, or dental plaque.

As the biofilm matures over the next several days, it becomes more complex. Early colonizers are joined by additional bacterial species, and the community develops a protective matrix that makes it harder to dislodge. If plaque isn’t removed through brushing and flossing, it can mineralize into calculus (tarite) in as little as 10 to 20 days. At that point, only a dental professional can remove it. The longer plaque sits undisturbed on a tooth, the more acid it produces in direct contact with the enamel, and the faster decay progresses.

Your Saliva Is Your Best Natural Defense

Saliva does far more than keep your mouth moist. It’s a sophisticated repair system. It physically rinses food particles and loose bacteria off your teeth. It delivers calcium and phosphate ions back to weakened enamel, actively reversing early mineral loss. And it contains bicarbonate, a buffering agent that neutralizes bacterial acids and brings plaque pH back to safe levels within minutes of an acid attack.

When salivary flow increases, such as during chewing, the concentration of bicarbonate rises significantly. This is one reason sugar-free gum after meals can help protect teeth: it stimulates saliva production right when you need buffering the most. On the flip side, anything that reduces saliva flow dramatically increases cavity risk. Hundreds of common medications (antihistamines, antidepressants, blood pressure drugs) list dry mouth as a side effect. People with chronically low saliva production can develop rampant cavities in a matter of months, even on teeth that were previously healthy, because the acid-neutralizing and remineralization cycle is constantly disrupted.

Tooth Shape and Location Create Vulnerable Spots

Not every surface of every tooth faces the same risk. Your back teeth (molars and premolars) have deep grooves and pits on their chewing surfaces called fissures. These fissures can be so narrow that toothbrush bristles physically cannot reach the bottom. Food particles and bacteria get trapped inside, creating a sheltered environment where acid can work against enamel with little interference from saliva or brushing. This is why the chewing surfaces of molars are the single most common location for cavities, especially in children and teenagers whose teeth are relatively new.

The spaces between teeth are another high-risk zone. Plaque accumulates in these tight contact points and can only be removed by floss or interdental brushes. Areas along the gumline are similarly vulnerable, particularly in older adults whose gums have receded to expose the root surface. Root surfaces lack the thick enamel shield that covers the crown of the tooth, so they dissolve more easily and at a higher pH than enamel does.

Other Factors That Raise Your Risk

Cavities aren’t purely a hygiene problem. Several factors beyond brushing and diet influence whether you’ll develop them.

  • Fluoride exposure: Fluoride integrates into tooth enamel and makes it more resistant to acid dissolution. It also promotes remineralization and can inhibit bacterial acid production. People who drink unfluoridated water and don’t use fluoride toothpaste have measurably higher rates of decay. For children under six, fluoride varnish applied by a dentist is the primary professional preventive measure. For older children and adults at elevated risk, prescription-strength fluoride products offer additional protection.
  • Genetics and enamel quality: Some people are born with thinner enamel, deeper tooth fissures, or saliva that’s less effective at buffering acid. These variations help explain why two people with similar diets and brushing habits can have very different cavity histories.
  • Acid reflux and vomiting: Stomach acid is far more acidic than anything bacteria produce, with a pH around 1 to 2. Frequent exposure from conditions like gastroesophageal reflux or eating disorders erodes enamel rapidly, especially on the inner surfaces of upper teeth.
  • Mouth breathing and orthodontic appliances: Anything that dries out the mouth or creates extra surfaces for plaque to cling to increases risk. Braces, retainers, and even sleeping with your mouth open can shift the balance toward decay.

How a Cavity Actually Progresses

Decay doesn’t go from healthy tooth to painful cavity overnight. It moves through stages, and the earliest stage is reversible. The first sign is usually a white spot on the enamel, an area where minerals have been lost but no actual hole has formed yet. At this point, improving fluoride exposure, reducing sugar frequency, and maintaining consistent plaque removal can allow the enamel to remineralize and heal itself.

If the acid attacks continue, the surface breaks down and a true cavity forms in the enamel. You typically won’t feel anything at this stage. Once decay penetrates through the enamel into the softer layer underneath (dentin), it spreads more quickly because dentin is less mineralized and dissolves at a higher pH. This is often when sensitivity to sweets or cold appears. Left untreated, the decay eventually reaches the innermost pulp of the tooth, which contains nerves and blood vessels. That’s when the sharp, persistent pain most people associate with a “bad cavity” kicks in, and the tooth typically needs more extensive treatment or extraction.

The entire process from white spot to deep decay can take months to years depending on your diet, saliva, fluoride exposure, and how consistently you disrupt the plaque on your teeth. Europe is the only world region where cavity rates have been declining in both baby and permanent teeth, largely attributed to widespread fluoride use and public health programs. Everywhere else, rates have remained stable or increased.