Tofu is a widely eaten soy product
Eating high levels of some soy products - including tofu - may raise the risk of memory loss, research suggests.
The study focused on 719 elderly Indonesians living in urban and rural regions of Java.
The researchers found high tofu consumption - at least once a day - was associated with worse memory, particularly among the over-68s.
The Loughborough University-led study features in the journal Dementias and Geriatric Cognitive Disorders.
Soy products are a major alternative protein source to meat for many people in the developing world.
But soy consumption is also on the increase in the west, where it is often promoted as a "superfood".
Soy products are rich in micronutrients called phytoestrogens, which mimic the impact of the female sex hormone oestrogen.
There is some evidence that they may protect the brains of younger and middle-aged people from damage - but their effect on the ageing brain is less clear.
The latest study suggests phytoestrogens - in high quantity - may actually heighten the risk of dementia.
Lead researcher Professor Eef Hogervorst said previous research had linked oestrogen therapy to a doubling of dementia risk in the over-65s.
She said oestrogens - and probably phytoestrogens - tended to promote growth among cells, not necessarily a good thing in the ageing brain.
Alternatively, high doses of oestrogens might promote the damage caused to cells by particles known as free radicals.
A third theory is that damage is caused not by the tofu, but by formaldehyde, which is sometimes used in Indonesia as a preservative.
The researchers admit that more research is required to ascertain whether the same effects are found in other ethnic groups.
However, previous research has also linked high tofu consumption to an increased risk of dementia in older Japanese American men.
Professor David Smith, of the University of Oxford, said tofu was a complex food with many ingredients which might have an impact.
However, he said: "There seems to be something happening in the brain as we age which makes it react to oestrogens in the opposite way to what we would expect."
The latest study also found that eating tempe, a fermented soy product made from the whole soy bean, was associated with better memory.
Professor Hogervorst said the beneficial effect of tempe might be related to the fact that it contains high levels of the vitamin folate, which is known to reduce dementia risk.
"It may be that that the interaction between high levels of both folate and phytoestrogens protects against cognitive impairment."
She also stressed that there was no suggestion that eating tofu in moderation posed a problem.
Rebecca Wood, of the Alzheimer's Research Trust, which funded the study, said more research was needed to pin down the potential risks and benefits of so-called superfoods.
However, she said: "This kind of research into the causes of Alzheimer's could lead scientists to new ways of preventing this devastating disease.
"As over half a million people have Alzheimer's in the UK today, there is a desperate need to find a new prevention or cure."