Postweaning diarrhea (PWD) in pigs is a leading cause of economic loss in pork production worldwide. The current practice of using antibiotics and zinc to treat PWD is unsustainable due to the potential of antibiotic resistance and ecological disturbance, and novel methods are required. In this study, an in vitro model was used to test the possibility of producing prebiotic fiber in situ in the gastrointestinal (GI) tract of the piglet and the prebiotic activity of the resulting fiber in the terminal ileum. Soluble fiber was successfully produced from potato pulp, an industrial waste product, with the minimal enzyme dose in a simulated upper GI tract model extracting 26.9% of the initial dry matter. The fiber was rich in galactose and galacturonic acid and was fermented at 2.5, 5, or 10 g/liter in a glucose-free medium inoculated with the gut contents of piglet terminal ileum. Fermentations of 5 g/liter inulin or 5 g/liter of a purified potato fiber were used as controls. The fibers showed high fermentability, evident by a dose-dependent drop in pH and an increase in the organic acid content, with lactate in particular being increased. Deep sequencing showed a significant increase in the numbers of Lactobacillus and Veillonella organisms and an insignificant increase in the numbers of Clostridium organisms as well as a decrease in the numbers of Streptococcus organisms. Multivariate analysis showed clustering of the treatment groups, with the group treated with purified potato fiber being clearly separated from the other groups, as the microbiota composition was 60% Lactobacillus and almost free of Clostridium. For animal studies, a dosage corresponding to the 5-g/liter treatment is suggested.