A World Baseball Classic for the ages may have seen its most compelling ending yet.

Japan rallied from 3–0 and 5–3 deficits to stun Mexico, 6–5, in the semifinals of the World Baseball Classic Monday night, setting up a showdown against the United States in the championship game.

Mexico grabbed an early lead when second baseman Luis Urías tagged 21-year-old Japan ace Roki Sasaki for a three-run home run in the top of the fourth at loanDepot Park. Pitcher Patrick Sandoval kept the Japanese juggernaut off the board, limiting Mexico to four hits and a walk over 4 1/3 innings.

The tide, however, began to turn in the seventh. Right fielder Kensuke Kondoh singled and pitcher JoJo Romero walked designated hitter Shohei Ohtani before left fielder Masataka Yoshida walked to the plate with two outs and blasted a three-run, game-tying homer.

Right fielder Alex Verdugo and third baseman Isaac Paredes gave Mexico the lead back with a pair of eighth-inning RBI hits, but Japan recovered to cut the lead to one entering the ninth.

Ohtani led off the last inning with a double, Yoshida walked, and third baseman Munetaka Murakami's two-run double sent Japan to Tuesday’s final, with first pitch set for 7 p.m. ET.