Intraflagellar transport (IFT) is a conserved mechanism essential for the assembly and maintenance of most eukaryotic cilia and flagella. However, little is known about its role in sperm flagella formation and male fertility. IFT140 is a component of IFT-A complex. In mouse, it is highly expressed in the testis. Ift140 gene was inactivated specifically in mouse spermatocytes/spermatids. The mutant mice did not show any gross abnormalities, but all were infertile and associated with significantly reduced sperm number and motility. Multiple sperm morphological abnormalities were discovered, including amorphous heads, short/bent flagella and swollen tail tips, as well as vesicles along the flagella due to spermiogenesis defects. The epididymides contained round bodies of cytoplasm derived from the sloughing of the cytoplasmic lobes and residual bodies. Knockout of Ift140 did not significantly affect testicular expression levels of selective IFT components but localization of IFT27 and IFT88, two components of IFT-B complex, was changed. Our findings demonstrate that IFT140 is a key regulator for male fertility and normal spermiogenesis in mice. It not only plays a role in sperm flagella assembling, but is also involved in critical assembly of proteins that interface between the germ cell plasma and the Sertoli cell.