The performance helped the Nationals first baseman raise his season average from .125 to .300 Tuesday in Washington, D.C.
"Tonight, it was just one of those nights that it worked out for me," Kendrick told reporters.
The reigning World Series champions hadn't played since last Thursday due to a postponement of their series against Miami Marlins after a COVID-19 outbreak. The Nationals now are on a three-game winning streak.
Kendrick went deep in the Nationals' third at-bat of Tuesday's game after settling in against Mets starter Steven Matz, who got a called strike before Kendrick worked a full count. The Nationals first baseman then ripped a 3-2 changeup over the left field fence for a solo homer.
Josh Harrison doubled the lead with a 406-foot solo shot in the next inning. The Nationals then broke the game open with three more runs in the third frame.
Michael Conforto put the Mets on the scoreboard with a two-run homer in the top of the fourth inning. Mets star Pete Alonso closed the gap to two runs with an RBI single in the top of the fifth frame, but the Mets could not complete a comeback.
Kendrick had three singles and a home run in his 4-for-4 night. He also had two runs scored and an RBI.
Nationals starter Patrick Corbin allowed eight hits and three runs in 5 2/3 innings to earn his first win of the season. Matz allowed seven hits and five runs in three innings in his second loss of 2020.
The Nationals next host the Mets in the final game of the series at 6:05 p.m. EDT Wednesday at Nationals Park.