SAN FRANCISCO -- Pinch-hitter Mark Canha hit a go-ahead home run in the seventh inning and the Oakland Athletics continued their late-game success, rallying to beat the San Francisco Giants 4-3 on Saturday night.
Stephen Piscotty and Marcus Semien had two hits apiece. Khris Davis added a sacrifice fly to help the A's improve to 20-6 since June 16, tied with Boston for the best record in the majors during that stretch.
Stay in the game with the latest updates on your beloved Bay Area and California sports teams! Sign up here for our All Access Daily newsletter.
Buster Posey, Steven Duggar and Chase d'Arnaud had two hits apiece for the Giants.
One night after being limited to three hits in a 7-1 loss, Oakland again struggled early until breaking out in the seventh.
Josh Phegley hit a leadoff single against Tony Watson (2-3). Canha followed with his 12th home run, a towering two-run blast, and emphatically flipped his bat and stared into the A's dugout before trotting around the bases.
It's Canha's first career pinch-hit home run and helped the A's avoid their first back-to-back losses since a season-high, four-game skid June 12-15.
Athletics
Find the latest Athletics news, highlights, analysis and more with NBC Sports Bay Area and California.
Oakland has scored 173 runs in the seventh inning or later this season, tied with Houston for second-most in the majors.
Yusmeiro Petit (4-2) retired eight batters to win. All-Star closer Blake Treinen pitched the ninth for his 24th save.
The Giants led 3-2 after Gorkys Hernandez hit an RBI double and scored on pinch-hitter Austin Slater's single off Oakland starter Brett Anderson in the fourth.
Giants first baseman Brandon Belt was ejected after the bottom of the fourth inning and had to be physically restrained from going after third base umpire Greg Gibson. Belt was upset over being called out on a checked swing and argued with Gibson as he took the field between innings. Gibson immediately ejected Belt, who angrily slammed his glove to the ground and began walking toward the umpire before teammates intervened.
TRAINER'S ROOM
Athletics: All-Star 2B Jed Lowrie struck out looking as a pinch hitter in the ninth after being held out of the lineup with a bone bruise and calf bruise in his left leg following a scary collision with Piscotty in right field Friday. . Reliever Santiago Casilla was designated for assignment. . 2B Franklin Barreto was recalled from Triple-A Nashville. RHP Ryan Dull was optioned down. RHP Daniel Mengden was sent to Nashville to begin a rehab assignment.
UP NEXT
Oakland LHP Sean Manaea (8-6, 3.44 ERA) goes for his fourth consecutive win on Sunday. Manaea is holding opponents to a .217 average over his last seven starts. LHP Andrew Suarez (3-5 3.75), who has allowed two runs or fewer in his previous six starts, pitches for San Francisco.