An effective approach to reducing greenhouse gas emissions is to utilize low/zero carbon fuels. This study simulated the combustion of a marine spark ignition (SI) ammonia-hydrogen engine, focusing on the effects of hydrogen volume fraction (X-H2), air fuel ratio (lambda), and compression ratio (CR) on the combustion and emission characteristics. The pathways of nitrogen-based pollutants such as NH3, NO, and N2O were explained. The results show that increasing X-H2 improves Pmax, heat release rate, thermal efficiency, and power. Regarding emission characteristics, when X-H2 rises, NH3 emissions drop; NOx emissions remain almost constant at lambda <= 1 (2100 ppm at lambda = 1) and considerably increase at lambda > 1, peaking at 5245 ppm. Moreover, as CR rises, the engine power and thermal efficiency increase, NOx emissions decrease by 10%, and N2O emissions are below 20 ppm. Furthermore, chemical kinetic analysis shows that NO comes from N and N-2, diffuses from the flame front toward the center in the cylinder under lambda = 1.2. And NO comes from HNO and is generated in the flame front and the center under lambda = 0.9, respectively. N2O is produced by NH and NH2 and is only generated in the flame front.