J.D. Martinez homered for the first time in nearly a month, Bobby Dalbec snapped a tie with a solo shot and the Boston Red Sox won for the eighth time in nine games, beating the Seattle Mariners 4-3 on Friday night.

Boston opened the final leg of its West Coast swing with a bounce-back victory after seeing its seven-game win streak snapped a day earlier.

Martinez homered for the first time since May 17, hitting a solo blast off Seattle starter Marco Gonzales to give Boston a 2-0 lead. It was Martinez's sixth home run.

After the Mariners pulled even at 2-all, Dalbec opened the seventh inning with his fourth home run off Seattle reliever Andrés Muñoz (1-3). Muñoz had allowed one run over his previous six outings.

Jake Diekman (2-0), one of five Boston relievers, earned the win. Seattle pulled within 4-3 on Cal Raleigh's two-out RBI single in the eighth, but Matt Strahm got a flyout from Jesse Winker with the tying run at third to end the threat.

Tanner Houck had trouble in the ninth, but picked up his first save of the season and second of his career. Houck allowed two base runners, but got Adam Frazier to line out to end the game with the tying run at third. Seattle left 12 runners on base.

Seattle was looking for a good start to an 11-game, 10-day homestand following a successful road trip that inched the Mariners closer to .500.

But Gonzales struggled badly with control, walking a career-high six batters and barely making it out of the first inning after throwing 44 pitches. Seattle's only offense early came on Winker's two-run homer in the fifth inning in what was likely the last batter for Boston starter Rich Hill.

Despite the rough first inning that included Xander Bogaerts' RBI double, Gonzales minimized the damage. He pitched into the fifth, giving up only two runs and throwing 102 pitches.

Winker's homer came on a 2-2 curveball from Hill and stayed fair down the right field line, pulling Seattle even at 2-all. It was Winker's fourth homer, three coming off left-handed pitchers.

Seattle missed a chance for more in the fifth, leaving the bases loaded after Eugenio Suárez struck out and Adam Frazier popped out against reliever John Schreiber.

TRAINER'S ROOM

Red Sox: RHP Garrett Whitlock was placed on the 10-day IL with right hip inflammation. Whitlock was scheduled to pitch Sunday's series finale in Seattle. Boston recalled right-hander Phillips Valdez from Triple-A Worcester to take Whitlock's spot. ... RHP Nathan Eovaldi (hip) was examined in Boston and is expected to make his next turn in the rotation next week at home. ... OF Alex Verdugo was day to day with a sore knee.

Mariners: RHP Erik Swanson was reinstated from the injured list and rejoined Seattle's bullpen. Swanson had been out since May 14 with elbow inflammation. LHP Anthony Misiewicz was optioned to Triple-A Tacoma. ... OF/DH Kyle Lewis is still suffering from concussion symptoms and has not resumed baseball activities. Lewis was placed on the concussion injured list on June 1. ... RHP Ken Giles was in the Seattle clubhouse pregame but is still expected to have a couple more rehab outings in the minors before potentially joining the Mariners.

UP NEXT

Red Sox: RHP Michael Wacha (4-1, 1.99) is coming off a complete-game shut out over the Angels, allowing three hits and striking out six. Wacha has not allowed an earned run in his past two starts.

Mariners: Rookie RHP George Kirby (1-1, 3.38) makes his seventh start, but just his third at home. Kirby has pitched six innings in each of his last two starts and allowed two earned runs over those 12 innings.