TiO2 nanoparticles are full of porosity that can be impregnated with a strong alkaline catalyst CH3ONa to form a TiO2/CH3ONa catalyst. TiO2 of the anatase phase, which is a semiconductor material, has been a prominent photocatalyst due to its excited photocatalyst activity, chemical and biological stability, and nontoxicity. The CH3ONa compound has been widely used as a catalyst for transesterification. Although the synthesized photocatalyst TiO2 powder with CH3ONa is anticipated to greatly enhance the transesterification efficiency, leading to improving biodiesel properties, relevant studies have not been found. After the photocatalyst was prepared, a reactant mixture of palm oil, methanol, and heterogeneous catalyst TiO2/CH3ONa was illuminated by ultraviolet (UV) light from light-emitting diode (LED) lamps. The experimental results revealed that the formation of fatty acid methyl esters was significantly increased to 98.4% with ultraviolet-light illumination for the molar ratio of methanol/palm oil equal to 6 and 3 wt % catalyst addition. The decrease of the catalyst amount to 2 wt % resulted in a slight decrease of the fatty acid methyl esters to 97.06 wt %. The lowest kinematic viscosity and acid value and the highest distillation temperature, heating value, and cetane index were observed under the above reaction conditions. The distillation temperature and cetane index were increased while the acid value was decreased under ultraviolet illumination on the reactant mixture. Consequently, the optimum preparing conditions for biodiesel production were 6 and 3 wt % for the molar ratio of methanol/palm oil and catalyst addition under UV-light irradiation.