ST. PETERSBURG, Fla. — Evan Longoria homered three times and the Tampa Bay Rays beat Baltimore 4-1 Wednesday, ending the Orioles' bid to force a one-game tiebreaker for the AL East title.

The loss left the Orioles as a wild-card team. They'll play Friday at Texas, with the winner advancing to the division series.

advertisement | advertise on newsday

Baltimore began the day one game behind the New York Yankees in the division. The Orioles needed a win, plus a loss by the Yankees to Boston, to pull even.

Longoria finished the season with a bang for the second straight year, hitting solo shots off Chris Tillman in the first and fourth innings and adding another solo shot off Jake Arrieta in the sixth.

With a chance to tie the major league record, Longoria grounded out in the eighth.