SAN DIEGO (AP) -- The first sign it was going to be a good night for Jacob deGrom was when he struck out the side in the first inning, all looking, on 10 pitches.
The right-hander won his eighth straight start with eight strong innings and the New York Mets held on when pinch-hitter Jabari Blash's bid for a game-winning home run was barely foul, beating the San Diego Padres 5-3 Monday night.
DeGrom (12-3) gave up two runs and struck out eight. The last Mets pitcher to win eight straight starts was Bobby Jones in 1997.
"The thing that stands out the most is his competitiveness," manager Terry Collins said. "This guy just doesn't give in. Tonight, early in the game, his foot started bothering him a little bit. You wouldn't know it. He loves to be out there and he loves to compete. With his stuff and his command, he's going to win a lot of games."
Collins said deGrom was dragging his foot on the mound, leading to some discomfort. But it hardly slowed the right-hander.
"It kind of bothered me from the start. I didn't know what was going on. It didn't affect me any," deGrom said.
He said winning eight straight is due to "just the command. I've been able to throw my fastball to both sides of the plate and just work off that. I think that's what helped me with success in 2015, being able to locate my fastball and pitch off that."
It was the seventh time in eight starts he went at least seven innings.
"I tried to stay out there as long as I can. I want to pitch into the ninth every game," he said.
Hunter Renfroe homered twice for San Diego, including a leadoff shot in the ninth. The Padres then put two runners on base with one out, and Blash sent a long drive that went just past the foul pole and landed in the right-field seats -- it was called foul, a ruling upheld on video replay.
Addison Reed, who played at San Diego State, then struck out Blash and closed for his 17th save.
"It's a tough one to lose by a couple inches," manager Andy Green said.
"It looks like we need another coat of paint out there. It doesn't look like it was foul by much. A little gust and we win a baseball game. That's a tough one. It was a good at-bat by Jabari, good at-bats all the way through the ninth inning against a very good closer. … We put ourselves in a position to win. We took our shots and we came up a bit short."
Wilmer Flores homered off Clayton Richard (5-10). Asdrubal Cabrera had three hits, Jay Bruce had two hits and two RBIs, and Jose Reyes stole his 500th career base.
DeGrom's only big mistake was allowing Renfroe's moonshot home run onto the top of the Western Metal Supply Co. Building leading off the seventh. The Padres announced the distance as 431 feet.
After he was called up last September, Renfroe became the first player to hit a homer onto the top of the four-story brick warehouse since the downtown ballpark opened in 2004.
"I'm proud of both of them," Renfroe said.
"Obviously deGrom is one of the best in the game. He's very good. He had some good stuff first inning. He always comes out. Good stuff all around. He was really showing it there and he was making really good pitches as well. He had 96 with the good spinning rating and good location. That's tough."
Renfroe has 19 home runs this season. It was the third multihomer game of his career and second this year.
DeGrom struck out his first four batters before walking Cory Spangenberg and allowing a single to Manuel Margot. Dusty Coleman, called up earlier in the day after the rebuilding Padres traded three pitchers to Kansas City, hit into a double play.
Flores homered in the second, his 10th.
The Mets added on in the third with Yoenis Cespedes' RBI triple followed by Bruce's single. Bruce singled again in the fifth to bring in Michael Conforto, who doubled with one out. Travis d'Arnaud hit an RBI single in the eighth.
Mets: RHP Zack Wheeler was put on the 10-day disabled list with a stress reaction in his right arm.
Padres: Manager Andy Green said SS Erick Aybar has a broken foot and could miss the rest of the season.
Mets: RHP Seth Lugo (4-2, 4.05) is scheduled to start the second game of the four-game series Tuesday night. The Mets have won 12 of his last 14 starts dating to Aug. 24.
Padres: RHP Jhoulys Chacin (9-7, 4.26) leads the Padres in victories.