The children of women who experience severe stress when pregnant are nearly 10 times more likely to develop a personality disorder by the age of 30, a study suggests.
Even moderate prolonged stress may have an impact on child development and continue after a baby's birth, it said.
More than 3,600 pregnant women in Finland were asked about their stress levels, and their children followed up.
Psychiatrists say mums-to-be must have access to mental health support.
Other important factors, such as how children are brought up, the family's financial situation and trauma experienced during childhood, are known to contribute to the development of personality disorders and could have played a role.
What is a personality disorder?
It means that certain aspects of someone's personality make life difficult for them and for other people.
They can be overly anxious or emotionally unstable, for example, or paranoid or anti-social – there are a wide range of types.
Personality disorders are thought to affect about one in 20 people.
They are more likely to have other mental health problems, such as depression, or drug and alcohol problems.
Like other mental disorders, upbringing, brain problems and genes can play a part in their development.
What did the study do?
Every month during pregnancy, the study – in the British Journal of Psychiatry – asked women to answer questions about their mental stress levels.
They had to say if they had notable stress, some stress or no stress.
The women lived around Helsinki, Finland, and their babies were born between 1975 and 1976.
When those children turned 30, any diagnoses of personality disorder were noted – there were 40 in total, which were all severe cases involving admission to hospital.
What did it find out about stress?
The study found prolonged, high levels of stress during pregnancy could have a potentially long-lasting effect on children.
Children exposed to severe maternal stress were 9.53 times more likely to develop a personality disorder than those whose mothers experienced no stress.
Those exposed to moderate stress had four times the chances.
This could be stress related to relationship problems, social factors or psychological problems, for example.
Why is stress damaging?
It's not known how stress in pregnant women could increase the risk of personality disorders – it could be down to changes caused in the brain or the result of inherited genes, or a number of other factors in the children's upbringing.
The researchers tried to tease out the effects of stress alone, by controlling for other factors such as the psychiatric history of the pregnant women, whether they smoked during pregnancy or had depression.
Previous research has found links between stress in pregnancy and the development of depression, anxiety and schizophrenia.
What can be done?
Dr Trudi Seneviratne, who chairs the perinatal faculty at Royal College of Psychiatrists, said pregnancy could be a stressful time and mums-to-be needed support.
"If stress isn't tackled, there is a high chance it will spill into the post-natal period," she said.
"It's a really sensitive thing to talk about.
"We don't want parents to think they are damaging their children – but high levels of stress do affect us."
She said NHS England had dramatically improved perinatal mental health services in recent times.