A surrogate mother from California, US, had to fight a legal battle to get back her biological son, who she had conceived while being pregnant with a Chinese couple's baby.

In April 2016, Jessica Allen became pregnant with a surrogate baby but at six weeks discovered there were two babies growing in her womb. Doctors thought the second baby was an identical twin of the surrogate baby and Allen gave up both the newborns to the Chinese couple after she delivered them in December 2016, the BBC reported.

"I was pregnant through IVF already and at about six, seven weeks they found another embryo and they labelled it that the one embryo that they transferred split and turned into twins," Allen, who already had two biological sons before she decided to be a surrogate, told Newsday on the BBC World Service.

"My body naturally still ovulated while I was already pregnant — that's very rare — no one really knows about it but obviously, with my situation, more people are learning about it. It's called superfetation — it has a medical term to it, so why this process is not explained to surrogates, I don't know. They don't give this as a possibility," Allen added.

Allen was not allowed to see the babies after their birth as her contract with Omega Family Global — a San Diego-based institution that provides surrogates and IVF services globally — had outlined.

However, a month later after the babies were born, Allen said she received pictures of the babies from the other woman, pointing out that they did not look identical. She also asked Allen if she had any idea why they were different.

"I immediately freaked out and I asked my case worker, 'what's going on, how can this be, what's happened, how did this happen?' and she didn't have any answers for me," Allen told Newsday.

"So she [the case worker] said the next thing we need to do is to get me to have a DNA test."

Allen immediately went for the test and the other mother took the second child for the DNA test. Within a fortnight Allen was confirmed to be the biological mother of the child.

However, that was not the end of Allen's miseries. When she asked the Chinese couple to return her baby, they declined saying they wanted up to $22,000 (£16,820) in "compensation", as they had paid her for two babies who they thought were their own.

In trying to get their son back, Allen and her husband ran into legal complications as the law did not recognise them as the parents of the baby. The intended mother had signed the child's birth certificate, so she was his legal mother and held all rights over the baby, The BBC reported.

However, Allen's story did have a happy ending. After a long, expensive battle, the California couple were finally reunited with their son, who is now 10 months old.

"The moment was incredibly emotional, and I started hugging and kissing my boy. I don't regret becoming a surrogate mom because that would mean regretting my son. I just hope other women considering surrogacy can learn from my story. And that a greater good will come out of this nightmare," Allen said.