Mother’s milk contains a unique microbiome that plays a relevant role in offspring health. We hypothesize that maternal malnutrition during lactation might impact the microbial composition of milk and affect adequate offspring gut colonization, increasing the risk for later onset diseases. Then, Wistar rats were fed ad libitum (Control, C) food restriction (Undernourished, U) during gestation and lactation. After birth, offspring feces and milk stomach content were collected at lactating day (L)4, L14 and L18. The V3–V4 region of the bacterial 16S rRNA gene was sequenced to characterize bacterial communities. An analysis of beta diversity revealed significant disparities in microbial composition between groups of diet at L4 and L18 in both milk, and fecal samples. In total, 24 phyla were identified in milk and 18 were identified in feces, with Firmicutes, Proteobacteria, Actinobacteroidota and Bacteroidota collectively representing 96.1% and 97.4% of those identified, respectively. A higher abundance of Pasteurellaceae and Porphyromonas at L4, and of Gemella and Enterococcus at L18 were registered in milk samples from the U group. Lactobacillus was also significantly more abundant in fecal samples of the U group at L4. These microbial changes compromised the number and variety of milk–feces or feces–feces bacterial correlations. Moreover, increased offspring gut permeability and an altered expression of goblet cell markers TFF3 and KLF3 were observed in U pups. Our results suggest that altered microbial communication between mother and offspring through breastfeeding may explain, in part, the detrimental consequences of maternal malnutrition on offspring programming.