Despite the extensive research on biodiesels, further investigation is warranted on the impact of compression ratios on emissions and engine performance. This study addresses this gap by evaluating the effects of increasing the engine’s compression ratio on engine performance metrics—brake-specific fuel consumption (BSFC), power, torque, and exhaust gas temperature—and emissions—unburnt hydrocarbons (HCs), carbon dioxide (CO2), carbon monoxide (CO), nitrogen oxides (NOx), and oxygen (O2)—when fueled with a 20% blend of waste cooking oil biodiesel (WCB20) and petroleum diesel (PD) under various operating conditions. The viscosity of the prepared fuels was measured at 25 °C and 40 °C. Experiments were conducted on a single-cylinder diesel engine under wide-open throttle conditions at three different speeds (1400 rpm, 2000 rpm, and 2600 rpm) and two compression ratios (16:1 and 18:1). The results revealed that at a lower compression ratio, both WCB20 and petroleum diesel exhibited reduced BSFC compared to higher compression ratios. However, increasing the compression ratio from 16:1 to 18:1 significantly decreased HC emissions but increased CO2 and NOx emissions. Engine power increased with engine speed for both fuels and compression ratios, with WCB20 initially producing less power than diesel but surpassing it at higher compression ratios. WCB20 demonstrated improved combustion quality with lower unburnt hydrocarbons and carbon monoxide emissions due to its higher oxygen content, promoting complete combustion. This study provides critical insights into optimizing engine performance and emission characteristics by manipulating compression ratios and utilizing biodiesel blends, paving the way for more efficient and environmentally friendly diesel engine operations.