Intestinal epithelial cells (IECs) absorb nutrients, respond to microbes, provide barrier function and help coordinate immune responses. We profiled 53,193 individual epithelial cells from mouse small intestine and organoids, and characterized novel subtypes and their gene signatures. We showed unexpected diversity of hormone-secreting enteroendocrine cells and constructed their novel taxonomy. We distinguished between two tuft cell subtypes, one of which expresses the epithelial cytokine TSLP and CD45 (Ptprc), the pan-immune marker not previously associated with non-hematopoietic cells. We also characterized how cell-intrinsic states and cell proportions respond to bacterial and helminth infections. Salmonella infection caused an increase in Paneth cells and enterocytes abundance, and broad activation of an antimicrobial program. In contrast, Heligmosomoides polygyrus caused an expansion of goblet and tuft cell populations. Our survey highlights new markers and programs, associates sensory molecules to cell types, and uncovers principles of gut homeostasis and response to pathogens.