SAN FRANCISCO (AP) — Alex Wood and five relievers combined on a three-hitter and the San Francisco Giants beat the Los Angeles Dodgers 5-0 on Tuesday night, ending a six-game losing streak to their NL West rivals.

Joc Pederson hit a two-run double in the first inning while David Villar and Brandon Crawford hit back-to-back homers in the eighth to complement a solid effort from the Giants' bullpen, which tossed 4 1/3 innings of two-hit ball.

A day after clubbing three home runs for the fourth time this season in a 9-1 win over the Giants, the Dodgers stranded 10 baserunners.

Los Angeles missed a big opportunity in the sixth after loading the bases with no outs following a catcher's interference call. Jakob Junis got Chris Taylor to strike out swinging, and then left-hander Scott Alexander (1-0) fielded James Outman's short comebacker and flipped to home for the force. Alexander followed with a swinging strikeout of Miguel Rojas.

John Brebbia allowed a leadoff walk to Mookie Betts in the seventh, then retired the next three batters to end another Dodgers threat.

Tyler Rogers and Camilo Doval set down three batters apiece to finish it off.

Wood was much sharper than he was against the Chicago White Sox, who chased him after three ineffective innings on April 6. Although he remains winless against the Dodgers in eight starts with San Francisco, Wood allowed one hit, struck out five and worked around three walks in 4 2/3 innings.

The Giants scored early and late. Pederson lined his two-run double down the right-field line against Dustin May (1-1). Villar and Crawford went deep off reliever Evan Phillips.

May allowed two hits and four walks over 5 1/3 innings. He was limited to six starts last season while recovering from Tommy John surgery and had allowed only one run in his first 13 innings this year.

The Dodgers had won their last eight games at Oracle Park dating to last season.

Trainer's room

Giants: OF Mitch Haniger (left oblique strain) and OF/IF Austin Slater (left hamstring strain) are both progressing and have resumed baseball activities but aren't likely to rejoin the team until it returns from its upcoming trip. Manager Gabe Kapler said both players could begin rehab assignments soon.

Up next

Dodgers ace LHP Clayton Kershaw (1-1, 3.75 ERA) gets the start in the series finale on Wednesday. Kershaw allowed nine earned runs in 18 1/3 innings during four appearances against the Giants last season. RHP Alex Cobb (0-1, 2.53), who has 12 strikeouts and one walk over his first two starts, goes for San Francisco.