The gut flora (microbiota) plays an important role in human health through their metabolic function in breaking down ingested food to provide nutrients to cells and organs of the body.
However, some of the products of this metabolism have been associated with carcinogenic processes, such as tumor promotion (ammonia, secondary bile acids), mutagenesis (fecapenaenes), and carcinogenesis (N -nitroso compounds)  .
Gut Flora and Cancer
Studies have shown that diet plays a role in gut microflora metabolism and cancer development. For instance, a high-fat diet (HFD) amplified tumor growth and spread in a mouse cancer model. Interestingly, when fecal microbiota from these mice was transferred to the same mouse model previously treated with antibiotics, this was sufficient to transmit the cancer-potentiating effects of the HFD .
HFD can also prompt the microbiota to produce the secondary bile acids, lithocholic and deoxycholic acid, two dominant fecal bile acids that may contribute to carcinogenesis. Deoxycholic acid was shown to mediate the activation of a mitogenic and proinflammatory response program in hepatic stellate cells, which promotes liver cancer in mice .
Finally, the microbiota functions in drug metabolism, by influencing the toxicity and efficacy of chemotherapeutic compounds. It can stimulate immune cells to secrete reactive oxygen species (ROS) that enhance DNA damage and cell death of cancer cells, which are mediated by chemotherapeutic compounds  .
Any unbalance in the microbiota that is caused by an unbalanced diet, particularly an HFD, can promote the production by the microbiota of carcinogenic metabolic products. It can also prevent the action of immune cells in promoting the effect of chemotherapies.
 Schulz, M.D., Atay, Ç., Heringer, J., Romrig, F.K., Schwitalla, S., Aydin, B., Ziegler, P.K., Varga, J., Reindl, W., Pommerenke, C. and Salinas-Riester, G., 2014. High-fat-diet-mediated dysbiosis promotes intestinal carcinogenesis independently of obesity. Nature, 514(7523), pp.508-512.
 Yoshimoto, S., Loo, T.M., Atarashi, K., Kanda, H., Sato, S., Oyadomari, S., Iwakura, Y., Oshima, K., Morita, H., Hattori, M. and Honda, K., 2013. Obesity-induced gut microbial metabolite promotes liver cancer through senescence secretome. Nature, 499(7456), pp.97-101.