NEW YORK (AP) — Max Scherzer pulled himself from a start Wednesday night with discomfort in his left side before the New York Mets finished off an 11-4 victory over the St. Louis Cardinals.

Pete Alonso homered and drove in four runs for the Mets (25-14), who improved to 13-1 following a loss. The only time they dropped consecutive games this season was April 10-11.

Jeff McNeil had an early two-run single and Alonso snapped a 2-all tie with an RBI single off rookie reliever Jake Walsh (0-1) in a four-run fifth inning. Dominic Smith knocked in a run with a single during the outburst, and Luis Guillorme drove in another with a nicely executed safety squeeze.

Mets batters were hit by pitches three times, increasing their major league-leading total to 28. That includes eight by Cardinals pitchers in six games — the teams got into a bench-clearing melee in St. Louis last month.

Both benches were warned Wednesday night after Mark Canha was hit near the ribs by a 98 mph fastball from Cardinals starter Jordan Hicks in the third, but there was no trouble between the teams.

Canha scored three times and followed Brandon Nimmo’s run-scoring triple with an RBI single as the Mets broke open a 6-4 game with a five-run eighth capped by Alonso’s three-run homer off T.J. McFarland.

Nolan Arenado hit a two-run homer for the Cardinals. Albert Pujols got two hits to pass Eddie Collins for 10th place on the career list with 3,314, including an early two-run single off Scherzer (5-1).

The three-time Cy Young Award winner left with two outs in the sixth and a 1-1 count on Pujols. He will have an MRI on Thursday, the Mets said.

With two runners on, Scherzer threw a slider in the dirt and immediately signaled to the New York bench that he was done.

Pitching coach Jeremy Hefner, manager Buck Showalter and a trainer came out of the dugout to visit Scherzer on the mound. After a quick discussion, the 37-year-old right-hander walked off the field.

Scherzer threw 61 of his 87 pitches for strikes and left with a 6-2 lead against his hometown team. Adam Ottavino was given all the time he needed to warm up, and he struck out Pujols to end the inning.

The 42-year-old Pujols, who stole second off Scherzer, also grounded out with the score 6-4 and a runner on against Seth Lugo to end the eighth.

TRAINER’S ROOM

Cardinals: Gold Glove 2B Tommy Edman (left calf tightness) was not in the starting lineup after getting hit by a pitch Tuesday night. But he entered in the fifth when SS Edmundo Sosa hobbled off with a mild ankle strain. Sosa was shaken up sliding into second base as he was caught stealing in the previous inning. He is day-to-day. Brendan Donovan shifted from second base to shortstop.

Mets: Nimmo was back in the lineup. The leadoff man fouled a ball off his right knee in the second game of Tuesday’s doubleheader and left with a bruised right quadriceps. … RF Starling Marte is expected to rejoin the team Thursday, but it’s unclear if he’ll be activated in time for the afternoon series finale. Marte is on the bereavement list following the death of his grandmother.

FILLING IN

Player development instructor José Oquendo coached third base for the Cardinals in place of Ron “Pop” Warner, who is away from the team to attend his son’s high school graduation in the St. Louis area. Oquendo previously spent 18 seasons on the Cardinals’ coaching staff, including 16 as third base coach.

UP NEXT

Cardinals RHP Dakota Hudson (3-2, 3.06 ERA) faces RHP Chris Bassitt (4-2, 2.34) in the series finale Thursday afternoon. Bassitt pitched six innings of two-hit ball for a 3-0 win April 26 in St. Louis.