The midnight screams of a taxi driver being brutally bashed alerted nearby residents who tackled one of the offenders and held him until police arrived.
Another attacker was chased by a police dog and handler, and arrested.
The assault, in which the assailants used fists and elbows and delivered at least 15 blows, happened on Ohauiti Rd, Welcome Bay, overnight Wednesday. The victim spent a night in Tauranga Hospital being treated for head injuries before being discharged yesterday.
A senior detective says it was an unprovoked attack that will "haunt" the victim for the rest of his life.
The two teenage men, Timote Manu (19) and Jared Dixon (18) faced a joint charge of aggravated robbery when they appeared in Tauranga District Court yesterday. They were remanded in custody and are due back in court on January 29.
But detectives want the public's help to identify two other men who were in the taxi and fled afterwards.
Detective Sergeant Iain Chapman said the Tauranga Mount Taxis driver picked up four men from Welcome Bay shops and drove them to Ohauiti Road.
At their destination, he was put in a headlock and attacked by the front-seat passenger, and by another man who was seated behind him.
"Their intent was to steal cash from the cab and they also ended up with the driver's cellphone, so coupled with the fact that it was a very vicious assault, the men were charged with aggravated robbery," Mr Chapman said.
"The driver suffered extensive bruising and scratches from this vicious, over-the-top assault. The offenders used their fists and elbows ... and the violence they showed was absolutely unnecessary. You could count the blows on this man's body. There was an excess of 15 punches to his head."
Despite continuing to be hit, the driver managed to get out of the taxi and screamed, Mr Chapman said.
"That alerted the neighbours because the assault happened in a residential street, and the neighbours came out to his aid."
As the men tried to run off, the neighbours managed to grab one of the alleged offenders and restrained him until police arrived. Another man was arrested a short time later after being tracked and caught by a dog handler, Mr Chapman said.
The other two men fled and police have released CCTV footage from inside the taxi of one of them.
Mr Chapman said it was not believed this person physically took part in the assault but police want to speak to him as he was part of the group. Police also want to speak to the fourth man.
Police wanted to praise the efforts of local residents who quickly came to the victim's aid.
"Although we never want the public to put themselves in danger we couldn't do the job that we do without the invaluable help of people willing to stand up for what is right."
Tauranga Mount Taxis did not return calls but the attack has left the Tauranga taxi community shocked.
Anyone with any information is asked to call Iain Chapman at Tauranga police on 577 4300, or alternative ring the Crimestoppers line on 0800 555111.