Yes, foods like onions and garlic can contribute to temporary bad breath, but persistent bad breath may have other causes.