By Richard Black
BBC News website environment correspondent
Some of the great apes - chimps, gorillas, and orangutans - could be extinct in the wild within a human generation, a new assessment concludes.
Human settlement, logging, mining and disease mean that orangutans in parts of Indonesia may lose half of their habitat within five years.
There are now more than 20,000 humans on the planet for every chimpanzee.
The World Atlas of Great Apes and their Conservation is published by the UN's environment and biodiversity agencies.
It brings together data from many sources in an attempt to assess comprehensively the prospects for the remaining great apes; the gorillas, chimpanzees and bonobos of Africa, and the orangutans of south-east Asia.
The general conclusion is that the outlook is poor.
"All of the great apes are listed as either endangered or critically endangered," co-author Lera Miles from the World Conservation Monitoring Centre near Cambridge told the BBC News website.
"Critically endangered means that their numbers have decreased, or will decrease, by 80% within three generations."
One critically endangered species is the Sumatran orangutan, of which around 7,300 remain in the wild.
Most live in Aceh province at the northern tip of Sumatra, which saw armed conflict for decades between the Indonesian government and separatist rebels, and which suffered heavily during December's tsunami.
In mid-August, a peace deal was signed which may end the 29-year conflict.
"The irony is that just as things are getting better for the people of Aceh, they're getting worse for wildlife, with people collecting timber, dormant logging concessions being activated, and illegal logging as well," said Dr Miles.
"Projections show that in 50 years' time, there could be as few as 250 left in the wild; but that's not a viable size for a population."
The other species of orangutan, in Borneo, is much better off, with around 45,000 animals remaining; though data gathered for this report by the United Nations Environment Programme (Unep) and its biodiversity agency the World Conservation Monitoring Centre (WCMC) suggests that numbers have declined 10-fold since the middle of the last century.
The mountain gorilla of the Democratic Republic of Congo, and the Cross River gorilla, found on the border between Nigeria and Cameroon, are also listed as critically endangered, with numbers estimated at 700 and 250 respectively.
For gorillas and chimpanzees, ebola fever is emerging as a significant threat.
Why ebola is now taking its toll of apes is not clear, but may be connected with forest clearance. One theory is that the as yet unidentified animal which harbours the virus lives on the edges of forests; logging creates more edges, and so enhances the transmission of ebola.
An expert group of researchers which convened in May has just released an action plan for conserving apes in western equatorial Africa.
"If we find ways to protect apes from the ebola virus, we also will protect humans," it concludes.
But disease is not the only threat to the well-being of chimpanzees, their close relatives bonobos, and gorillas.
Bushmeat can be a significant source of protein in rural west Africa
Bushmeat hunting and habitat removal by logging are also major issues.
The 1990s saw forest cover declining in all African countries where gorillas, chimpanzees and bonobos live.
Close to human
The World Atlas comes with a foreword by UN Secretary-General Kofi Annan, in which he argues forcibly for the preservation of apes.
"The great apes are our kin," he writes. "Like us, they are self-aware and have cultures, tools, politics, and medicines; they can learn to use sign language, and have conversations with people and with each other.
"Sadly, however, we have not treated them with the respect they deserve."
His thesis on the close kinship of ape and man has been reinforced by the publication this week of the chimpanzee genome, demonstrating that humans and chimps share 99% of their active genetic material.
But stopping the decline of ape populations may not be easy, with human encroachment continuing, often under the pressure of poverty.
A key player is the Great Ape Survival Project (Grasp), launched under UN auspices in 2001, which aims to establish strategies for all regions of Africa and Asia which still have ape populations.
It holds its first council meeting next week in the Democratic Republic of Congo.