The invention relates to a traditional Chinese medicine formula for treating male infertility. The traditional Chinese medicine formula consists of 16 traditional Chinese herbal medicines including male silkworm moth, baked pangolin scales, tortoiseshells, agilawood, antler tablets, unprocessed rehmannia glutinosa, dogwood, cistanche, herba epimedii, peony bark, golden cypress, semen plantaginis, lycium barbarum, paeonia lactiflora, yam rhizome and poria cocos. Pharmacology experiments show that the traditional Chinese medicine formula has the effects of nourishing yin and clearing heat, tonifying kidney and generating seminal fluid, tonifying spleen and removing dampness as well as activating blood and removing stasis, testis, epididymis seminal vesicle and prostate can be nourished, the amount of sperms is increased, and the testicular spermatogenic function is covered; the traditional Chinese medicine formula has a remarkable effect in treating kidney-yin deficiency type semen quality abnormity and semen volume abnormity, immune infertility and unknown cause infertility.