An experimental research is assessed to examine the engine performance and exhaust emissions of direct injection (DI) and indirect injection diesel (IDI) engines fueled with petroleum diesel, biodiesel, and nanoemulsion fuel. The nanoemulsion fuel was produced using a hydrodynamic cavitation reactor. These three fuels were used to study the exhaust emissions, brake power, brake specific fuel consumption (BSFC), brake thermal efficiency (BTE), and exhaust gas temperature at engine speeds ranging from 1100, 1400, 1700, 2000, and 2300 rpm with engine loads of 25, 50, and 75%. Furthermore, three fuels were burned in two types of combustion engines such as DI and IDI diesel engines under identical conditions. The finding showed that using DI and IDI engines influenced the magnitude of emissions as well as the performance with different speeds and loads. By comparing the performance of DI and IDI engines at a maximum engine load of 75%, the most concerning parameter among the efficiency of an engine of BTE of diesel, biodiesel, and nanoemulsion fuel from the DI engine was higher at 24.19, 24.83, and 20.76%, respectively, than that of the IDI engine at 2300 rpm engine speed. At the maximum load and speed of engines, the BSFC of diesel, biodiesel, and nanoemulsion fuel in the DI engine were 4.44, 23.73, and 20% lower than in the IDI engine, respectively. Emission results of the DI and IDI engines were analyzed at 75% load and 2300 rpm speed. The results demonstrated that emissions of NOx from nanoemulsion fuel from the IDI engine was significantly reduced by 82.46% when the values were compared to the DI engine. In terms of CO emissions, the IDI engine emits significantly less than the DI diesel engine. The CO emissions of diesel, biodiesel, and nanoemulsion fuel in the IDI engine were 69.02, 28.95, and 48.75% lower than those in the DI engine, respectively. The studies conclude that the emissions from IDI engines clearly show that pollution from exhaust emissions can be reduced to a low level compared to the DI engine. However, when high-performance engines are considered, the DI engine is recommended rather than the IDI engine.