A cavity is a small hole that forms inside the tooth and is caused by tooth decay. Cavities are formed when plaque buildup on the outside of the tooth combines with sugars and starches in the food you eat. This can produce an acid that can eat away the enamel on your tooth. If a cavity is left untreated, it can lead to more serious oral health problems. Cavities can be prevented by remembering to brush your teeth at least three times a day, and floss in between teeth at least once.