Scientists have found more evidence to suggest that taking ecstasy or smoking cannabis may lead to memory problems.
Little is known about the long-term effects of ecstasy
A survey of 763 internet users found ecstasy users had problems with long-term memory while cannabis users had problems with short-term memory.
It found users of both drugs suffered a "double whammy" with difficulty remembering all sorts of things.
Writing in the Journal of Psychopharmacology, the researchers warned users to be aware of the risks.
The findings are based on a web-based survey completed by people throughout the world.
Of these, 283 had taken ecstasy. Some 81 people said they had taken the drug more than 10 times. A total of 242 people said they had never taken drugs.
Each participant was asked a series of questions designed to test their short-term and long-term memory.
For instance, they were asked how likely they were to forget certain tasks, such as forgetting to pass on a message.
They were also asked how likely they were to find a television programme difficult to follow.
Their answers were analysed by a team of researchers from across the UK.
They found that ecstasy users were 23% more likely to have problems remembering things than those who had never taken the drug.
Cannabis users were 20% more likely to have problems remembering things.
The researchers also examined how accurately each participant filled out the questionnaire.
They found that people who regularly take ecstasy or smoke cannabis were more likely to have made mistakes compared to others.
Dr Jacqui Rodgers, a researcher at the University of Newcastle and one of those involved in the study, said the findings were a cause for concern.
"Users may think that ecstasy is fun and that it feels fairly harmless at the time.
"However, our results show slight but measurable impairments to memory as a result of use, which is worrying.
"It's equally concerning that we don't really know what the long-term effects of ecstasy use will be, as it is still a poorly understood drug.
"The results indicate that users are potentially creating a time bomb of potential cognitive difficulties later in life."
However, the UK charity DrugScope said the findings were unlikely to deter ecstasy users.
"What is needed is a longitudinal study into ecstasy use, following users over a period of years to find out the long-term effects," said a spokeswoman.
"Then we would have much more information to talk in an informed way about the long-term effects of ecstasy."