Click photo to enlarge
Hunter Pence of the San Francisco Giants crosses home plate on an RBI triple by Brandon Belt in the second inning of Game 4 of baseball's World Series against the Detroit Tigers on Sunday

DETROIT -- The never-say-die Giants cemented a legacy that will live forever.

After waiting 52 seasons for a first World Series title, San Francisco needed to wait just two for a second. The Giants refused to give in during an often-tumultuous season and refused to let up on the Detroit Tigers, sweeping them with a 4-3 extra-innings victory on Sunday.

Ryan Theriot hit a leadoff single in the 10th, took second on a sacrifice and scored on Marco Scutaro's single to center. Scutaro became the first player since Edgar Renteria in 1997 to win a World Series with an extra-innings hit.

The win was the seventh in a row for the Giants, who won the franchise's seventh title.

The Giants grabbed an early lead on back-to-back extra-base hits by Hunter Pence and Brandon Belt. Pence hit a deep double off of Max Scherzer to left-center field and scored when Belt lined a triple off the right field wall for his first World Series hit.

Matt Cain wasn't particularly sharp early on, but he kept the Tigers off the scoreboard for two innings, extending the pitching staff's scoreless streak to 20 innings. That run came to an end in the third inning, along with the Giants' 56-inning streak of not trailing a game. With two outs and a runner on, Miguel Cabrera hit a high fly ball to right field that kept carrying and carrying at Comerica Park, where the wind was blowing directly out to right much of the night. The two-run homer put the Tigers on top 2-1 and was the fifth home run allowed by Cain this postseason.

For the first time since Game 4 of the National League Championship Series, the Giants fell behind. Buster Posey made sure the situation didn't last long.

Posey was hitting just .190 in the postseason as he stepped to the plate with Marco Scutaro on first base in the sixth inning, but one of his hits was a huge grand slam in Game 5 of the NLDS that helped the Giants move on. That had been Posey's last extra-base hit until he crushed a hanging changeup from Scherzer, driving it through the wind and curling it just inside the foul pole for the go-ahead homer.

Posey raised his fist as he approached first base, the Giants now just 12 outs away from a title. But the Tigers rallied back in the bottom of the inning, tying the game on Delmon Young's two-out homer to right.

Cain battled through the rest of the sixth and cruised through the seventh, and the Giants looked to be back in business in the eighth. Scutaro drew a leadoff walk but Pablo Sandoval hit into a double play. Octavio Dotel struck out Posey to end the inning.

After walking Avisail Garcia in the bottom of the inning, Jeremy Affeldt struck out Cabrera, Prince Fielder and Young, the heart of Detroit's lineup.

Tigers left-hander Phil Coke returned the favor in the top of the ninth, striking out the side.

Hunter Pence of the San Francisco Giants crosses home plate on an RBI triple by Brandon Belt in the second inning of Game 4 of baseball’s World
Hunter Pence of the San Francisco Giants crosses home plate on an RBI triple by Brandon Belt in the second inning of Game 4 of baseball's World Series against the Detroit Tigers on Sunday (Nhat V. Meyer/Staff)

After Scutaro and Theriot teamed up to put the Giants on top, Sergio Romo came on for the bottom of the 10th.

For more on the Giants, see Alex Pavlovic's Giants Extra blog at blogs.mercurynews.com/Giants. Follow him on Twitter at twitter.com/AlexPavlovic.