Hydrogen peroxide is a very pale blue liquid that appears colorless when diluted. For use in homes, diluted hydrogen peroxide (usually 3%) can serve many purposes. It is considered a disinfectant. As a result, it can be used in cleaning and getting rid of bacteria from external infections, cuts and bruises. It should never be swallowed.
Hydrogen peroxide will reduce bacteria from a mouth infection that is outside the tooth. For example, hydrogen peroxide can reduce bacteria that cause a gum infection. On the other hand, it will not help a diseased tooth in need of a root canal. This is because the diseased pulp (nerve tissue) is inside the tooth. Hydrogen peroxide is not able to seep into the tooth.
Although hydrogen peroxide is an efficient disinfectant, it will not "cure" a tooth infection. If you have a tooth infection, the cause needs to be addressed. Even in the case of gum disease, the hydrogen peroxide will offer only temporary relief.
If you have signs of a tooth infection or are feeling pain, I suggest that you have a professional examination and receive treatment to correct the problem.