Pediatricians may recommend a stool pH test if a child exhibits symptoms such as chronic diarrhea, unexplained weight loss, abdominal pain, or failure to thrive. It is also useful for diagnosing conditions like lactose intolerance, where the body cannot properly digest lactose, leading to acidic stool.