Martinez had his biggest hit for the Red Sox since being acquired from Cleveland at the trading deadline, getting a go-ahead double with two outs in a six-run ninth inning that gave Boston an 8-4 victory over the Texas Rangers.
The win extended Boston's lead over Texas in the wild card to 1 1/2 games.
Trailing 4-3, the Red Sox were down to their last strike when Martinez ripped a pitch from Texas closer Frank Francisco into the right-field corner, scoring Jacoby Ellsbury and Dustin Pedroia.
"I saw three pitches and finally got a fastball right down the middle and I got a good swing at it," Martinez said. "My teammates have made it easy for me to fit in."
Boston needed Martinez's hit because pinch-runner Clay Buchholz was thrown out at home as the tying run after a double by Pedroia.
Buchholz, a starting pitcher, hesitated between second and third base when Texas left fielder David Murphy leaped to try to catch Pedroia's drive at the wall. Murphy quickly retrieved the ball and threw to Michael Young, whose relay beat a sliding Buchholz. The Red Sox ended up with runners at second and third, and Martinez followed with the go-ahead hit.
Boston finished off Francisco with Jason Bay's RBI single and a two-run home run by J.D. Drew. Francisco (2-2), who blew his third save in 19 chances, gave up seven hits and six runs. It was the first time he's allowed more than four hits or four runs in 203 major league appearances.
"I don't want anyone at my locker so beat it," Francisco said.
The Rangers had won 72 straight games at home when leading after eight innings. The last time they blew such a lead was September 2007.
"It doesn't really affect us," said Young, who had a two-run homer and three RBIs. "We have so much confidence in the back end of our bullpen. It's a fluke when this happens."
Red Sox reliever Takashi Saito (3-3) got the win after pitching a scoreless eighth. Jonathan Papelbon pitched a scoreless ninth, an anticlimactic non-save situation after the drama the preceded it.
David Ortiz, dropped to seventh in the batting order for the first time since May 24, 2003, ruined Kevin Millwood's chance for a third victory against Boston this season by wiping out a 2-0 deficit in the sixth inning with a homer off Eddie Guardado.
Ortiz also started the winning ninth-inning rally with a leadoff double.
Millwood threw 110 pitches in 5 2-3 innings, allowing three singles, walking five and hitting a batter.
White Sox 8, Athletics 7, 10 innings
Alexei Ramirez led off the 10th inning with a home run and visiting Chicago overcame blowing a 6-0 lead.
Ramirez hit an 0-2 pitch from Craig Breslow (4-4) to lift the White Sox to just their fourth win in the last 16 road games.
Ramon Castro homered for Chicago, while Jermaine Dye added two hits and three RBIs.
Yankees 4, Mariners 2
Mark Teixeira hit a solo home run in the top of the ninth, his second game-deciding homer of the week, and New York rolled on without a resting Alex Rodriguez.
Teixeira, who had a tiebreaking homer against Boston on Sunday, hit his 30th homer off Mark Lowe (1-5) to break a 2-all tie that had stood since the fifth.
Mariano Rivera closed the ninth for his major league-leading 34th save, and 30th consecutive conversion
- another major league best.