It is best to avoid milk and other dairy products during a stomach flu until diarrhea has subsided, according to Brown University. A stomach flu typically lasts around 1 to 3 days, but it can take a week or longer until diarrhea from the stomach flu has completely gone away.
When a person has a stomach flu, it's also recommended to avoid spicy foods, alcohol, caffeinated beverages, whole grain breads, raw and dried vegetables and dried peas and beans. A good diet during a stomach flu consists of clear soups and broth, water, plain saltine crackers, Gatorade, popsicles and decaffeinated teas. Staying hydrated during a stomach flu is important, but only small amounts of liquids should be consumed at a time to ensure the stomach can handle it.