However, the victory was costly for the Giants, who lost third baseman J.D. Davis (sprained right ankle) and left fielder Mitch Haniger (broken right forearm) to injuries
Mike Yastrzemski hit a two-run homer and Patrick Bailey added a solo homer for the Giants, who won for the sixth time in eight games
Giants starter Alex Cobb allowed two runs on five hits and two walks in four innings. He struck out five. Reliever Luke Jackson (1-0) earned the victory by striking out three in one scoreless inning, and Keaton Winn earned a four-inning save in his major league debut
Jack Flaherty (3-5) allowed six runs on 10 hits and three walks with three strikeouts in 4 1/3 innings for the Cardinals, who lost for the 11th time in 14 games
The teams had a bench-clearing discussion in the middle of the fourth inning after Flaherty and LaMonte Wade Jr. jawed at each other.
The Giants seized a 2-0 lead in the first inning. Thairo Estrada walked, Joc Pederson hit a single and Conforto smacked a two-run double
The Cardinals tied the game in their half of the inning. Brendan Donovan hit a double, Paul Goldschmidt hit an RBI single, Nolan Gorman walked, Nolan Arenado hit a single and Dylan Carlson grounded into a run-scoring forceout
In the third inning, Pederson's walk and singles by Davis and Conforto put the Giants up 3-2. Davis was thrown out, and injured, while sliding into third base
Haniger was then injured when hit by a pitch.
San Francisco made it 6-2 in the fifth inning on singles by Blake Sabol, Conforto, Casey Schmitt and Patrick Bailey followed by Brandon Crawford's run-scoring bunt.
Yastrzemski hit his two-run homer in the sixth inning and Bailey followed with a solo shot to make it 9-2.
St. Louis cut the deficit to 9-3 on Jordan Walker's RBI double in the eighth inning. The Giants pushed their lead to 11-3 in the ninth on an infield RBI single by Estrada and a sacrifice fly from Sabol
--Field Level Media