A rescue effort was launched after nearly 50 pilot whales were stranded on a beach in Indonesia; but the majority did not survive

Forty-six small whales stranded on a beach in Indonesia have died, after rescue efforts succeeded in saving three others, local officials said Friday.

Starting Thursday, at least 49 short-finned arrived at a beach on Madura Island in northern Java, authorities said in a statement.

Large crowds gathered as a rescue operation was launched, with volunteers using tarpaulins or just their bare hands to try to push the pod back out to sea.

Curious onlookers took pictures and touched the whales, while others tried to splash water on them.

In the end, only three of the animals survived.

"The live whales had to be released together as they live in a group," said East Java governor Khofifah Indar Parawansa in the statement.

Parawansa said that officials had taken samples of the carcasses for further investigation into the cause of death.

He added that the corpses, which measure from three to five metres each, would be buried on the beach at low tide.

Authorities said that officials had taken samples of the carcasses for further investigation into the cause of death

Offshore cross-currents in the area pose a danger to whales, as they can get caught between reefs close to land.

Pollution, abandoned nets and floating are also dangers for .

In July last year, 10 pilot whales were found dead near Kupang, a town in East Nusa Tenggara province.

In 2018, a was found dead in Indonesia with more than 100 plastic cups and 25 in its stomach, raising concerns about the Southeast Asian archipelago's massive marine rubbish problem.

Large crowds gathered as rescuers tried to push the whales back out to sea, but in the end only three were saved