Niese pitched eight sharp innings for his first victory since May 9, and the Mets beat the San Francisco Giants 3-0 to hand the slumping World Series champions their seventh straight defeat.
"Guys persevered today," Niese said. "They pushed some runs across. It was a good feeling."
Johnny Monell snapped a scoreless tie with a two-run double in the ninth against his former team.
"It just felt great to be able to come through for the team," Monell said. "When he pitches that well he deserves to win."
Michael Cuddyer had two hits, including a single that started the winning rally, to help the Mets improve to 3-1 on a six-game West Coast trip.
It was New York's second consecutive shutout, including an 8-0 victory Sunday at Dodger Stadium behind rookie Steven Matz.
"We don't play well on the West Coast, so to get off to a great start on this road trip is huge for us," Mets manager Terry Collins said. "It looks like we're starting to get some breaks."
Niese (4-8) retired 15 of his first 16 batters before running into a little bit of trouble in the sixth, when he lost his command momentarily. The Giants loaded the bases with two outs on Joaquin Arias' single and walks to Ehire Adrianza and Matt Duffy.
Niese retired All-Star slugger Buster Posey on a grounder to third to end the threat.
"I lost my feel for everything for a few batters," Niese said. "I wanted to slow the game down and stay calm to pitch against Posey."
The left-hander did not permit a run for the first time all season, ending a six-game losing streak and a nine-start winless streak. He allowed three hits, walked two and struck out four.
"He deserved it a lot," Collins said. "He's been pitching well lately and he had another tremendous outing."
Chris Heston, facing the Mets for the first time since throwing a no-hitter against them on June 9 in New York, gave up three hits in 7 1/3 shutout innings. He walked four and struck out two.
"I wish I would have not walked so many people and just tighten the zone a little better," Heston said. "But other than that I thought it went pretty well."
Cuddyer singled off Sergio Romo (0-4) to start the ninth and went to third on a double by Kirk Nieuwenhuis, called up from the minors before the game. Monell doubled against Santiago Casilla to drive in the go-ahead runs.
Heston was pulled after hitting Lagares with a pitch and walking Ruben Tejada sandwiched around a forceout on a ball that fell amid three players in short left field. Gregor Blanco threw to second to force Lagares.
Mets: Right-handed reliever Jenrry Mejia made his final rehab appearance Sunday and is expected to be activated in time for Tuesday night's game. Mejia completed his 80-game suspension for testing positive for performance-enhancing drugs.
Giants: OF Hunter Pence (soreness in left wrist) took batting practice the past two days, and manager Bruce Bochy said Pence could return this week.
Mets: RHP Bartolo Colon (9-6, 4.55 ERA) threw seven shutout innings in his last start. Colon is 2-2 with a 5.46 ERA in five starts against the Giants. He has not won in San Francisco in three years.
Giants: RHP Matt Cain (0-1, 9.00) will make his second start of the season Tuesday night. He made his first start in nearly a year on Thursday, taking the loss against Miami. Cain is winless in his last four starts against the Mets and is looking for his first win against them in four years.
Top 10 All-Time Game 7s
Reliving the best game seven showdowns from across the sporting landscape.
Galarraga on how he's moved forward from 'imperfect' game
Armando Galarraga reconciles the 10-year anniversary of his "imperfect" game, in which he was one out away from recording a perfect game with the Detroit Tigers.
Cubs' Tom Ricketts says most revenue goes right back into team
Cubs owner Tom Ricketts said most MLB teams' yearly revenue goes right back into the team and that "the league itself does not make a lot of cash."
White Sox's Tim Anderson, Lucas Giolito inspired by their relationship
Tim Anderson and Lucas Giolito have a unique bond on the White Sox, one they both believe other people across baseball -- and even throughout the country -- can learn from.
Break-in at Brewers' Miller Park leads to minor field damage
A break-in at Miller Park in Milwaukee early Tuesday morning led to minor field damage, the Brewers said in a statement.
Stephen A. fears MLB won't recover from a canceled season
Stephen A. Smith expresses his concerns for MLB and its future if the league were to cancel the 2020 season.