Shearer called for a vote on his leadership after it was effectively challenged at the party conference last weekend by David Cunliffe.
Cunliffe has been punished by being dumped to an unranked section of the caucus.
Shearer wanted to end speculation about his leadership.
“That has now happened. I enjoy the confidence of my caucus today and going forward. Labour is a team. We’re here for New Zealanders and that’s bigger than the ambitions of any single individual,” he was reported as saying by Fairfax NZ.
He had laid out a “bold plan” at the weekend to take the country in a new direction, but needed the support of the caucus behind him.
“Sadly David Cunliffe has not been able to show that loyalty.
“His actions at the weekend were disappointing, not only to me but to many party members. That, along with his repeated failure to quell speculation about the leadership means that I no longer have confidence in him.
“He has lost my trust.”
The Labour caucus will again vote on its leadership in February, but Shearer was confident he would win then too.
He said he had no plans to demote Cunliffe loyalists, and would announce a replacement in the economic development portfolio shortly.
Cunliffe said on Facebook:
“I wish I could express my gratitude for your kindness and my wish that we all might work together for a better New Zealand.
“Unfortunately I am not at liberty to comment further at this time,” he wrote.
Prime Minister John Key said Cunliffe would be back to challenge for the leadership, and the caucus was deeply divided.
“They fundamentally don’t like each other and can’t agree on the direction they are going in … yip, they’ll put a united front on it today, but that’s not going to fool anyone.
“At some point in the future David Cunliffe is coming back after David Shearer.”