SAN FRANCISCO (AP) - Dexter Fowler hit a leadoff triple in the ninth inning and scored the go-ahead run on Kolten Wong's single moments later, Stephen Piscotty later hit a two-run homer, and the St. Louis Cardinals rallied from a three-run deficit to beat the San Francisco Giants 11-6 on Friday night.

Greg Garcia hit a tying RBI triple in the top of the eighth inning off Mark Melancon, then Sam Dyson (1-2) gave it up in the ninth. Tyler Lyons (3-0) pitched the eighth for the win.

Paul DeJong added a two-run double in the six-run ninth and Yadier Molina had an RBI single.

Harrison Bader hit a two-run homer in the third for St. Louis before San Francisco added on again with Hunter Pence's two-run triple in the bottom half.

Randal Grichuk added a solo homer in the sixth for the Cardinals, his third straight game clearing the fences.