[email protected] bi-functional catalysts were successfully synthesized through the in situ encapsulation method to form 2-5 nm Ni nanoparticles within HZSM-5 crystals, which was applied in evaluating the hydrodeoxygenation performance of palmitic acid to diesel-like range fuels. As for [email protected], there was the certain interaction between Ni and Al, which further influenced the hydrogenation activity and acidity of catalysts. Complete deoxygenation of palmitic acid and 100% selectivity of alkanes were achieved over [email protected] bi-functional catalysts, and the corresponding main products were C15 and C16 alkanes. Importantly, [email protected] (2.4 wt% Ni) exhibited the high conversion activity of 16.4 mol(palmitic acid) •mol(Ni)−1 • h−1, which were attributed to 2-5 nm Ni nanoparticles uniformly dispersed within HZSM-5 crystals. [email protected] further exhibited the well catalytic stability during the process of regeneration and recycle runs without obvious change of Ni sizes and dispersion, which was totally different from impregnated Ni/HZSM-5 catalysts with the aggregation of Ni particles. The favorable performance of [email protected] was ascribed to small Ni nanoparticles within HZSM-5 crystals without any obvious aggregation, which would offer a novel strategy for synthesizing low [email protected] bi-functional catalysts with high activity and stability in upgrading of bio-mass oils.