Peru's northern beaches have been declared off-limits as scientists try to pin down what is causing the mysterious deaths of thousands of birds and dolphins.

Since March, some 4,000 birds have been found dead along a 200km stretch of coastline, along with at least 900 dolphins.

The South American nation's health ministry declared an alert at the weekend.

It urged the public to stay away from the beaches around Lima and on the northern coast until the cause of death is known.

Local health officials are also asking residents not to eat raw fish and to avoid swimming in the seas.

The state environment ministry has ruled out water contamination or damage from dragnet fishing, suggesting cautiously that wildlife may be falling victim to a virus.

"Once we know what the scientific causes behind these deaths are, we will lift the alert," said health ministry spokesman Bernardo Ausejo.

A team of ornithologists have also been investigating the mysterious death of the birds, which started after dead dolphins began to wash ashore in January in the northern departments of Piura and Lambayeque.

Biologist Guillermo Boigorrea, from the agriculture ministry in Lambayeque, said although nothing had been determined for sure, "it seems that the birds died of starvation.

"Now we have to find out why the birds can't fly or fish," he said, adding scientists had also been analysing the seawater.

"It's unbelievable that the Oceanic Institute has still not given a reason for the massive deaths of pelicans and dolphins," said Carlos Bocanegra, a biologist from the University of Trujillo.

''I believe we are trying to protect certain interests," he told Peruvian radio, in an allusion to the powerful fishing industry, which is one of the mainstays of the nation's economy.

One non-government conservation organisation, known as ORCA, has blamed the dolphin deaths on oil exploration activities in the area, which it claims produces noises that are having an acoustic impact on the mammals.

The huge die-off "is a risk for human health in case of a possible mutation of the virus," said German biologist Stefan Austermuehle, head of another environmental group Mundo Azul.

Former health minister Uriel Garcia blamed excessive fishing for the pelican deaths, saying stocks of some species were running low such as anchovies, a favourite food of the sea-birds.

In an editorial with the daily El Comercio, he also maintained the birds were dying of starvation, not sickness.

Weather expert Abraham Levy hypothesised that the warming of the Pacific waters due to El Nino could be to blame.

"The warming of the waters alters the food chain, which is very complex and starts with the plankton and ends with the marine birds and the marine mammals on the other," he told AFP.

Meanwhile, deputy minister of fishing Patricia Majluf said she was resigning as the sector was "in disorder, full of irregularities and corruption."