The epicardium is the important outermost mesothelial/epithelial layer of the heart that serves as a signaling center for cardiac development and repair. During heart development, epicardial cells undergo a process known as epithelial-to-mesenchymal transition to form diverse mesenchymal cell lineages, such as fibroblasts, coronary vascular smooth muscle cells, and pericytes. However, it is not clear whether the reverse process, mesenchymal-to-epithelial transition (MET), takes place in the mammalian heart. In this study, we performed apical resection on neonatal hearts and usedFap-CreER;Ai9labeling to track activated fibroblasts in the injured cardiac regions. We found that these fibroblasts underwent MET to generate epicardial cells during heart regeneration. To our knowledge, this is the first report of MET occurring in vivo during heart development and regeneration. Our findings suggest that it is feasible to directly convert fibroblasts into epicardial cells, providing a novel approach to generate epicardial cells.Supplementary InformationThe online version contains supplementary material available at 10.1186/s13287-023-03391-8.