Exhaust gas recirculation (EGR) and selective catalytic reduction (SCR) are crucial technologies for mitigating nitrogen oxide (NO x ) emissions in diesel engines. Although EGR reduces engine outlet NO x emissions, it simultaneously increases diesel consumption, leading to a poor economic performance. SCR requires AdBlue consumption; thus, striking the right balance for overall engine economy is of utmost importance. This study aims to evaluate NO x emission control and fluid cost in diesel engines. The total fluid cost of the diesel engine includes diesel and AdBlue. The engine is equipped with an aftertreatment system comprising a diesel oxidation catalyst (DOC), diesel particulate filter (DPF), selective catalytic reduction (SCR), and ammonia slip catalyst (ASC). The study was carried out at 1600 and 2100 rpm (25, 50, 75, and 100% load). The results show that with the increase of EGR valve opening, the exhaust temperature increased, the brake-specific fuel consumption (BSFC) increased, and the NO x emission decreased. With the increased AdBlue dosage, the NO x conversion efficiency gradually improved, ultimately approaching near-zero NO x emissions. However, as NO x emissions decreased, the equivalent diesel fluid cost rose. At 1600 r/min (100% load), when the NO x emissions were reduced by zero, the maximum fluid costs were 235, 223, and 218g/(kW•h) under the AdBlue/diesel price ratios of 1/1, 1/2, and 1/3, respectively. As the AdBlue/diesel price ratio decreases, the influence of EGR on the fluid cost diminishes. Coordinated control of EGR and AdBlue allows for reduced NO x emissions while mitigating the overall cost of diesel engines and aftertreatment systems. This research provides valuable guidance for EGR and urea control in diesel engines and contributes to the field of diesel engine emission control.