An sun bear with a bad bowel and an even worse temper is about to receive world-first surgery from a team of Australian vets hoping to give her a new lease on life.

The bear, named Hitam, lives in excruciating pain.

Watch the related video above: Sun bear cub emerges from den for the first time

She became malformed from being raised in a cage on a diet of milk and rice.

The Orangutan Foundation International rescued the bear on the island of Borneo in January.

Staff tried to release her into a forest enclosure with other sun bears but Hitam did not play nice.

Volunteers soon learned she was cranky because a canal in her pelvis was a quarter of the size it should be, making it agonising for her to go to the toilet.

Now a group of dedicated Australian veterinarians will travel to the Indonesian part of Borneo to perform a triple pelvic osteotomy on the creature, which had been caught in the wild animal trade.

RELATED:

They will insert a custom metal plate, built by Australian medical designer Girius Antanaitis, into her pelvis.

Vet and filmmaker Stephen Van Mil said poaching, which resulted in Hitam being taken from the wild and sold as a domestic pet, was another ugly spin-off of deforestation.

He said he hoped the September operation by dedicated vets Gordon Corfield, Geoff Wilson and Larry Vogelnest meant Hitam could soon play with other bears.

"Hopefully she'll be a normal bear again," Van Mil said.

The vets hope the operation will shine a light on the palm oil industry's contribution to deforestation.

Orangutan Foundation International cares for more than 400 orangutans displaced by deforestation.