SAN FRANCISCO -- Andres Torres came back from a rare day off better than ever.
He snapped out of a lengthy batting slump with a home run and two singles, though it was his speed that really made the difference.
Torres scored the deciding run from third base on Aubrey Huff's long foul out in the sixth inning, and the Giants overcame another erratic start by pitcher Jonathan Sanchez to beat the Cleveland Indians 4-3 on Friday night.
Before breaking out against Indians starter Carlos Carrasco, Torres had been hitless in 14 at-bats and was batting just .097 over his previous 13 games.
"It just seemed like his head was clear," San Francisco manager Bruce Bochy said. "More than anything just having his energy back (helped). He just seemed like he was more himself today."
Torres' big day helped the Giants rally from three runs down and win their major league-leading 16th one-run game at home. San Francisco has won three straight following a season-high five-game losing streak.
It's Torres' third multihit game this month.
"I just tried to calm my mind," Torres said. "Sometimes I have a lot of stuff going and I'm just trying to learn how to relax myself and things like that."
The Giants managed only six hits but took advantage of two errors by Cleveland first baseman Carlos Santana to score three unearned runs off Carrasco.
"Unfortunately we didn't play good defense behind him," Indians manager Manny Acta said. "I was impressed how he did not crumble. He kept his composure and kept going after hitters."
It was a tough night all around for the Indians, who lost outfielder Shin-Soo Choo to a broken left thumb after he was hit by a pitch from Sanchez in the fourth.
Sanchez allowed only two hits but walked six and hit a batter with a pitch in what may be his final start in San Francisco's rotation. The left-hander, who struck out six, has failed to make it out of the fifth inning in each of his last two starts and has only one win since May 12.
With left-hander Barry Zito scheduled to come off the disabled list in the next few days, manager Bruce Bochy may be forced to make a move. Before the game Bochy said that Zito will pitch the second game of San Francisco's doubleheader in Chicago on Tuesday but was noncommittal beyond that.
"We'll stay open-minded," Bochy said. "It's fair to say Jonny's searching right now. I can see it. He's fighting it. It's not that he's getting hit. He's just beating himself with these walks, and he knows it. I think it's affected his confidence a little bit.
"What we end up doing, I don't know. We may keep throwing him out there or we may back him off a little bit. Having Zito back will give us that option."
Santiago Casilla (1-1) pitched 1 1/3 innings for the win and combined with Jeremy Affeldt, Sergio Romo and Brian Wilson for 4 1/3 hitless innings to complete the two-hitter in the first meeting between the two teams since 2008. Wilson pitched the ninth for his 22nd save in 24 chances.
Carrasco (7-4) allowed only six hits and struck out four in his second career complete game but couldn't overcome Cleveland's defensive shortcomings. It's only Carrasco's second loss in his last eight starts.
"I pitched good but we had a couple errors," Carrasco said. "Nothing you can do about it. I just tried to stay aggressive and keep pitching consistently. Every pitch was working today, especially my fastball."
Sanchez walked two of the first three batters he faced before Santana's two-run double to the gap in left-center.
Sanchez came back to strike out the side in the second and pitched a perfect third but had control problems again in the fourth when he hit Choo with a pitch and knocked the Indians' outfielder out of the game.
Choo, who had hit safely in 20 of his previous 26 games, was hit on his right hand on the 2-1 pitch and fell face first to the dirt as a team trainer rushed out to check on him. He was eventually helped to his feet and paused momentarily along the first base line before walking off the field.
Sanchez walked the bases loaded in the fifth, ending his night.
Cleveland managed only one baserunner the rest of the game. Santana walked to lead off the eighth but was picked off.
Torres hit a 3-2 pitch from Carrasco into the stands above the 25-foot brick wall in right field leading off the fourth.
San Francisco then took a 4-3 lead after scoring three times in the sixth with the help of two errors by Santana.
Santana threw wildly to second base on pinch-hitter Nate Schierholtz's grounder, then bobbled Emmanuel Burris' infield dribbler, allowing Chris Stewart to score. Pablo Sandoval added a sacrifice fly and Torres hustled home on Aubrey Huff's deep foul out down the third base line.
Torres' home run was only the 14th at home by the Giants this season, tied with the Los Angeles Angels for fewest in the majors. ... Bochy plans to notify Major League Baseball this weekend of his choice to replace Jim Riggleman on the bench for the All-Star game. Riggleman abruptly resigned as manager of the Washington Nationals on Thursday amid a contract dispute with management. ... San Francisco C Eli Whiteside has a tight quad and was given the night off. Whiteside has started 19 games since Buster Posey sustained a season-ending injury on May 25. ...