Hu'akavameiliku received 14 votes while the Tongatapu MP Aisake 'Eke got 11 votes.
Eke had filed a motion for a vote of no confidence last week with 46 issues raised to support the call.
Hu'akavameiliku said he was happy the issue has been dealt with and he and the government can continue to do the work they were elected to do.
"I am grateful that the vote of no confidence has been dealt with and we can move on to working for the country and her people," he said.
Hu'akavameiliku said the issues raised by the group that moved the vote to oust him are being dealt with by the government.
One of the major issues raised was the operation of the country's only domestic airline service Lulutai Airlines.