Early childhood is a critical period for development, and early life stress may increase the risk of gastrointestinal diseases including irritable bowel syndrome (IBS). In rodents, neonatal maternal separation (NMS) induces bowel dysfunctions that resemble IBS. However, the underlying mechanisms remain unclear. Here we show that NMS induces expansion of intestinal stem cells (ISCs) and their differentiation toward secretory lineages including enterochromaffin (EC) and Paneth cells, leading to EC hyperplasia, increased serotonin production, and visceral hyperalgesia. This is reversed by inhibition of nerve growth factor (NGF)-mediated tropomyosin receptor kinase A (TrkA) signalling, and treatment with NGF recapitulates the intestinal phenotype of NMS mice in vivo and in mouse intestinal organoids in vitro. Mechanistically, NGF transactivates Wnt/β-catenin signalling. NGF and serotonin are positively correlated in the sera of diarrhea-predominant IBS patients. Together, our findings provide mechanistic insights into early life stress-induced intestinal changes that may translate into treatments for gastrointestinal diseases.