Cow’s milk protein allergy (CMPA) is an immune response to cow’s milk proteins, which is one of the most common food allergies in infants and young children. It is estimated that 2–3% of infants and young children have CMPA. The diet, gut microbiota, and their interactions are believed to be involved in the alterations of mucosal immune tolerance, which might lead to the development of CMPA and other food allergies. In this review, the potential molecular mechanisms of CMPA, including omics technologies used for analyzing microbiota, impacts of early microbial exposures on CMPA development, and microbiota–host interactions, are summarized. The probiotics, prebiotics, synbiotics, fecal microbiota transplantation, and other modulation strategies for gut microbiota and the potential application of microbiota-based design of diets for the CMPA treatment are also discussed. This review not only summarizes the current studies about the interactions of CMPA with gut microbiota but also gives insights into the possible CMPA treatment strategies by modulating gut microbiota, which might help in improving the life quality of CMPA patients in the future.