The invention relates to a traditional Chinese medicine for treating swine fever and a preparation method thereof. The traditional Chinese medicine comprises following traditional Chinese medicine raw materials in parts by weight: cordate houttuynia, sweet wormwood, isatis root, dandelion, reed rhizome, honeysuckle flower, radix scutellariae, fructus forsythiae, patrinia herb, coix seed, Chinese yam, balloonflower root, grosvenor momordica fruit, belamcanda rhizome, earthworm, radix scrophulariae, dried rehmannia root, dried orange peel, oldenlandia diffusa and motherwort. The traditional Chinese medicine is prepared by reasonable compatibility, and by steps of sterilizing, drying, smashing, cleaning, dipping, decocting for the first time, decocting for a second time, mixing, concentrating, drying and combining. The traditional Chinese medicine has an antiviral function and functions of clearing away heat, detoxifying, relieving cough, relieving asthma, eliminating phlegm, and the like, and has good curative effects for pneumonia, enteritis, tonsillitis, conjunctivitis, and the like which are caused by viruses. The traditional Chinese medicine overcomes a reproductive disturbance problem of sicken sows. The curative rate of the traditional Chinese medicine for acute and chronic swine fever can be higher than 95%. Long-term taking of the traditional Chinese medicine can boost body immunity of pigs. The traditional Chinese medicine avoids medicine residue, guarantees the pork quality, and prevents the swine fever.