The invention discloses a preparation method of aniline through catalytic nitrobenzene hydrogenation. According to the preparation method, nitrobenzene is taken as the reactant, hydrogen gas is taken as the hydrogen source, a precious metal supported nitrogen-functionalized carbon material is taken as the catalyst, water is taken as the solvent, reactions are carried out for 0.5 to 5 hours at a temperature of 30 to 80 DEG C, after reactions, the reaction product is filtered; and then the reaction liquid is extracted by anhydrous ethanol to obtain aniline. No organic solvent or additive is used during the reaction process. After the reactions, the catalyst and the reaction product can be separated just through simple filtering. The catalyst can be repeatedly used, while the catalytic activity is basically not changed. The yield of aniline can reach 90% or more. The preparation process of catalyst is simple, the cost is low, the repeatability is good, and the catalyst system is high efficient, green, and environment-friendly. The reaction conditions are mild, the operation is simple, no additive is used, the catalysis process is environment-friendly, and thus the method has a very good industrial application prospect.