OAKLAND, Calif. -- Right-hander Sonny Gray allowed three runs on six hits over 8 1/3 innings, and the Oakland A's beat the first-place Los Angeles Angels 5-3 Friday night in the opener of a key three-game series between the top two teams in the American League West.

Oakland (75-52) cut the Angels' lead to one game in the West and ended the Angels' four-game winning streak. The A's and Angels (76-51) began a crucial 10-day stretch in which they'll face each other seven times, the first three games in Oakland and the final four at Anaheim.

Gray (13-7) ended his career-high four-game losing streak and earned his first victory since July 26 at Texas. He struck out five, walked two and threw 102 pitches.

A's center fielder Coco Crisp led off the game with a home run, doubled in the fifth and scored twice. Right fielder Sam Fuld had an RBI triple in the sixth and scored a run, and first baseman Stephen Vogt hit a solo home run in the eighth.

A's closer Sean Doolittle survived a high-wire act to record his 19th save. After striking out second baseman Howie Kendrick for the second out, he gave up a single to shortstop Erick Aybar and an RBI single to third baseman David Freese. Then he walked pinch hitter Collin Cowgill, loading the bases. Doolittle struck out pinch hitter Chris Iannetta to end the game.

Center fielder Mike Trout and left fielder Josh Hamilton hit solo home runs for the Angels.

Angels right-hander Hector Santiago allowed two runs, just one of them earned, over five innings and got his fourth straight no-decision. He struck out five, walked two and held the A's to one or no earned runs for the third straight start this season. He took a no-decision in all three games against Oakland.

The A's scored twice in the sixth off reliever Jason Grilli (1-4), snapping a 2-2 tie and taking a 4-2 lead. Second baseman Alberto Callaspo, a former Angel, hit an infield single with one out, and Fuld brought him home with a triple to the right-center field alley. Fuld scored on shortstop Andy Parrino's sacrifice fly.

Vogt extended the A's lead to 5-2, hitting a one-out home run off reliever Cam Bedrosian.

The Angels had just two hits off Gray over the first four innings, but they were both solo home runs, the first by Trout and the second by Hamilton.

Trout put the Angels ahead 1-0 in the top of the first with his 28th home run of the season, golfing Gray's 1-1 curve over the high wall in left-center.

The A's pulled even in the bottom of the first on Crisp's 15th career leadoff home run, thirteen of those with Oakland. He sent Santiago's 1-2 fastball over the left-center fence, following Trout's lead.

The Angels grabbed a 2-1 lead with one out in the top of the fourth on Hamilton's ninth home run of the season and first since Aug. 4. Gray threw him a 2-1 curve, and Hamilton sent it high into the seats in right-center.

Oakland answered with an unearned run in the fifth. Crisp lined a ground rule double that one-hopped the fence down the left-field line. After left fielder Craig Gentry walked, third baseman Josh Donaldson lined a shot up the middle that ricocheted off Santiago's left hand to second baseman Kendrick. Kendrick got the force at second, but shortstop Aybar threw wildly past first baseman Albert Pujols and into the A's dugout for an error as Crisp came home.

NOTES: Angels RHP Garrett Richards (torn left patellar tendon), who went on the 60-day disabled list Thursday, underwent season-ending knee surgery Friday. "They said the surgery was as they expected and they're very happy with the repair and hopefully the rehab will go very well," manager Mike Scioscia said before the game. "Same timetable they gave us before the surgery, six to nine months." ... The A's activated OF Craig Gentry (broken right hand) from the 15-day disabled list and optioned RHP Dan Otero to Triple-A Sacramento. Gentry started in left field and hit second against the Angels. Otero is 7-1 with a 2.28 ERA and one save in 56 relief appearances. He has just nine walks in 71.0 innings. ... Oakland entered the game hitting .226 in August, the lowest average in the American League.