The response of nitrifier and denitrifier populations and associated N2O emissions to different carbon-to-nitrogen (C/N = 17 or 45) straw amendments was monitored under flooding-drying and non-flooding conditions. A 10-week laboratory mesocosm study was conducted in two soils, (i) a paddy soil with a long history of managed flooding-drying (CN), and (ii) a wheat cropping soil with no previous history of flooding (UK). We measured N2O fluxes and the abundances of ammonia-oxidizing archaea (AOA) and bacteria (AOB), nitrite reductase (nirK and nirS) genes, and nitrous oxide reductase (nosZI and nosZII) genes during flooding (4 weeks) and post-flooding (6 weeks). Straw addition enhanced N2O emissions, with higher fluxes apparent after incorporation of narrow C/N residues. Moreover, the impact of crop amendment on N2O emission was exacerbated when soil was under flooding-drying conditions. The abundances of nirS and nosZI genes in CN soil and AOA gene in UK soil were increased by straw amendment, with highest in narrow C/N straw amendments. Structural equation modeling showed that the impact of denitrifier gene abundance on the N2O flux was stronger than that of nitrifier gene abundance in the two soils, and significant correlations were observed between N2O fluxes and the consumption of DOC and NO3−, indicating that denitrification was the dominant N2O production pathway during the drying phase. The ratio of (nirS + nirK)/(nosZI + nosZII) in the narrow C/N amendment was greater than in the wide C/N treatment after flooding, suggesting that the straw C/N ratio had an effect on the capacity for N2O production via denitrification. We conclude that crop amendments with an appropriate C/N ratio could minimize N2O fluxes through regulating the denitrification process when soils are subjected to regular flooding and drying and also experiencing greater frequencies of flooding.