Foamy stool may be related to improper diet, intestinal infection and chronic pancreatitis. 1. Improper diet: prolonged or excessive consumption of spicy, stimulating and greasy food will easily lead to increased exhaust, which will make the feces not easy to be shaped and then excrete foamy feces. 2. Intestinal infections: common intestinal infections include bacterial dysentery and acute gastroenteritis. For patients suffering from intestinal infections, their intestinal peristalsis is faster, so that the feces are not formed and discharged, and the amount of gas produced will increase, resulting in the discharge of foamy feces. 3. Chronic pancreatitis: Chronic pancreatitis inhibits the pancreas from secreting less, which affects the digestion of food and makes the feces foamy. Foamy stools can also be caused by other reasons. It is recommended that you go to the hospital in time, complete the examination to clarify the cause of the disease, and then give targeted treatment or therapy under the guidance of the doctor.