NEW YORK -- The New York Mets probably can't rewrite the inevitable ending to their season. But they're pretty good at dramatically changing the narrative of a single game in the late innings.
Kirk Nieuwenhuis hit a three-run home run off the right-field signage to cap a stunning four-run ninth inning comeback, lifting the Mets to a 4-3 win over the Chicago Cubs in front of a Father's Day crowd of 30,256 at Citi Field on Sunday.
The Mets (25-39) had three hits in the first eight innings Sunday, scored just five runs in the first 26 innings of the three-game series and appeared headed for their seventh loss in an eight-game homestand as the ninth inning began.
But they needed just 19 pitches by Cubs reliever Carlos Marmol to manufacture their sixth walk-off win of the season and their fifth win in which they trailed entering the ninth inning. It was also the seventh time in their last eight home victories dating back to April 24 that the Mets have scored the winning run in their final at-bat.
"If we can't use this as a spark -- I mean, I don't know what else we can do," Mets manager Terry Collins said.
In addition, the Mets were 2-of-33 with the tying or go-ahead run at the plate between the fifth inning Saturday -- when they fell behind 2-0 in a 5-2 loss -- and the eighth inning Sunday.
"We go through our scuffles," said Marlon Byrd, whose homer leading off the ninth started the rally. "But at the same time, we never give up. We can go through a stretch where we're not swinging the bats [but] everybody's always working, everybody's trying to figure out how to get it right.
"Today was one of those games [where] all the work we put in it helped in the ninth inning. We've just got to keep working, keep figuring out how to win games."
The comeback also spared the Mets the embarrassment of losing as a result of a series of errors usually seen in Little League. Two throwing errors on the same play by David Wright and Daniel Murphy led to two runs for the Cubs in the fifth inning.
"I know what would have been said, what would have been written [had the Mets lost]," Collins said. "And you know what? That's what should have been written, to be honest. That's what happened.
"But we're going to get on the plane with smiles on our faces."
The Mets are headed to Atlanta -- where they will begin an 11-game, 11-day, four-city road trip on Monday -- in a good mood thanks to some unlikely contributors. After Byrd's third homer of the homestand, Lucas Duda, who was 5-for-27 on the homestand, worked a walk.
"When Marlon hit the home run, there was a huge, huge bolt of energy go through the bench," Collins said. "And then when Lucas walked, there were guys saying 'We're gonna win the game.'"
John Buck, mired in a 21-for-115 slump since May 5, singled into right field. Omar Quintanilla, who was 3-for-32 on the homestand, sacrificed the runners.
Nieuwenhuis, who was 1-for-15 since being recalled from Triple-A Las Vegas last Sunday, crushed Marmol's second pitch well beyond the fence to unleash a wild celebration.
"Knew it was gone," Byrd said. "So I was trying to figure out the quickest way to get on the field."
It was the first walk-off homer for Nieuwenhuis, who flung his helmet into the air between third and home and leaped on to the plate. It was also his first homer since last June 23. A few minutes later, he received an apple pie in the face from teammate Justin Turner during an on-field television interview.
"Lot of fun," Nieuwenhuis said with a grin. "Can't really describe it."
The ninth-inning rally made a winner out of Bobby Parnell (5-3), who threw a perfect ninth. Mets relievers allowed just one hit in four scoreless innings.
Marmol, who was pitching in the ninth because closer Kevin Gregg had thrown four straight days, fell to 2-4. His implosion wasted an impressive effort by starter Matt Garza, who allowed three hits and two walks while striking out five in seven innings.
Luis Valbuena and Starlin Castro each had two hits and a run scored for the Cubs (28-39), while Alfonso Soriano had an RBI single in the first.
Soriano was also at the center of the bizarre play in the fifth. With two outs and two on, Soriano grounded to third baseman Wright, who overthrew Murphy at first. Castro scored easily. Murphy then threw wide of catcher Buck as Nate Schierholtz, who never broke stride from first base, slid in with a second run to put the Cubs up 3-0.
"That's definitely frustrating to lose a game like that," Schierholtz said. "It's a game we needed to win. We had them, we needed to put them away and we didn't."
Mets starter Jeremy Hefner allowed three runs (one earned) on six hits and one walk while striking out five in five innings.
NOTES: The Mets purchased the contract of RHP Carlos Torres from Triple-A Las Vegas and optioned RHP Greg Burke to Las Vegas. To make room for Torres on the 40-man roster, the Mets designated for assignment RHP Collin McHugh. Torres threw two scoreless innings in relief of Hefner. ... Wright reached base for the 10th time in his past 12 plate appearances with his double in the first inning. ... Cubs OF David DeJesus, who went on the 15-day disabled list Saturday with a right shoulder sprain suffered when he crashed into the centerfield wall Friday night, headed back to Chicago before the game and will undergo an MRI Monday. ... Valbuena batted leadoff for the first time this season and only the fourth time in 372 big league games. Manager Dale Sveum said Saturday that Valbuena and Ryan Sweeney were the main candidates to bat leadoff in DeJesus' absence.