KANSAS CITY, Mo. — Pete Alonso’s error at first base in the fourth inning led to Kansas City’s only run of the night on Saturday and put the Mets behind.

So when Alonso got a chance to come through for his teammates with the bases loaded in the seventh, he did not want to fail. After narrowly missing out on a grand slam, he settled for a two-run single that put Jacob deGrom and the Mets ahead in a 4-1 victory over the Royals.

“Definitely when guys are on base, it definitely helps me,” Alonso said. “Like, O.K., I put us in a little hole earlier in the game. This is a chance at redemption.”

DeGrom (8-7), last year’s National League Cy Young Award winner, gave up three hits while striking out five over seven innings. Since the All-Star break, he has permitted just five earned runs in 45 innings for a 1.00 E.R.A.