The invention discloses modified-diatomite-containing organic fertilizer and a preparation method thereof. The modified-diatomite-containing organic fertilizer is prepared from the following raw materials in parts by weight: 30 to 50 parts of egg shell, 15 to 25 parts of modified diatomite, 20 to 30 parts of EM (Effective Microorganism) stock solution, 10 to 20 parts of seaweed extract, 10 to 20 parts of ground phosphate rock, 8 to 16 parts of wormcast, 6 to 12 parts of pine needle meal, 5 to 9 parts of urea, 7 to 13 parts of biochar, 6 to 14 parts of sugar residues, 2 to 6 parts of sodium humate, 3 to 5 parts of mixed strain and 1 to 3 parts of water retaining agent. The preparation method comprises the steps: firstly crushing the egg shell, the modified diatomite, the ground phosphate rock powder, the wormcast, the biochar and the sugar residues, and high-temperature steam sterilization is carried out to obtain a mixed material; then adding the algae extract, the pine needle meal, the urea, the sodium humate and water, evenly mixing and fermenting; finally adding the water retaining agent, evenly mixing and pelleting. The organic fertilizer disclosed by the invention is sufficient in fertility, not only has yield improvement, high efficiency, long-acting property effects for crops, but also is good soil conditioner for improving the soil environment, thus having relatively good popularization and application prospect and profound significance for improving the soil environment of the crops.