Pregnancy is a very complex and highly stressful time in which women become more physically and emotionally vulnerable. Therefore, mothers are more likely to face decreased self-esteem and increased postpartum depression. Despite the high prevalence of postpartum depression, more than 50 % of mothers are undiagnosed or untreated, showing an urgent need to explore an effective preventive strategy. A healthy lifestyle and regular physical activity have been suggested to be associated with an increased quality of life in pregnant and postpartum women. The purpose of this study was to determine whether swimming exercise before and during pregnancy can affect maternal care and postpartum depression-related behaviors in dams. To this end, female NMRI and C57BL/6 J mice were subjected to swimming exercise before conception and throughout pregnancy. On postpartum days 1–2, maternal behavior including nest building, active nursing, and licking/grooming were monitored. A battery of behavioral tests was also used to measure depression-related symptoms including anhedonia- and anxiety-like behavior, social behavior, and behavioral despair. To identify the underlying mechanisms, corticosterone and inflammatory cytokines during late pregnancy, and corticosterone and brain serotonin during the postpartum period were measured in dams. The findings indicated that swimming exercise increased gestational corticosterone, decreased maternal care and brain serotonin, and increased all depression-related behaviors in postpartum C57BL/6 J dams, while only increased licking/grooming and social behavior, and reduced anhedonia-like behavior in postpartum NMRI dams. Taken together, this study suggests that swimming exercise before and during pregnancy could alter maternal care and postpartum depression-like behavior in a strain-dependent manner.