It was drama all the way, with Tonga leading by 24 points late in the first half, only to see the Kiwis draw level with a spirited second-half comeback.
Twenty-year-old Isaiya Katoa nailed a field goal for Tonga from 30 metres in the 76th minute, sparking a frenetic last couple of minutes as the Kiwis tried to get in front. Their goal attempts went astray to the delight of the Tonga's red-and-white flag-waving, hymn-singing supporters, who dominated the 22,000-strong crowd.
The result means Tonga will play Australia in the final next weekend, while the Kiwis will have a promotion-relegation match against the winner of the match between Cook Islands and Papua New Guinea on Sunday.
The Tongan side followed up a stirring Sipi Tau challenge before kick-off with a try to Sione Katoa charged over the corner after just three minutes.
They ran in four tries during a steamrolling first half performance, with the Kiwis only registering their first in the 36tth minute, to Isaiah Papali'i.
In between times it was a bone-crunching attack with ferocious hard running, led by Jason Taumalolo, Eli Katoa and Addin Fonua-Blake, backed up by skillful passing.
The Kiwis looked stunned but Papali's try gave them hope and their comeback in the second half was brilliant, with three tries including a stunner to Joe Tapine.
After Katoa's field goal, Jamayne Isaako missed a chance for the Kiwis, hooking a penalty attempt, and then Shaun Johnson's field goal attempt was charged down before Keano Kini attempted another. A captain's challenge that Johnson's legs were illegally taken out failed to convince the officials, and seconds later the match was Tonga's.
Taumalolo spoke of his pride at the win, telling Sky Sport: "To be back in Auckland playing before the red sea again is an unreal feeling. An honour to be back here playing before our fans.
"We came out firing, a little bit disappointing that second half, but we still managed to win and that's all that matters at the moment."
Kiwis captain James Fisher-Harris said his players showed some mana with their second half comeback.
"We had some opportunities at the end but we just couldn't get it done," he told Sky.
"MMT came out firing, all credit to them, they just came out physical and we didn't match them. All the best to them for next week."