MLB: Seattle Mariners at Tampa Bay Rays

Mariners relief pitcher Matt Magill, catcher Omar Narvaez and teammates talk on the mound during the ninth inning against the Rays on Wednesday afternoon at Tropicana Field.

ST. PETERSBURG, Fla. — The searing-hot Mariners were riding a streak where it seemed they could do no wrong. That finally ended on Wednesday afternoon, when the Tampa Bay Rays rallied for a wild 7-6 walk-off victory at Tropicana Field.

Wild … as in a pair of clutch ninth-inning rallies.

Wild … as in a wild pitch that decided the game.

With a fifth player added to a drawn-in infield, with the bases loaded and none out for the Rays, Mariners closer Matt Magill delivered a low breaking ball to leadoff batter Tommy Pham. But it bounced and eluded catcher Omar Narvaez, allowing Willy Adames to race home with the winning run.

“That pitch just got too low and it was unblockable,’’ said Magill, who entered the ninth with a 6-5 advantage but surrendered a tying leadoff homer to Kevin Kiermaier. “It was my fault. I cost our team a win.

“Everyone has failures in this game. You learn from it. That’s what the best people do in life. They grow from it and get better.’’

Mariners manager Scott Servais, whose team had captured four straight games, focused on the positives of a 6-3 road trip, which included three series wins.

“We almost pulled off a sweep here, really close,’’ Servais said. “We had one heck of a comeback late in the ballgame against a really good bullpen.’’

The Mariners trailed 5-3 entering the ninth inning. The numbers said a comeback was highly improbable.

The Rays bullpen, which came in with a baseball-leading 2.26 ERA since the beginning of August, had retired nine of 10 batters in relief of starter Charlie Morton.

This season, the Mariners had been 1-64 when trailing after eighth innings.

And then … boom!

Rays closer Emilio Pagan was greeted by Daniel Vogelbach’s 28th homer, making it 5-4. With one out, Pagan’s fastball hit the elbow of rookie Jake Fraley and Dee Gordon singled.

Ex-Ray Mallex Smith followed with a two-run triple to the right-field corner, putting the Mariners up 6-5.

“I just anticipated that moment — period,’’ Smith said. “I assumed I was going to come up with guys on the bases. I wasn’t trying to do too much. It just happened to go my way.’’

But just as quickly, Smith’s would-be heroics became a footnote.

Kiermaier’s homer off Magill tied the game. The Mariner momentum was gone. Adames singled, then was held at third when Mike Brousseau doubled. Pinch-hitter Ji-Man Choi was walked intentionally and Magill’s assignment was getting Pham to hit it on the ground.

“Stay low, that’s the idea,’’ Magill said. “That one just got too low.’’

Smith could only search for consolation in the losing clubhouse.

“We played well and they had to come back and win,’’ Smith said. “We didn’t lose. They beat us.’’

As for nearly becoming the conquering hero against his former club, Smith said, “That would’ve been cool, but it didn’t happen.’’

The Mariners were hitless through three innings, then got to Morton, who came in with the American League’s best ERA (2.77), with a three-run fourth inning to take a 3-2 lead.

Morton surrendered a leadoff triple to J.P. Crawford, then hit Austin Nola. Kyle Seager’s fielder’s choice grounder drove in Crawford, making it 2-1.

Narvaez singled to right, then went to second on right fielder Guillermo Heredia’s attempt to nab Seager at third. After Vogelbach walked to load the bases, Tim Lopes delivered a two-run single and the Mariners led 3-2.

But after the Rays reclaimed the lead, 4-3, on Kiermaier’s one-out, two-run single off left-hander Wade LeBlanc in the fourth, the Mariners began going quietly.

The noise would come later — on both sides.

In wild fashion.

Notes

Rookie center fielder Jake Fraley, the Mariners’ No. 8-ranked prospect according to MLB.com, made his major-league debut. He was 0 for 3. In the fourth, his deep line drive seemed destined to be for extra bases, but it was run down in right by Heredia.

Fraley became the 63rd player used by the Mariners this season, one off the MLB record (64 by the 2014 Rangers).

“We’re going to break that record,’’ Mariners manager Scott Servais said. “You can write that down.’’

Seager’s hitting streak of 14 games was halted by an 0-for-4 afternoon.

After an off day Thursday, the Mariners host the Toronto Blue Jays in a three-game series beginning Friday. Left-hander Justus Sheffield, called up from Class AA Arkansas, will start Friday. Right-hander Felix Hernandez, out since May with a shoulder injury, will start Saturday.