Perth Glory beat Melbourne City 5-4 to close the A-League regular season but it wasn't enough to earn a home final against the same opponent.
Glory and City were destined to meet in an elimination final next week with just the venue to be determined.
It was a tall order for Glory to earn the home final, needing to beat City by four goals.
They did start well with a penalty from Diego Castro in the fifth minute. But City responded in the 21st with a classy finish from Tim Cahill.
An Andy Keogh goal five minutes into the second half reignited Perth's hopes with Chris Harold adding another in the 56th minute.
A Nebojsa Marinkovic free-kick with 15 minutes to go put Perth up 4-1 but City snuffed out their chances with Cahill's second in the 80th minute before one to Nicolas Colazo in the 84th.
Adam Taggart's goal for Perth in the 88th minute proved immaterial as did Nick Fitzgerald's in injury time.
That ensured City finished fourth to play at home either Friday night or Sunday against the fifth-place Glory.
Castro was proving particularly lively shaking off a calf injury for Glory.
Taggart drew a foul on Neil Kilkenny in the penalty area after four minutes which Castro converted.
City settled when Bruce Kamau found Cahill at the top of the penalty area. After a couple of dribbles he delivered a smooth finish on his left-boot.
Another terrific Castro pass put Keogh into some space in the 50th minute and he scored his 12th of the season.
Harold replaced Richard Garcia and three minutes later scored with a header on a perfect cross from Josh Risdon to put Perth up 3-1.
It became 4-1 in the 75th thanks to a masterstroke from coach Kenny Lowe.
Marinkovic was substituted just as a free-kick was awarded. The dead play specialist delivered a pearler from just outside the box leaving Perth needing just one more goal.
While Perth had the momentum, City delivered the killer blow in the 80th minute when Cahill slid in to give himself a brace for the night and great form heading into the finals.
Lowe was disappointed to not have a home final to prepare for but said his team gave their all.
"I didn't think it would be that open with that many goals, but I guess people will have been entertained definitely," Lowe said.
"At one point it looked as though it was a distinct possibility it could have happened but that's how it goes sometimes. You can't fault the intent from our guys to really give it a shake."
City coach Michael Valkanis was looking for the win and to leapfrog Brisbane Roar into third spot.
"Both teams were chasing wins and we needed to win to finish third and it was just crazy how it all panned out in the end," Valkanis said.
"But if you break down what we did, we probably could have added another four or five goals so it's even more crazy going into finals after a game that was so open."