The invention discloses a method for preparing high-quality gasoline from cracking biological oil and relates to the technical field of hydrocarbon fuel preparation. According to the method, crude biological oil, lignocellulose, xylogen, phenolic monomer derived from the xylogen or/and lignin of the xylogen, cellulose, and a furan compound derived from the cellulose are used as raw materials. Under the catalytic action of Ni/HMFI catalyst, the hydrocarbon fuel is obtained through one-step hydrogenation deoxidizing conversion. Most of hydrocarbon products in obtained refined biological oil belong to the range of naphthenic hydrocarbon and aromatic hydrocarbon, does not contain sulphur and nitrogen, and belongs to high-octane high-quality clean gasoline fuel. The method has the advantage of being economical (source of the raw materials is wide and cost is low), simple in process, environment-friendly and easy to industrialize and the like. The catalyst is low in cost, efficient and easy in mass production, and products have significant application requirements. The method plays an important role in the field of replacement of fossil energy by biomass energy in the future, and is wide in application prospects.